]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
intel_pstate: fix no_turbo
authorSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Tue, 1 Oct 2013 17:28:41 +0000 (10:28 -0700)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 1 Oct 2013 20:51:11 +0000 (22:51 +0200)
When sysfs for no_turbo is set, then also some p states in turbo regions
are observed. This patch will set IDA Engage bit when no_turbo is set to
explicitly disengage turbo.

Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Acked-by: Dirk Brandewie <dirk.j.brandewie@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/cpufreq/intel_pstate.c

index 9733f29ed148f840a35171df38e32cbd1ce7bca8..32b3479a24051d09a0c1c53647b74848fcb3c967 100644 (file)
@@ -394,7 +394,10 @@ static void intel_pstate_set_pstate(struct cpudata *cpu, int pstate)
        trace_cpu_frequency(pstate * 100000, cpu->cpu);
 
        cpu->pstate.current_pstate = pstate;
-       wrmsrl(MSR_IA32_PERF_CTL, pstate << 8);
+       if (limits.no_turbo)
+               wrmsrl(MSR_IA32_PERF_CTL, BIT(32) | (pstate << 8));
+       else
+               wrmsrl(MSR_IA32_PERF_CTL, pstate << 8);
 
 }