Cpufreq

時代はエコである.
うちのデスクトップPCは,ほとんどアイドル状態である.
しかし,アイドル状態でもCPUは動作周波数は最大値である.
ヒマなときは少しサボってもバチはあたらないんじゃない?
ということで動的にCPUの動作周波数を変更する設定を行う.

ツールのダウンロード.

% sudo pacman -S cpufrequtils

とりあえず,CPUの情報.

% sudo modprobe acpi-cpufreq
% cpufreq-info
cpufrequtils 008: cpufreq-info (C) Dominik Brodowski 2004-2009
Report errors and bugs to cpufreq@vger.kernel.org, please.
analyzing CPU 0:
  driver: acpi-cpufreq
  CPUs which run at the same hardware frequency: 0 1
  CPUs which need to have their frequency coordinated by software: 0
  maximum transition latency: 10.0 us.
  hardware limits: 2.00 GHz - 3.17 GHz
  available frequency steps: 3.17 GHz, 2.67 GHz, 2.33 GHz, 2.00 GHz
  available cpufreq governors: performance
  current policy: frequency should be within 2.00 GHz and 3.17 GHz.
                  The governor "performance" may decide which speed to use
                  within this range.
  current CPU frequency is 3.17 GHz.
analyzing CPU 1:
  driver: acpi-cpufreq
  CPUs which run at the same hardware frequency: 0 1
  CPUs which need to have their frequency coordinated by software: 1
  maximum transition latency: 10.0 us.
  hardware limits: 2.00 GHz - 3.17 GHz
  available frequency steps: 3.17 GHz, 2.67 GHz, 2.33 GHz, 2.00 GHz
  available cpufreq governors: performance
  current policy: frequency should be within 2.00 GHz and 3.17 GHz.
                  The governor "performance" may decide which speed to use
                  within this range.
  current CPU frequency is 3.17 GHz.

今は performanceしか選択できないが,

% sudo modprobe cpufreq_ondemand

とすれば,ondemandも選択可能になる.

起動時に有効にするためデーモンにたのむ.
/etc/conf.d/cpufreq

governor="ondemand"

として,/etc/rc.confのDAEMONSの欄に追加.

MODULES=(acpi-cpufreq cpufreq_ondemand !pcspkr !acer-wmi !acerhdf !usblp)
(中略)
DAEMONS=(syslog-ng cpufreq !network @crond @hal @alsa @net-profiles !sshd)