[CPUFREQ] Fix another notifier leak in powernow-k8.
[deliverable/linux.git] / arch / x86 / kernel / cpu / cpufreq / powernow-k8.c
index 302963fb4dc3438d6a8f5f11d03852a239c4d2f2..c567dec854f69f865bc92105c55cc7066cc06c6e 100644 (file)
@@ -1556,14 +1556,14 @@ static int __cpuinit powernowk8_init(void)
 
                cpb_capable = true;
 
-               register_cpu_notifier(&cpb_nb);
-
                msrs = msrs_alloc();
                if (!msrs) {
                        printk(KERN_ERR "%s: Error allocating msrs!\n", __func__);
                        return -ENOMEM;
                }
 
+               register_cpu_notifier(&cpb_nb);
+
                rdmsr_on_cpus(cpu_online_mask, MSR_K7_HWCR, msrs);
 
                for_each_cpu(cpu, cpu_online_mask) {
This page took 0.024752 seconds and 5 git commands to generate.