powerd: add support for limiting cpu frequency on adaptive mode
smithi at nimnet.asn.au
Fri Oct 27 08:46:38 UTC 2006
On Thu, 26 Oct 2006, Kevin Oberman wrote:
> > Can someone look on the pr
> > (http://www.freebsd.org/cgi/query-pr.cgi?pr=bin/104689) I sent. Maybe
> > the patch is dirty but I think that idea is nice and with it battery
> > lives really longer.
> YES! When I am on battery for an extended time, I am very happy to have
> the system max out at a MUCH lower speed if I can keep basic capabilities
> for simple stuff like editing and such. Slight slow-downs are not an
The problem I see with this patch as it stands is that it affects both
battery and AC power adaptive modes (ie, powerd default operating mode)
Stepan says in the PR:
"Apply the patch and run powerd:
powerd -a maximum -b adaptive -m 558
Where 558 is maximum frequency on adaptive mode"
I want to run adaptive mode on 'AC' both because it uses half the power
when idle and greatly reduces the laptop's temperature (Thinkpad T23).
'AC' in quotes, this being a 100% solar power home; every watt counts.
Were the -m switch function ANDed with (acline_status = SRC_BATTERY) or
perhaps, allowing for SRC_UNKNOWN, (acline_status != SRC_AC) then you
could still use adaptive mode at full speed on 'AC' when required and
take advantage of setting a maximum speed while running on battery?
> That said, power consumption is NOT intuitive. If I am playing an MP3
> (very constant CPU load) at a speed where the CPU is at about 80%, the
> system uses more power than when the CPU is at 30%. In either case, the
> MP3 playback is fine. (This was on my T30 with a 1.8G P4M CPU, so it's
> not the best for power use.)
The T23 is only a two-speed P3M (1133/733) so I've yet to see the full
potential of powerd, nor have I played with its idle/busy shift points
or examined hysteresis between load shift points at various freqs, but
it's already a Very Good Thing here ..
> I know that Windows wants to reduce maximum CPU speed when running on
> battery, so I do believe this is a good thing.
If limited to while running on battery only, I'd heartily agree.
Meanwhile of course you can run powerd -b min though that might be
overkill if you have lots of freqs available ..
More information about the freebsd-acpi