drm/amd/display: fix issue with eDP not detected on driver load
authorAnthony Koo <Anthony.Koo@amd.com>
Thu, 23 May 2019 01:17:38 +0000 (21:17 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 11 Jun 2019 17:50:05 +0000 (12:50 -0500)
commitabe882a39a9c8c7b95839451088268fcbf2b14fa
treefc62b960214bcacd8cd0e67d4a20f998f014a16c
parent7cd4b70091a5cfa1f58d3a529535304a116acc95
drm/amd/display: fix issue with eDP not detected on driver load

[Why]
HPD not going to be high if Panel VDD is off
And all AUX transaction will fail :(

[How]
1. Power on VDD before attempting detection if it isn't already on
2. Improve the robustness by having a retry mechanism on the
first DPCD read after VDD on. If a particular board always holds
HPD high incorrectly, the AUX access may fail, so we can retry
in those scenarios. This change would only improve logic
since it prevents AUX failure leading to bad resolution on internal
panel.
3. We should never need to re-detect internal panel, so logic
is re-arranged a bit to skip earlier.

Signed-off-by: Anthony Koo <Anthony.Koo@amd.com>
Reviewed-by: Jun Lei <Jun.Lei@amd.com>
Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/core/dc_link.c