aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2014-04-16 10:56:09 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-04-16 12:52:47 -0400
commitc79057922ed6c2c6df1214e6ab4414fea1b23db2 (patch)
tree7bef3edde567ac34101708ed932c07054d178cab
parenta5c4d7bc187bd13bc11ac06bb4ea3a0d4001aa4d (diff)
drm/i915: Remove vblank wait from haswell_write_eld
The pipe is off at that point in time, so a vblank wait is simply a 50ms wait. Caught by Jesse's verbose "make vblank wait timeouts WARN" patch. We've probably had a few versions of this float around already. To document assumptions put a pipe assert into the same place. And also add a posting read. If we ever decide to update the eld and infoframes while the pipe is already on (e.g. for fastboot) then there's lots of work to do. So better properly document all the hidden assumptions. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
-rw-r--r--drivers/gpu/drm/i915/intel_display.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index f32c7bccbec7..420070b08ac4 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -7336,7 +7336,6 @@ static void haswell_write_eld(struct drm_connector *connector,
7336{ 7336{
7337 struct drm_i915_private *dev_priv = connector->dev->dev_private; 7337 struct drm_i915_private *dev_priv = connector->dev->dev_private;
7338 uint8_t *eld = connector->eld; 7338 uint8_t *eld = connector->eld;
7339 struct drm_device *dev = crtc->dev;
7340 struct intel_crtc *intel_crtc = to_intel_crtc(crtc); 7339 struct intel_crtc *intel_crtc = to_intel_crtc(crtc);
7341 uint32_t eldv; 7340 uint32_t eldv;
7342 uint32_t i; 7341 uint32_t i;
@@ -7354,9 +7353,9 @@ static void haswell_write_eld(struct drm_connector *connector,
7354 tmp = I915_READ(aud_cntrl_st2); 7353 tmp = I915_READ(aud_cntrl_st2);
7355 tmp |= (AUDIO_OUTPUT_ENABLE_A << (pipe * 4)); 7354 tmp |= (AUDIO_OUTPUT_ENABLE_A << (pipe * 4));
7356 I915_WRITE(aud_cntrl_st2, tmp); 7355 I915_WRITE(aud_cntrl_st2, tmp);
7356 POSTING_READ(aud_cntrl_st2);
7357 7357
7358 /* Wait for 1 vertical blank */ 7358 assert_pipe_disabled(dev_priv, to_intel_crtc(crtc)->pipe);
7359 intel_wait_for_vblank(dev, pipe);
7360 7359
7361 /* Set ELD valid state */ 7360 /* Set ELD valid state */
7362 tmp = I915_READ(aud_cntrl_st2); 7361 tmp = I915_READ(aud_cntrl_st2);