drm/amd/display: Move wait for hpd ready out from edp power control.
authorYongqiang Sun <yongqiang.sun@amd.com>
Fri, 24 Nov 2017 21:31:03 +0000 (16:31 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 14 Dec 2017 16:00:35 +0000 (11:00 -0500)
commit904623ee5936e2226009b2f238f28781aecd2565
treebba0b5b3e1634df87d77ba0949fc75742dd08bf9
parent73da927b083737a8923c1bbc850274adffca1257
drm/amd/display: Move wait for hpd ready out from edp power control.

It may take over 200ms for wait hpd ready. To optimize the resume time,
we can power on eDP in init_hw, wait for hpd ready when doing link
training.

also create separate eDP enable function to make sure eDP is powered up
before doing and DPCD access, as HPD low will result in DPDC transaction
failure.

After optimization,
setpowerstate 145ms -> 9.8ms,
DPMS 387ms -> 18.9ms

Signed-off-by: Yongqiang Sun <yongqiang.sun@amd.com>
Signed-off-by: Tony Cheng <tony.cheng@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/core/dc_link.c
drivers/gpu/drm/amd/display/dc/core/dc_link_hwss.c
drivers/gpu/drm/amd/display/dc/dce/dce_link_encoder.c
drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.h
drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c
drivers/gpu/drm/amd/display/dc/inc/hw_sequencer.h