CPU power management on OpenSolaris
By glagasse on Jan 31, 2008
I haven't forgotten about my promise to post more (in particular to post about configuring my new T61P). I've got a post or two in process that I'm tidying up that documents all of that. I should have them up 'soon'. In the meantime I thought I'd post how I enabled CPU power management on my Lenovo T61P running Indiana since it took me a little bit to actually find out how to do so. This will also work on Solaris Express Developer Edition as well as Solaris Express Community Edition versions of OpenSolaris as long as you're running build 70 or higher.
Power Management for OpenSolaris is being developed by the Tesla project. This is to utilize Intel's Enhanced SpeedStep technology in their line of processors which allows the Operating Systems to scale the processor speed depending on system load or other user defined policies. Which has the nice side effect of using less power (good for laptops when disconnected from a power source) and generating less heat (good for not scorching one's body parts when using aforementioned laptops). Thanks to you can now manage some Intel cpu's operating frequency. And it's dreadfully easy (as long as your cpu supports it, see the flag-day referenced above which outlines how to check if your cpu is supported) to enable.
Modify /etc/power.conf and add the following entries:
After that, just run /usr/sbin/pmconfig as root (or with rootly powers via pfexec in the case of Indiana) and in 15 seconds you should see that your cpu frequency will drop. You can get a lot of useful information from the cpu_info kstat (/usr/bin/kstat cpu_info). In particular the current_clock_hz and supported_frequencies_hz. In my case, the processor in the T61P has a max frequency of 2.4Ghz. With cpupm enabled the processor cores run at 800Mhz when the machine is idle. Pretty great stuff :-)
Now all I need is solid S3 (suspend to ram) support (which is also under development) and OpenSolaris on a laptop will just about rival Mac OS X (at least for the things I care about).