[Intel-gfx] [PATCH 10/10] drm/i915: Move FEC enable timeout wait to enable_ddi_dp

Maarten Lankhorst maarten.lankhorst at linux.intel.com
Wed Aug 21 13:32:21 UTC 2019


Even without bigjoiner I get a timeout when enabling FEC, the length of the timeout
doesn't matter, still happens with 10s timeout.

It seems that DP-MST waits for ACT in enable_dp() so we
could postpone it in normal bringup in a similar way, just to be sure.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst at linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_ddi.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_ddi.c b/drivers/gpu/drm/i915/display/intel_ddi.c
index 81205b75da78..a88348464ffd 100644
--- a/drivers/gpu/drm/i915/display/intel_ddi.c
+++ b/drivers/gpu/drm/i915/display/intel_ddi.c
@@ -3138,10 +3138,6 @@ static void intel_ddi_enable_fec(struct intel_encoder *encoder,
 	val = I915_READ(DP_TP_CTL(port));
 	val |= DP_TP_CTL_FEC_ENABLE;
 	I915_WRITE(DP_TP_CTL(port), val);
-
-	if (intel_de_wait_for_set(dev_priv, DP_TP_STATUS(port),
-				  DP_TP_STATUS_FEC_ENABLE_LIVE, 1))
-		DRM_ERROR("Timed out waiting for FEC Enable Status\n");
 }
 
 static void intel_ddi_disable_fec_state(struct intel_encoder *encoder,
@@ -3473,6 +3469,11 @@ static void intel_enable_ddi_dp(struct intel_encoder *encoder,
 	if (port == PORT_A && INTEL_GEN(dev_priv) < 9)
 		intel_dp_stop_link_train(intel_dp);
 
+	if (crtc_state->fec_enable &&
+	    intel_de_wait_for_set(dev_priv, DP_TP_STATUS(port),
+				  DP_TP_STATUS_FEC_ENABLE_LIVE, 1))
+		DRM_ERROR("Timed out waiting for FEC Enable Status\n");
+
 	intel_edp_backlight_on(crtc_state, conn_state);
 	intel_psr_enable(intel_dp, crtc_state);
 	intel_dp_ycbcr_420_enable(intel_dp, crtc_state);
-- 
2.20.1



More information about the Intel-gfx mailing list