]> git.ipfire.org Git - thirdparty/linux.git/commit
cpufreq/amd-pstate: Add missing NULL ptr check in amd_pstate_update
authorDhananjay Ugwekar <dhananjay.ugwekar@amd.com>
Wed, 5 Feb 2025 11:25:21 +0000 (11:25 +0000)
committerMario Limonciello <mario.limonciello@amd.com>
Mon, 24 Feb 2025 00:54:56 +0000 (18:54 -0600)
commit426db24d4db2e4f0d6720aeb7795eafcb9e82640
tree4de7d63eead3347b165e7151b189a741719167bd
parentb899434857b0f1ab460b3c126cbed82ab9b52d43
cpufreq/amd-pstate: Add missing NULL ptr check in amd_pstate_update

Check if policy is NULL before dereferencing it in amd_pstate_update.

Fixes: e8f555daacd3 ("cpufreq/amd-pstate: fix setting policy current frequency value")
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-11-dhananjay.ugwekar@amd.com
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
drivers/cpufreq/amd-pstate.c