Skip to content

Commit 7ebfbc9

Browse files
dhananjay-AMDsmb49
authored andcommitted
cpufreq: amd-pstate: Remove unnecessary driver_lock in set_boost
BugLink: https://bugs.launchpad.net/bugs/2115678 [ Upstream commit db1cafc77aaaf871509da06f4a864e9af6d6791f ] set_boost is a per-policy function call, hence a driver wide lock is unnecessary. Also this mutex_acquire can collide with the mutex_acquire from the mode-switch path in status_store(), which can lead to a deadlock. So, remove it. Signed-off-by: Dhananjay Ugwekar <dhananjay.ugwekar@amd.com> Acked-by: Mario Limonciello <mario.limonciello@amd.com> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Sasha Levin <sashal@kernel.org> CVE-2025-38038 Signed-off-by: Manuel Diewald <manuel.diewald@canonical.com> Signed-off-by: Mehmet Basaran <mehmet.basaran@canonical.com>
1 parent 7897f93 commit 7ebfbc9

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
@@ -746,7 +746,6 @@ static int amd_pstate_set_boost(struct cpufreq_policy *policy, int state)
746746
pr_err("Boost mode is not supported by this processor or SBIOS\n");
747747
return -EOPNOTSUPP;
748748
}
749-
guard(mutex)(&amd_pstate_driver_lock);
750749

751750
ret = amd_pstate_cpu_boost_update(policy, state);
752751
refresh_frequency_limits(policy);

0 commit comments

Comments
 (0)