[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Ondemand governor by default in etch



Hi,

I believe that we should enable CPU frequency scaling, and the ondemand
governer, by default in etch.

By doing so, we:

 * Save our users money with their power bills

 * Reduce the contribution to pollution and global warming by machines
   running Debian, and thus help to save the planet.

Setting the ondemand governor:

 * Will cause negligible impact on system performance.  ondemand seems
   to have the philosophy of "max system speed unless I can be shown
   that the system is pretty much idle"

 * Requires no user-land tools to manage

 * Is compatible with almost all modern hardware, and just won't
   load on machines that don't support it

 * Requires only a 10K ondemand module and a 5-15K driver module to be
   loaded into the kernel

Why should it be the default?

Earlier this morning, I wrote up the procedure [1] to enable CPU
frequency scaling and the ondemand governor.  It's about 3 pages, and
not even newbie friendly at that.  So the first reason is that people
that don't know about this feature aren't prone to find it, and even if
they find it, they aren't prone to know how to enable it.

[1] http://changelog.complete.org/posts/572-Saving-Power-with-CPU-Frequency-Scaling.html

Secondly, the ondemand governor is very non-invasive.  It requires no
userspace daemon.  It makes a negligible impact on performance.  And if
people do wish to run a userspace daemon, this default will not
interfere with it.  I've tried it all over the place.  It is stable and
reliable.

Thirdly, it is ethically the right thing to do.  Think about all the
thousands (millons?) of machines that are running Debian.  If we save
even an average of 10W per machine, we could be talking about huge
energy savings worldwide.  We save our users money on their power and
cooling bills.  We reduce air pollution, which has been shown to have
negative health effects.  And we reduce greenhouse gas emissions.

I can't see any reason NOT to do it.

How would we turn it on by default?

1. Compile all the CPU frequency drivers (not the governors) into the
   kernel statically.  This should only add about 150K to the kernel
   size.  We don't currently have a way to autodetect which CPU
   frequency driver to use for a machine.  The alternative is to try to
   modprobe all of them, with ACPI last, at boot.

2. modprobe cpufreq_ondemand at boot (not necessary on 2.6.18)

3. Run something like:

   for CPU in /sys/devices/system/cpu/*; do
      echo ondemand > $CPU/cpufreq/scaling_governor
      cat $CPU/cpufreq/cpu_max_freq > $CPU/cpufreq/scaling_max_freq
   done

Very easy.

Thoughts?




Reply to: