Skip to content

Commit 79bc412

Browse files
effective-lightalexdeucher
authored andcommitted
drm/amd/display: fix hibernate entry for DCN35+
Since, two suspend-resume cycles are required to enter hibernate and, since we only need to enable idle optimizations in the first cycle (which is pretty much equivalent to s2idle). We can check in_s0ix, to prevent the system from entering idle optimizations before it actually enters hibernate (from display's perspective). Also, call dc_set_power_state() before dc_allow_idle_optimizations(), since it's safer to do so because dc_set_power_state() writes to DMUB. Acked-by: Alex Deucher <[email protected]> Signed-off-by: Hamza Mahfooz <[email protected]> Signed-off-by: Alex Deucher <[email protected]> (cherry picked from commit 2fe7950) Cc: [email protected] # 6.10+
1 parent 0a9906c commit 79bc412

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2972,10 +2972,11 @@ static int dm_suspend(void *handle)
29722972

29732973
hpd_rx_irq_work_suspend(dm);
29742974

2975-
if (adev->dm.dc->caps.ips_support)
2976-
dc_allow_idle_optimizations(adev->dm.dc, true);
2977-
29782975
dc_set_power_state(dm->dc, DC_ACPI_CM_POWER_STATE_D3);
2976+
2977+
if (dm->dc->caps.ips_support && adev->in_s0ix)
2978+
dc_allow_idle_optimizations(dm->dc, true);
2979+
29792980
dc_dmub_srv_set_power_state(dm->dc->ctx->dmub_srv, DC_ACPI_CM_POWER_STATE_D3);
29802981

29812982
return 0;

0 commit comments

Comments
 (0)