# Can't change CPU freq on 2.6.33 or 34

## PraetorZero

Using gentoo-sources-2.6.33-*, 34 and vanilla-sources 2.6.34, I cannot change the scaling on my CPU.  However, using gentoo-sources-2.6.32, it works fine.

My CPU is a "Genuine Intel(R) CPU           T2300  @ 1.66GHz"

With 2.6.33/34 and acpi_cpufreq loaded, the laptop boots at "cpu MHz		: 1000.000".   I cannot change the governor or speed using cpufreq-utils or the cpufreq-applet.  The applet simply remains at 1 GHz.   If I boot the same kernel but do not load the acpi_cpufreq module, it boots at the full 1667.000-ish speed, I just can't scale it.

I've tried taking my .config from 2.6.32 and running a make oldconfig on 2.6.33 and 2.6.34 without success.  I even jumped over to vanilla-sources 2.6.34 and built the kernel using a clean config without success.

I'm pretty sure this is a problem with the kernel or how I'm configuring it.  Any suggestions?

```

#

# Power management and ACPI options

#

CONFIG_PM=y

CONFIG_PM_DEBUG=y

# CONFIG_PM_ADVANCED_DEBUG is not set

# CONFIG_PM_VERBOSE is not set

CONFIG_CAN_PM_TRACE=y

CONFIG_PM_TRACE=y

CONFIG_PM_TRACE_RTC=y

CONFIG_PM_SLEEP_SMP=y

CONFIG_PM_SLEEP=y

CONFIG_SUSPEND=y

# CONFIG_PM_TEST_SUSPEND is not set

CONFIG_SUSPEND_FREEZER=y

CONFIG_HIBERNATION_NVS=y

CONFIG_HIBERNATION=y

CONFIG_PM_STD_PARTITION="/dev/sda2"

CONFIG_PM_RUNTIME=y

CONFIG_PM_OPS=y

CONFIG_ACPI=y

CONFIG_ACPI_SLEEP=y

CONFIG_ACPI_PROCFS=y

CONFIG_ACPI_PROCFS_POWER=y

# CONFIG_ACPI_POWER_METER is not set

CONFIG_ACPI_SYSFS_POWER=y

CONFIG_ACPI_PROC_EVENT=y

CONFIG_ACPI_AC=y

CONFIG_ACPI_BATTERY=y

CONFIG_ACPI_BUTTON=y

CONFIG_ACPI_VIDEO=y

CONFIG_ACPI_FAN=y

CONFIG_ACPI_DOCK=y

CONFIG_ACPI_PROCESSOR=y

CONFIG_ACPI_HOTPLUG_CPU=y

# CONFIG_ACPI_PROCESSOR_AGGREGATOR is not set

CONFIG_ACPI_THERMAL=y

# CONFIG_ACPI_CUSTOM_DSDT is not set

CONFIG_ACPI_BLACKLIST_YEAR=0

# CONFIG_ACPI_DEBUG is not set

# CONFIG_ACPI_PCI_SLOT is not set

CONFIG_X86_PM_TIMER=y

CONFIG_ACPI_CONTAINER=y

# CONFIG_ACPI_SBS is not set

# CONFIG_SFI is not set

# CONFIG_APM is not set

#

# CPU Frequency scaling

#

CONFIG_CPU_FREQ=y

CONFIG_CPU_FREQ_TABLE=y

CONFIG_CPU_FREQ_DEBUG=y

# CONFIG_CPU_FREQ_STAT is not set

# CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE is not set

# CONFIG_CPU_FREQ_DEFAULT_GOV_POWERSAVE is not set

CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y

# CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND is not set

# CONFIG_CPU_FREQ_DEFAULT_GOV_CONSERVATIVE is not set

CONFIG_CPU_FREQ_GOV_PERFORMANCE=y

CONFIG_CPU_FREQ_GOV_POWERSAVE=y

CONFIG_CPU_FREQ_GOV_USERSPACE=y

CONFIG_CPU_FREQ_GOV_ONDEMAND=y

CONFIG_CPU_FREQ_GOV_CONSERVATIVE=y

#

# CPUFreq processor drivers

#

CONFIG_X86_PCC_CPUFREQ=m

CONFIG_X86_ACPI_CPUFREQ=m

# CONFIG_X86_POWERNOW_K6 is not set

# CONFIG_X86_POWERNOW_K7 is not set

# CONFIG_X86_POWERNOW_K8 is not set

# CONFIG_X86_GX_SUSPMOD is not set

CONFIG_X86_SPEEDSTEP_CENTRINO=m

CONFIG_X86_SPEEDSTEP_CENTRINO_TABLE=y

CONFIG_X86_SPEEDSTEP_ICH=m

CONFIG_X86_SPEEDSTEP_SMI=m

CONFIG_X86_P4_CLOCKMOD=m

# CONFIG_X86_CPUFREQ_NFORCE2 is not set

# CONFIG_X86_LONGRUN is not set

# CONFIG_X86_LONGHAUL is not set

# CONFIG_X86_E_POWERSAVER is not set

#

# shared options

#

CONFIG_X86_SPEEDSTEP_LIB=m

CONFIG_X86_SPEEDSTEP_RELAXED_CAP_CHECK=y

CONFIG_CPU_IDLE=y

CONFIG_CPU_IDLE_GOV_LADDER=y

CONFIG_CPU_IDLE_GOV_MENU=y

```

