lkml.org 
[lkml]   [2021]   [Feb]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] cpufreq: schedutil: Call sugov_update_next_freq() before check to fast_switch_enabled
On 24-02-21, 14:39, Yue Hu wrote:
> From: Yue Hu <huyue2@yulong.com>
>
> Note that sugov_update_next_freq() may return false, that means the
> caller sugov_fast_switch() will do nothing except fast switch check.
>
> Similarly, sugov_deferred_update() also has unnecessary operations
> of raw_spin_{lock,unlock} in sugov_update_single_freq() for that case.
>
> So, let's call sugov_update_next_freq() before the fast switch check
> to avoid unnecessary behaviors above. Accordingly, update interface
> definition to sugov_deferred_update() and remove sugov_fast_switch()
> since we will call cpufreq_driver_fast_switch() directly instead.
>
> Signed-off-by: Yue Hu <huyue2@yulong.com>
> ---
> v2: remove sugov_fast_switch() and call cpufreq_driver_fast_switch()
> directly instead, also update minor log message.
>
> kernel/sched/cpufreq_schedutil.c | 29 ++++++++++++-----------------
> 1 file changed, 12 insertions(+), 17 deletions(-)

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

\
 
 \ /
  Last update: 2021-02-24 07:48    [W:0.117 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site