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

Commit d8c5bfcc authored by Pavankumar Kondeti's avatar Pavankumar Kondeti
Browse files

sched: Make sure window start passed to schedutil is consistent



The scheduler sends some notifications for individual CPUs. If these
events happen close to the window boundary, the window_start passed
to schedutil may go out of order.

Change-Id: Ib6338bd4bc3b1c41c424ec959056c57c0ed7507e
Signed-off-by: default avatarPavankumar Kondeti <pkondeti@codeaurora.org>
parent ccf21f85
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -1870,7 +1870,7 @@ cpu_util_freq_walt(int cpu, struct sched_walt_cpu_load *walt_load)
		walt_load->prev_window_util = util;
		walt_load->nl = nl;
		walt_load->pl = pl;
		walt_load->ws = rq->window_start;
		walt_load->ws = rq->load_reported_window;
	}

	return (util >= capacity) ? capacity : util;
@@ -2318,6 +2318,7 @@ static inline void cpufreq_update_util(struct rq *rq, unsigned int flags)
		(rq->load_reported_window == rq->window_start) &&
		!(flags & exception_flags))
		return;
	if (!(flags & exception_flags))
		rq->load_reported_window = rq->window_start;
#endif