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

Commit 2a699361 authored by Vikram Mulukutla's avatar Vikram Mulukutla
Browse files

sched: hmp: Reduce number of load reports in a window



There's no use reporting load more than once in a window
via the cpufreq_update_util path (unless there's a migration).
Set the load_reported_window flag in sched_get_cpus_busy
to remove these redundant updates.

Change-Id: If43dd5abc7e0e52a8e0f0df3a20ca99ed92f5361
Signed-off-by: default avatarVikram Mulukutla <markivx@codeaurora.org>
parent 436b4a5f
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -3180,6 +3180,13 @@ void sched_get_cpus_busy(struct sched_load *busy,
		update_task_ravg(rq->curr, rq, TASK_UPDATE, sched_ktime_clock(),
				 0);

		/*
		 * Ensure that we don't report load for 'cpu' again via the
		 * cpufreq_update_util path in the window that started at
		 * rq->window_start
		 */
		rq->load_reported_window = rq->window_start;

		account_load_subtractions(rq);
		load[i] = rq->prev_runnable_sum;
		nload[i] = rq->nt_prev_runnable_sum;