Skip to content

Commit c1fe9f6

Browse files
committed
cpufreq/amd-pstate: Fix per-policy boost flag incorrect when fail
JIRA: https://issues.redhat.com/browse/RHEL-75923 commit fa80351 Author: Lifeng Zheng <zhenglifeng1@huawei.com> Date: Fri Jan 10 17:19:49 2025 +0800 cpufreq/amd-pstate: Fix per-policy boost flag incorrect when fail Commit c8c68c3 ("cpufreq: amd-pstate: initialize core precision boost state") sets per-policy boost flag to false when boost fail. However, this boost flag will be set to reverse value in store_local_boost() and cpufreq_boost_trigger_state() in cpufreq.c. This will cause the per-policy boost flag set to true when fail to set boost. Remove the extra assignment in amd_pstate_set_boost() and keep all operations on per-policy boost flag outside of set_boost() to fix this problem. Fixes: c8c68c3 ("cpufreq: amd-pstate: initialize core precision boost state") Signed-off-by: Lifeng Zheng <zhenglifeng1@huawei.com> Reviewed-by: Mario Limonciello <mario.limonciello@amd.com> Link: https://lore.kernel.org/r/20250110091949.3610770-1-zhenglifeng1@huawei.com Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Signed-off-by: David Arcari <darcari@redhat.com>
1 parent 29bc1fa commit c1fe9f6

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

drivers/cpufreq/amd-pstate.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -747,7 +747,6 @@ static int amd_pstate_set_boost(struct cpufreq_policy *policy, int state)
747747
guard(mutex)(&amd_pstate_driver_lock);
748748

749749
ret = amd_pstate_cpu_boost_update(policy, state);
750-
policy->boost_enabled = !ret ? state : false;
751750
refresh_frequency_limits(policy);
752751

753752
return ret;

0 commit comments

Comments
 (0)