Link detection may fail after suspend/resume when the display is "slow to wake up", and it may happen on boot as well.
Let's retry link detection in those cases too. Signed-off-by: Timur Kristóf <[email protected]> --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index 8bda79c26288..1ddf77b08626 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -3954,6 +3954,10 @@ static int dm_resume(struct amdgpu_ip_block *ip_block) if (ret) { /* w/a delay for certain panels */ apply_delay_after_dpcd_poweroff(adev, aconnector->dc_sink); + } else { + dm_queue_delayed_hpd_work(aconnector, + DETECT_REASON_RESUMEFROMS3S4, + AMDGPU_DM_HPD_RETRY_DELAY_MSEC); } } @@ -5979,6 +5983,10 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev) link->dpcd_caps.psr_info.psr_dpcd_caps.raw, link->dpcd_caps.psr_info.psr2_su_y_granularity_cap); } + } else { + dm_queue_delayed_hpd_work(aconnector, + DETECT_REASON_BOOT, + AMDGPU_DM_HPD_RETRY_DELAY_MSEC); } } amdgpu_set_panel_orientation(&aconnector->base); -- 2.54.0
