From: Todd Poynor Date: Thu, 19 Apr 2012 19:52:48 +0000 (-0700) Subject: cpufreq: interactive: based hispeed bump on target freq, not actual X-Git-Tag: firefly_0821_release~7613^2~126 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=4e3800ea447962106a962f5279ea508edd6ca160;p=firefly-linux-kernel-4.4.55.git cpufreq: interactive: based hispeed bump on target freq, not actual For systems that set a common speed for all CPUs, checking current speed here could bypass the intermediate hispeed bump decision for this CPU when another CPU was already at hispeed. This could result in an overly high setting (for all CPUs) in situations where all CPUs were about to drop to load levels that map to hispeed or below. Change-Id: I186f23dcfc5e2b6336cab8b0327f0c8a9a4482bc Signed-off-by: Todd Poynor --- diff --git a/drivers/cpufreq/cpufreq_interactive.c b/drivers/cpufreq/cpufreq_interactive.c index c9f348f966d6..6a9f6c23ae64 100644 --- a/drivers/cpufreq/cpufreq_interactive.c +++ b/drivers/cpufreq/cpufreq_interactive.c @@ -174,7 +174,7 @@ static void cpufreq_interactive_timer(unsigned long data) cpu_load = load_since_change; if (cpu_load >= go_hispeed_load) { - if (pcpu->policy->cur == pcpu->policy->min) { + if (pcpu->target_freq <= pcpu->policy->min) { new_freq = hispeed_freq; } else { new_freq = pcpu->policy->max * cpu_load / 100;