thermal: Replace deprecated CPU-hotplug functions.
[linux-2.6-microblaze.git] / drivers / thermal / intel / intel_powerclamp.c
index b0eb5ec..a5b58ea 100644 (file)
@@ -528,7 +528,7 @@ static int start_power_clamp(void)
 
        set_target_ratio = clamp(set_target_ratio, 0U, MAX_TARGET_RATIO - 1);
        /* prevent cpu hotplug */
 
        set_target_ratio = clamp(set_target_ratio, 0U, MAX_TARGET_RATIO - 1);
        /* prevent cpu hotplug */
-       get_online_cpus();
+       cpus_read_lock();
 
        /* prefer BSP */
        control_cpu = 0;
 
        /* prefer BSP */
        control_cpu = 0;
@@ -542,7 +542,7 @@ static int start_power_clamp(void)
        for_each_online_cpu(cpu) {
                start_power_clamp_worker(cpu);
        }
        for_each_online_cpu(cpu) {
                start_power_clamp_worker(cpu);
        }
-       put_online_cpus();
+       cpus_read_unlock();
 
        return 0;
 }
 
        return 0;
 }