aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/cpufreq/powernow-k8.c24
1 files changed, 14 insertions, 10 deletions
diff --git a/drivers/cpufreq/powernow-k8.c b/drivers/cpufreq/powernow-k8.c
index e2defb822bb1..f1035a920b0a 100644
--- a/drivers/cpufreq/powernow-k8.c
+++ b/drivers/cpufreq/powernow-k8.c
@@ -1576,9 +1576,6 @@ static int __cpuinit powernowk8_init(void)
1576 if (supported_cpus != num_online_cpus()) 1576 if (supported_cpus != num_online_cpus())
1577 return -ENODEV; 1577 return -ENODEV;
1578 1578
1579 printk(KERN_INFO PFX "Found %d %s (%d cpu cores) (" VERSION ")\n",
1580 num_online_nodes(), boot_cpu_data.x86_model_id, supported_cpus);
1581
1582 if (boot_cpu_has(X86_FEATURE_CPB)) { 1579 if (boot_cpu_has(X86_FEATURE_CPB)) {
1583 1580
1584 cpb_capable = true; 1581 cpb_capable = true;
@@ -1597,16 +1594,23 @@ static int __cpuinit powernowk8_init(void)
1597 struct msr *reg = per_cpu_ptr(msrs, cpu); 1594 struct msr *reg = per_cpu_ptr(msrs, cpu);
1598 cpb_enabled |= !(!!(reg->l & BIT(25))); 1595 cpb_enabled |= !(!!(reg->l & BIT(25)));
1599 } 1596 }
1600
1601 printk(KERN_INFO PFX "Core Performance Boosting: %s.\n",
1602 (cpb_enabled ? "on" : "off"));
1603 } 1597 }
1604 1598
1605 rv = cpufreq_register_driver(&cpufreq_amd64_driver); 1599 rv = cpufreq_register_driver(&cpufreq_amd64_driver);
1606 if (rv < 0 && boot_cpu_has(X86_FEATURE_CPB)) { 1600
1607 unregister_cpu_notifier(&cpb_nb); 1601 if (!rv)
1608 msrs_free(msrs); 1602 pr_info(PFX "Found %d %s (%d cpu cores) (" VERSION ")\n",
1609 msrs = NULL; 1603 num_online_nodes(), boot_cpu_data.x86_model_id,
1604 supported_cpus);
1605
1606 if (boot_cpu_has(X86_FEATURE_CPB)) {
1607 if (rv < 0) {
1608 unregister_cpu_notifier(&cpb_nb);
1609 msrs_free(msrs);
1610 msrs = NULL;
1611 } else
1612 pr_info(PFX "Core Performance Boosting: %s.\n",
1613 (cpb_enabled ? "on" : "off"));
1610 } 1614 }
1611 return rv; 1615 return rv;
1612} 1616}