----------

## BradN

It seems like recent kernels are having some weird problems with various power management (some machines don't power down but reboot instead, some machines power off but back on when you close the lid, and now this...) - It seems like a kernel bug so I would say your best bet for a resolution would be either waiting or doing a bisection test yourself to find exactly what particular change caused it to fail.

A bisection test basically means you take the last kernel you know to work and the first kernel you know to fail, and then take the kernel (from git or whatever they use these days) at the point where the middle change occurred, test that, and then you have ruled out half of the changes one way or the other.  You pick a new midpoint to test and repeat (if there were 1000 changes between your last known working and first known failed, you'll need to build and test about 10 kernels to find the culprit.  A million changes would make you do about 20 tests, so this method is very scalable but still a pain in the ass even with relatively few changes involved).

Once you have the specific change narrowed down, you can submit it to the kernel mailing list and someone will probably fix it for you (they love it when people do the dirty work of tracking down bugs like that for them).

I'm sure there's some page out there describing how you actually do this - I haven't done it myself but I know it's a common practice for tracking this stuff down.

----------

## dmpogo

Can you change, say governor, or frequency, by hand e.g.

see what frequencies and governors you have available

```

cat  /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies

cat  /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors

```

and try to change them, like

```

echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

echo  yournumber > /sys/devices/system/cpu/cpu0/cpufreq/scaling_frequencies

```

Any effect ?

----------

## PraetorZero

Good idea, BradN, that's a bit outside my skill set, but now seems like the perfect time to learn how to do it.

dmpogo:  Changing the governor by hand doesn't do anything.  The speed remains constant at 1GHz. IIRC, it does show the governor that I selected, but that's about it.    Same for specifying the frequency.

----------

## dmpogo

 *PraetorZero wrote:*   

> Good idea, BradN, that's a bit outside my skill set, but now seems like the perfect time to learn how to do it.
> 
> dmpogo:  Changing the governor by hand doesn't do anything.  The speed remains constant at 1GHz. IIRC, it does show the governor that I selected, but that's about it.    Same for specifying the frequency.

 

Just to be completely certain it is a deeper issue, you can see whether this /sys/ entries change when you change frequency/governer with the tools you usually use.

But indeeded, there were threads about cpufreq not working in 2.6.33 and some early 2.6.34's

----------

## PraetorZero

 *dmpogo wrote:*   

>  *PraetorZero wrote:*   Good idea, BradN, that's a bit outside my skill set, but now seems like the perfect time to learn how to do it.
> 
> dmpogo:  Changing the governor by hand doesn't do anything.  The speed remains constant at 1GHz. IIRC, it does show the governor that I selected, but that's about it.    Same for specifying the frequency. 
> 
> Just to be completely certain it is a deeper issue, you can see whether this /sys/ entries change when you change frequency/governer with the tools you usually use.
> ...

 

It doesn't budge.   I ran '/sys/devices/system/cpu/cpu0/cpufreq/scaling_governor' while using cpufreq-set, gnome applet, manually setting via echo > blah blah, no change.

While on 2.6.34, all I get is 1000000

----------

