cpufreq: Don't unnecessarily call set_boost()

The policy specific boost value may already be set correctly in
cpufreq_boost_trigger_state(), don't update it again unnecessarily.

Reviewed-by: Lifeng Zheng <zhenglifeng1@huawei.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Link: https://patch.msgid.link/3003fbdcc1850128fe7fb653d7ddb8afc4d66170.1745511526.git.viresh.kumar@linaro.org
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
Viresh Kumar
2025-04-24 21:50:15 +05:30
committed by Rafael J. Wysocki
parent 3b4628a8af
commit c347f31ae2

View File

@@ -2807,7 +2807,7 @@ static int cpufreq_boost_trigger_state(int state)
cpus_read_lock();
for_each_active_policy(policy) {
if (!policy->boost_supported)
if (!policy->boost_supported || policy->boost_enabled == state)
continue;
policy->boost_enabled = state;