]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
cpufreq/amd-pstate: Remove the unncecessary driver_lock in amd_pstate_update_limits
authorDhananjay Ugwekar <dhananjay.ugwekar@amd.com>
Wed, 5 Feb 2025 11:25:23 +0000 (11:25 +0000)
committerMario Limonciello <mario.limonciello@amd.com>
Mon, 24 Feb 2025 00:54:56 +0000 (18:54 -0600)
There is no need to take a driver wide lock while updating the
highest_perf value in the percpu cpudata struct. Hence remove it.

Signed-off-by: Dhananjay Ugwekar <dhananjay.ugwekar@amd.com>
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>
Reviewed-by: Gautham R. Shenoy <gautham.shenoy@amd.com>
Link: https://lore.kernel.org/r/20250205112523.201101-13-dhananjay.ugwekar@amd.com
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
drivers/cpufreq/amd-pstate.c

index ee7e3f0a4c0a360cf54427c36f6f0cc416628e5e..08ae480768120acac14fc2ed22aef1890cf29d45 100644 (file)
@@ -832,8 +832,6 @@ static void amd_pstate_update_limits(unsigned int cpu)
        if (!policy)
                return;
 
-       guard(mutex)(&amd_pstate_driver_lock);
-
        if (amd_get_highest_perf(cpu, &cur_high))
                return;