summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorAndrew Morton <akpm@linux-foundation.org>2007-07-09 11:35:27 -0700
committerDave Jones <davej@redhat.com>2007-07-13 01:29:51 -0400
commitaac22d0a79f51d7bd93145be36322baaa4b423f8 (patch)
tree95ac9788e4dcb0335a5e41c284afd0178a30963f /arch
parent68485695e5a84399da7b48b208ac42623fe22963 (diff)
downloadop-kernel-dev-aac22d0a79f51d7bd93145be36322baaa4b423f8.zip
op-kernel-dev-aac22d0a79f51d7bd93145be36322baaa4b423f8.tar.gz
[CPUFREQ] powernow-k8 compile fix.
Make it compile on UP. Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Dave Jones <davej@redhat.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/i386/kernel/cpu/cpufreq/powernow-k8.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/i386/kernel/cpu/cpufreq/powernow-k8.c b/arch/i386/kernel/cpu/cpufreq/powernow-k8.c
index 9773368..93192d7 100644
--- a/arch/i386/kernel/cpu/cpufreq/powernow-k8.c
+++ b/arch/i386/kernel/cpu/cpufreq/powernow-k8.c
@@ -1322,16 +1322,21 @@ static struct cpufreq_driver cpufreq_amd64_driver = {
static int __cpuinit powernowk8_init(void)
{
unsigned int i, supported_cpus = 0;
+ unsigned int booted_cores = 1;
for_each_online_cpu(i) {
if (check_supported_cpu(i))
supported_cpus++;
}
+#ifdef CONFIG_SMP
+ booted_cores = cpu_data[0].booted_cores;
+#endif
+
if (supported_cpus == num_online_cpus()) {
printk(KERN_INFO PFX "Found %d %s "
"processors (%d cpu cores) (" VERSION ")\n",
- supported_cpus/cpu_data[0].booted_cores,
+ supported_cpus/booted_cores,
boot_cpu_data.x86_model_id, supported_cpus);
return cpufreq_register_driver(&cpufreq_amd64_driver);
}
OpenPOWER on IntegriCloud