Merge tag 'pm-5.20-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
[linux-2.6-microblaze.git] / drivers / thermal / cpufreq_cooling.c
index dc19e7c..cb75f13 100644 (file)
@@ -146,11 +146,9 @@ static u32 cpu_power_to_freq(struct cpufreq_cooling_device *cpufreq_cdev,
 static u32 get_load(struct cpufreq_cooling_device *cpufreq_cdev, int cpu,
                    int cpu_idx)
 {
-       unsigned long max = arch_scale_cpu_capacity(cpu);
-       unsigned long util;
+       unsigned long util = sched_cpu_util(cpu);
 
-       util = sched_cpu_util(cpu, max);
-       return (util * 100) / max;
+       return (util * 100) / arch_scale_cpu_capacity(cpu);
 }
 #else /* !CONFIG_SMP */
 static u32 get_load(struct cpufreq_cooling_device *cpufreq_cdev, int cpu,