aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorNaga Chumbalkar <nagananda.chumbalkar@hp.com>2009-06-11 11:26:54 -0400
committerDave Jones <davej@redhat.com>2009-06-15 11:49:42 -0400
commite15bc4559b397a611441a135b1f5992f07d0f436 (patch)
treecb657e9af69aeaa281d4780cf05877f4f95b4837 /arch
parent532cfee6ba0a8efcf7c3ce38b9881292d79d516e (diff)
[CPUFREQ] powernow-k8: get drv data for correct CPU
Make powernowk8_get() similar to powernowk8_target() and powernowk8_verify() in the way it obtains "powernow_data" for a given CPU. Cc: Andreas Herrmann <andreas.herrmann3@amd.com> Cc: Langsdorf, Mark <mark.langsdorf@amd.com> Cc: Thomas Renninger <trenn@suse.de> Signed-off-by: Naga Chumbalkar <nagananda.chumbalkar@hp.com> Reviewed-by: Andreas Herrmann <andreas.herrmann3@amd.com> Tested-by: Andreas Herrmann <andreas.herrmann3@amd.com> Acked-by: Langsdorf, Mark <mark.langsdorf@amd.com> Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Dave Jones <davej@redhat.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/kernel/cpu/cpufreq/powernow-k8.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/arch/x86/kernel/cpu/cpufreq/powernow-k8.c b/arch/x86/kernel/cpu/cpufreq/powernow-k8.c
index 331021112f2b..20c7b99d7ba8 100644
--- a/arch/x86/kernel/cpu/cpufreq/powernow-k8.c
+++ b/arch/x86/kernel/cpu/cpufreq/powernow-k8.c
@@ -1385,13 +1385,9 @@ static int __devexit powernowk8_cpu_exit(struct cpufreq_policy *pol)
1385 1385
1386static unsigned int powernowk8_get(unsigned int cpu) 1386static unsigned int powernowk8_get(unsigned int cpu)
1387{ 1387{
1388 struct powernow_k8_data *data; 1388 struct powernow_k8_data *data = per_cpu(powernow_data, cpu);
1389 cpumask_t oldmask = current->cpus_allowed; 1389 cpumask_t oldmask = current->cpus_allowed;
1390 unsigned int khz = 0; 1390 unsigned int khz = 0;
1391 unsigned int first;
1392
1393 first = cpumask_first(cpu_core_mask(cpu));
1394 data = per_cpu(powernow_data, first);
1395 1391
1396 if (!data) 1392 if (!data)
1397 return -EINVAL; 1393 return -EINVAL;