second try: centrino patch - how to use?

Bill Nottingham notting at redhat.com
Wed Jul 30 14:11:49 UTC 2003


Peter (pboy at barkhof.uni-bremen.de) said: 
> I'll try again: can someone (possibly from Rad Hat) inform us how make
> the speedstep centrino module work? Or post a link where to find
> information? There are some people around here who would like to know
> about it.

     CPU frequency and voltage scaling code in the Linux(TM) kernel
...

2.1   /proc/cpufreq interface [2.6]
***********************************

Starting in the patches for kernel 2.5.33, CPUFreq uses a "policy"
interface /proc/cpufreq.

When you "cat" this file, you'll find something like:

--
          minimum CPU frequency  -  maximum CPU frequency  -  policy
CPU  0       1200000 ( 75%)      -     1600000 (100%)      -  performance
--

This means the current policy allows this CPU to be run anywhere
between 1.2 GHz (the value is in kHz) and 1.6 GHz with an eye towards
performance.

To change the policy, "echo" the desired new policy into
/proc/cpufreq. Use one of the following formats:

cpu_nr:min_freq:max_freq:policy
cpu_nr%min_freq%max_freq%policy
min_freq:max_freq:policy
min_freq%max_freq%policy

with cpu_nr being the CPU which shall be affected, min_freq and
max_freq the lower and upper limit of the CPU core frequency in kHz,
and policy either "performance" or "powersave".
A few examples:

root at notebook:#echo -n "0:0:0:powersave" > /proc/cpufreq
     sets the CPU #0 to the lowest supported frequency.

root at notebook:#echo -n "1%100%100%performance" > /proc/cpufreq
     sets the CPU #1 to the highest supported frequency.

root at notebook:#echo -n "1000000:2000000:performance" > /proc/cpufreq
     to set the frequency of all CPUs between 1 GHz and 2 GHz and to
     the policy "performance".

Please note that the values you "echo" into /proc/cpufreq are
validated first, and may be limited by hardware or thermal
considerations. Because of this, a read from /proc/cpufreq might 
differ from what was written into it.


When you read /proc/cpufreq for the first time after a CPUFreq driver
has been initialized, you'll see the "default policy" for this
driver. If this does not suit your needs, you can pass a boot
parameter to the cpufreq core. Use the following syntax for this:
   "cpufreq=min_freq:max_freq:policy", i.e. you may not chose a
specific CPU and you need to specify the limits in kHz and not in
per cent.





More information about the fedora-test-list mailing list