If the receiver goes away, drop any associated CRTC. This will force a full mode set on any subsequent setcrtc call, which is what we need if the receiver is gone and the link is down.
Signed-off-by: Jesse Barnes <[email protected]> --- drivers/gpu/drm/i915/intel_dp.c | 10 ++++++++-- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index f41aec3..d7a8d24 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -1533,7 +1533,7 @@ intel_dp_check_link_status(struct intel_dp *intel_dp) if (!intel_dp_get_link_status(intel_dp)) { intel_dp_link_down(intel_dp); - return; + goto out_gone; } /* Try to read receiver status if the link appears to be up */ @@ -1542,13 +1542,19 @@ intel_dp_check_link_status(struct intel_dp *intel_dp) sizeof (intel_dp->dpcd)); if (ret != sizeof(intel_dp->dpcd)) { intel_dp_link_down(intel_dp); - return; + goto out_gone; } if (!intel_channel_eq_ok(intel_dp)) { intel_dp_start_link_train(intel_dp); intel_dp_complete_link_train(intel_dp); } + + return; + +out_gone: + DRM_DEBUG_DRIVER("sink gone, clearing crtc for DP\n"); + intel_dp->base.base.crtc = NULL; } static enum drm_connector_status -- 1.7.4.1 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
