]> git.karo-electronics.de Git - linux-beck.git/commit
cpufreq: Fix cpufreq regression after suspend/resume
authorSrivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Sun, 30 Jun 2013 22:40:55 +0000 (00:40 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Sun, 30 Jun 2013 22:40:55 +0000 (00:40 +0200)
commitf51e1eb63d9c28cec188337ee656a13be6980cfd
tree9727fe247814aea091dd2579589341cd46a08bab
parent419e172145cf6c51d436a8bf4afcd17511f0ff79
cpufreq: Fix cpufreq regression after suspend/resume

Toralf Förster reported that the cpufreq ondemand governor behaves erratically
(doesn't scale well) after a suspend/resume cycle. The problem was that the
cpufreq subsystem's idea of the cpu frequencies differed from the actual
frequencies set in the hardware after a suspend/resume cycle. Toralf bisected
the problem to commit a66b2e5 (cpufreq: Preserve sysfs files across
suspend/resume).

Among other (harmless) things, that commit skipped the call to
cpufreq_update_policy() in the resume path. But cpufreq_update_policy() plays
an important role during resume, because it is responsible for checking if
the BIOS changed the cpu frequencies behind our back and resynchronize the
cpufreq subsystem's knowledge of the cpu frequencies, and update them
accordingly.

So, restore the call to cpufreq_update_policy() in the resume path to fix
the cpufreq regression.

Reported-and-tested-by: Toralf Förster <toralf.foerster@gmx.de>
Signed-off-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Cc: 3.10+ <stable@vger.kernel.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/cpufreq/cpufreq_stats.c