summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>2018-09-27 13:57:33 -0700
committerDhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>2018-09-27 19:33:03 -0700
commit47658556da857c66c5865f192408639f524cca40 (patch)
treefc78d8a20a128c8fbeae8bcd6d717a23d08573b3
parentd5acd97f5571189616685a4498b7d50687048979 (diff)
downloadtalos-obmc-linux-47658556da857c66c5865f192408639f524cca40.tar.gz
talos-obmc-linux-47658556da857c66c5865f192408639f524cca40.zip
drm/i915/dp: Do not grab crtc modeset lock in intel_dp_detect()
A crtc modeset lock was added for link retraining but intel_dp_retrain_link() knows to take the necessary locks since commit c85d200e8321 ("drm/i915: Move SST DP link retraining into the ->post_hotplug() hook") v2: Drop AUX power domain reference in the early return path Fixes: c85d200e8321 ("drm/i915: Move SST DP link retraining into the ->post_hotplug() hook") Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: José Roberto de Souza <jose.souza@intel.com> Signed-off-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com> Reviewed-by: José Roberto de Souza <jose.souza@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20180927205735.16651-4-dhinakaran.pandiyan@intel.com
-rw-r--r--drivers/gpu/drm/i915/intel_dp.c25
1 files changed, 11 insertions, 14 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 5c0375899974..64c8a5330847 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -5079,8 +5079,16 @@ intel_dp_long_pulse(struct intel_connector *connector,
* Some external monitors do not signal loss of link synchronization
* with an IRQ_HPD, so force a link status check.
*/
- if (!intel_dp_is_edp(intel_dp))
- intel_dp_retrain_link(encoder, ctx);
+ if (!intel_dp_is_edp(intel_dp)) {
+ int ret;
+
+ ret = intel_dp_retrain_link(encoder, ctx);
+ if (ret) {
+ intel_display_power_put(dev_priv,
+ intel_dp->aux_power_domain);
+ return ret;
+ }
+ }
/*
* Clearing NACK and defer counts to get their exact values
@@ -5130,19 +5138,8 @@ intel_dp_detect(struct drm_connector *connector,
connector->base.id, connector->name);
/* If full detect is not performed yet, do a full detect */
- if (!intel_dp->detect_done) {
- struct drm_crtc *crtc;
- int ret;
-
- crtc = connector->state->crtc;
- if (crtc) {
- ret = drm_modeset_lock(&crtc->mutex, ctx);
- if (ret)
- return ret;
- }
-
+ if (!intel_dp->detect_done)
status = intel_dp_long_pulse(intel_dp->attached_connector, ctx);
- }
intel_dp->detect_done = false;
OpenPOWER on IntegriCloud