]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/amd/pm/smu7: Fix AC/DC switch notification
authorTimur Kristóf <timur.kristof@gmail.com>
Sun, 12 Jul 2026 17:39:28 +0000 (19:39 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 17 Jul 2026 21:40:43 +0000 (17:40 -0400)
commitec917f19ff1077709e1c4aa7926c7451106080d0
tree0c10372e8e89137808c98fdc47b6e7246f7c3d83
parent0148ac33547b9af1c5a7f3bb6e5baffcb6e9fac2
drm/amd/pm/smu7: Fix AC/DC switch notification

There were two mistakes in the previous implementation:

The check for AutomaticDCTransition should be inverted.
We recently learned that the kernel should send
PPSMC_MSG_RunningOnAC when the flag is set, and not the
other way around.

The clocks also need to be recomputed, because the code in
the smu7_apply_state_adjust_rules() function selects
different limits on AC and DC.

Fixes: 96da0d86614e ("drm/amd/pm/smu7: Notify SMU7 of DC->AC switch")
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit 516f8fc30a1b56af03f39e93c18707d13419fb1f)
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c