linux-yocto/kernel/sched
Rafael J. Wysocki 0819b7c062 cpufreq/sched: Fix the usage of CPUFREQ_NEED_UPDATE_LIMITS
[ Upstream commit cfde542df7 ]

Commit 8e461a1cb4 ("cpufreq: schedutil: Fix superfluous updates caused
by need_freq_update") modified sugov_should_update_freq() to set the
need_freq_update flag only for drivers with CPUFREQ_NEED_UPDATE_LIMITS
set, but that flag generally needs to be set when the policy limits
change because the driver callback may need to be invoked for the new
limits to take effect.

However, if the return value of cpufreq_driver_resolve_freq() after
applying the new limits is still equal to the previously selected
frequency, the driver callback needs to be invoked only in the case
when CPUFREQ_NEED_UPDATE_LIMITS is set (which means that the driver
specifically wants its callback to be invoked every time the policy
limits change).

Update the code accordingly to avoid missing policy limits changes for
drivers without CPUFREQ_NEED_UPDATE_LIMITS.

Fixes: 8e461a1cb4 ("cpufreq: schedutil: Fix superfluous updates caused by need_freq_update")
Closes: https://lore.kernel.org/lkml/Z_Tlc6Qs-tYpxWYb@linaro.org/
Reported-by: Stephan Gerhold <stephan.gerhold@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Christian Loehle <christian.loehle@arm.com>
Link: https://patch.msgid.link/3010358.e9J7NaK4W3@rjwysocki.net
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-04-25 10:43:51 +02:00
..
autogroup.c
autogroup.h
build_policy.c
build_utility.c
clock.c
completion.c
core_sched.c
core.c sched: Clarify wake_up_q()'s write to task->wake_q.next 2025-03-28 21:58:51 +01:00
cpuacct.c
cpudeadline.c
cpudeadline.h
cpufreq_schedutil.c cpufreq/sched: Fix the usage of CPUFREQ_NEED_UPDATE_LIMITS 2025-04-25 10:43:51 +02:00
cpufreq.c
cpupri.c sched/rt: Fix live lock between select_fallback_rq() and RT push 2023-10-06 14:57:02 +02:00
cpupri.h
cputime.c sched/cputime: Fix mul_u64_u64_div_u64() precision for cputime 2024-08-14 13:52:50 +02:00
deadline.c sched/deadline: Use online cpus for validating runtime 2025-04-10 14:33:39 +02:00
debug.c
fair.c sched/fair: Fix potential memory corruption in child_cfs_rq_on_list 2025-03-13 12:53:19 +01:00
features.h
idle.c kernel/sched: Modify initial boot task idle setup 2023-10-06 14:57:02 +02:00
isolation.c sched/isolation: Fix boot crash when maxcpus < first housekeeping CPU 2024-06-12 11:03:00 +02:00
loadavg.c
Makefile
membarrier.c sched/membarrier: reduce the ability to hammer on sys_membarrier 2024-02-23 09:12:52 +01:00
pelt.c
pelt.h
psi.c sched: psi: fix bogus pressure spikes from aggregation race 2024-10-17 15:22:06 +02:00
rt.c sched/rt: sysctl_sched_rr_timeslice show default timeslice after reset 2024-03-01 13:26:24 +01:00
sched-pelt.h
sched.h sched/fair: set_load_weight() must also call reweight_task() for SCHED_IDLE tasks 2024-08-03 08:49:31 +02:00
smp.h
stats.c profiling: remove profile=sleep support 2024-08-14 13:52:50 +02:00
stats.h sched/psi: Use task->psi_flags to clear in CPU migration 2025-02-21 13:48:54 +01:00
stop_task.c
swait.c
topology.c sched/fair: Allow disabling sched_balance_newidle with sched_relax_domain_level 2024-06-12 11:03:33 +02:00
wait_bit.c
wait.c wait: Return number of exclusive waiters awaken 2023-03-10 09:34:34 +01:00