diff options
author | Rodrigo Vivi <rodrigo.vivi@intel.com> | 2015-11-05 10:50:22 -0800 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2015-11-18 11:24:27 +0100 |
commit | 6d8175da1f449520373945ecbcf7c733cc07df1c (patch) | |
tree | 895d2cbef0f399d502cb2a24a5a2710f89e9fbb0 /drivers/gpu/drm/i915/intel_dp.c | |
parent | 7e38eeff6da255bf0a4dfd984b40d4615456e0a4 (diff) | |
download | linux-6d8175da1f449520373945ecbcf7c733cc07df1c.tar.bz2 |
drm/i915: Rely on TEST_SINK_START instead of tracking Sink CRC state on dev_priv.
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_dp.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_dp.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 948a7b007a87..6c17b0b455da 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -3985,7 +3985,6 @@ static int intel_dp_sink_crc_stop(struct intel_dp *intel_dp) ret = -ETIMEDOUT; } - intel_dp->sink_crc.started = false; out: hsw_enable_ips(intel_crtc); return ret; @@ -3999,12 +3998,6 @@ static int intel_dp_sink_crc_start(struct intel_dp *intel_dp) u8 buf; int ret; - if (intel_dp->sink_crc.started) { - ret = intel_dp_sink_crc_stop(intel_dp); - if (ret) - return ret; - } - if (drm_dp_dpcd_readb(&intel_dp->aux, DP_TEST_SINK_MISC, &buf) < 0) return -EIO; @@ -4014,6 +4007,12 @@ static int intel_dp_sink_crc_start(struct intel_dp *intel_dp) if (drm_dp_dpcd_readb(&intel_dp->aux, DP_TEST_SINK, &buf) < 0) return -EIO; + if (buf & DP_TEST_SINK_START) { + ret = intel_dp_sink_crc_stop(intel_dp); + if (ret) + return ret; + } + hsw_disable_ips(intel_crtc); if (drm_dp_dpcd_writeb(&intel_dp->aux, DP_TEST_SINK, @@ -4023,7 +4022,6 @@ static int intel_dp_sink_crc_start(struct intel_dp *intel_dp) } intel_wait_for_vblank(dev, intel_crtc->pipe); - intel_dp->sink_crc.started = true; return 0; } |