Re: [PATCH RFC 3/5] cpufreq: schedutil: Use idle_calls counter of the remote CPU

From: Viresh Kumar
Date: Mon Oct 30 2017 - 05:18:37 EST


On 28-10-17, 02:59, Joel Fernandes wrote:
> Since the recent remote cpufreq callback work, its possible that a cpufreq
> update is triggered from a remote CPU. For single policies however, the current
> code uses the local CPU when trying to determine if the remote sg_cpu entered
> idle or is busy. This is incorrect. To remedy this, compare with the nohz tick
> idle_calls counter of the remote CPU.
>
> Cc: Rafael J. Wysocki <rjw@xxxxxxxxxxxxx>
> Cc: Viresh Kumar <viresh.kumar@xxxxxxxxxx>
> Cc: Ingo Molnar <mingo@xxxxxxxxxx>
> Cc: Peter Zijlstra <peterz@xxxxxxxxxxxxx>
> Cc: Frederic Weisbecker <fweisbec@xxxxxxxxx>
> Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx>

Fixes: 674e75411fc2 ("sched: cpufreq: Allow remote cpufreq callbacks")

> Signed-off-by: Joel Fernandes <joelaf@xxxxxxxxxx>
> ---
> include/linux/tick.h | 1 +
> kernel/sched/cpufreq_schedutil.c | 2 +-
> kernel/time/tick-sched.c | 13 +++++++++++++
> 3 files changed, 15 insertions(+), 1 deletion(-)

Acked-by: Viresh Kumar <viresh.kumar@xxxxxxxxxx>

--
viresh