diff options
author | Perry Yuan <perry.yuan@amd.com> | 2023-01-10 18:10:29 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-01-18 13:58:12 +0300 |
commit | ba518c5b6429ed7273e26bff318b92bd27857e4b (patch) | |
tree | 0c205b71cb9243ea234df0d45e680590f4ff56d9 /arch | |
parent | 80a82f6eb3b75c8bb02ada8f7f55efca08b74eec (diff) | |
download | linux-ba518c5b6429ed7273e26bff318b92bd27857e4b.tar.xz |
cpufreq: amd-pstate: fix kernel hang issue while amd-pstate unregistering
commit 4f3085f87b51a551a0647f218d4f324796ecb703 upstream.
In the amd_pstate_adjust_perf(), there is one cpufreq_cpu_get() call to
increase increments the kobject reference count of policy and make it as
busy. Therefore, a corresponding call to cpufreq_cpu_put() is needed to
decrement the kobject reference count back, it will resolve the kernel
hang issue when unregistering the amd-pstate driver and register the
`amd_pstate_epp` driver instance.
Fixes: 1d215f0319 ("cpufreq: amd-pstate: Add fast switch function for AMD P-State")
Acked-by: Huang Rui <ray.huang@amd.com>
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>
Tested-by: Wyes Karny <wyes.karny@amd.com>
Signed-off-by: Perry Yuan <perry.yuan@amd.com>
Cc: 5.17+ <stable@vger.kernel.org> # 5.17+
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions