Skip to content

Commit 1fc9d8f

Browse files
superm1gregkh
authored andcommitted
drm/amd: Restore cached power limit during resume
commit ed4efe4 upstream. The power limit will be cached in smu->current_power_limit but if the ASIC goes into S3 this value won't be restored. Restore the value during SMU resume. Acked-by: Alex Deucher <alexander.deucher@amd.com> Link: https://lore.kernel.org/r/20250725031222.3015095-2-superm1@kernel.org Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 26a609e) Cc: stable@vger.kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 9225818 commit 1fc9d8f

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2153,6 +2153,12 @@ static int smu_resume(void *handle)
21532153

21542154
adev->pm.dpm_enabled = true;
21552155

2156+
if (smu->current_power_limit) {
2157+
ret = smu_set_power_limit(smu, smu->current_power_limit);
2158+
if (ret && ret != -EOPNOTSUPP)
2159+
return ret;
2160+
}
2161+
21562162
dev_info(adev->dev, "SMU is resumed successfully!\n");
21572163

21582164
return 0;

0 commit comments

Comments
 (0)