MacBook patches

From: Rui Paulo <rpaulo_at_fnop.net>
Date: Fri, 11 May 2007 16:39:07 +0100
Hi,
Attached are the work I've done so far for my Summer of Code
project. If you have a MacBook and are willing to spend some time
build -current with these patches and testing, here's what you should
know:

1) Grab the patch a
	http://fnop.net/~rpaulo/freebsd/macbook.diff
2) Apply it to today's -current
3) Build a kernel.

Load three modules: backlight, msrtemp, cpufreq (est).
The only one that shouldn't work out of the box on MacBook Pro's
backlight.

backlight controls the LCD backlight. You should have
hw.backlight.{enable,value} after loading the module.
Play with it to see if it works. I didn't test MacBook Core 2 Duo, but
it should work.
I have a feeling that it should be very easy to make it work for the
MacBook Pro, but contact me if you need help.

msrtemp displays the Cores temperature.
There should be N new sysctls, one for each CPU. For example:

$ sysctl dev.cpu.{0,1}.temperature
dev.cpu.0.temperature: 53
dev.cpu.1.temperature: 53

est should detect, at least, the following values:
dev.cpu.0.freq_levels: 2000/31000 1833/28016 1667/25033 1500/22050
1333/19066 1000/13100

Don't panic if you have more :) I disabled p4tcc and acpi_throttle on
purpose.

Have fun!
--
Rui Paulo
Received on Fri May 11 2007 - 14:10:50 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:10 UTC