Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1b5e5a89 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "soc: qcom: rq_stats: Pass correct cpu id to update_average_load function"

parents a4190627 2bcc0af4
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -71,7 +71,7 @@ static int update_average_load(unsigned int freq, unsigned int cpu)
	pcpu->prev_cpu_idle = cur_idle_time;


	if (unlikely(!wall_time || wall_time < idle_time))
	if (unlikely(wall_time <= 0 || wall_time < idle_time))
		return 0;

	cur_load = 100 * (wall_time - idle_time) / wall_time;
@@ -129,7 +129,7 @@ static int cpufreq_transition_handler(struct notifier_block *nb,
		for_each_cpu(j, this_cpu->related_cpus) {
			struct cpu_load_data *pcpu = &per_cpu(cpuload, j);
			mutex_lock(&pcpu->cpu_load_mutex);
			update_average_load(freqs->old, freqs->cpu);
			update_average_load(freqs->old, j);
			pcpu->cur_freq = freqs->new;
			mutex_unlock(&pcpu->cpu_load_mutex);
		}