Skip to contentSkip to conversation

drm/i915: take mode config lock around crtc disable at suspend

PATCH Applied Jesse Barnes 2 participants 2 messages Nov 26, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/i915: take mode config lock around crtc disable at suspend

This is just a theoretical issue, but we need to do this to prevent the WARN in pipe_from_connector at suspend time.

https://bugs.freedesktop.org/show_bug.cgi?id=71978

---
 drivers/gpu/drm/i915/i915_drv.c |    2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/i915/i915_drv.c +2 -0
index 13076db..0ec0fb3 100644
@@ -535,8 +535,10 @@ static int i915_drm_freeze(struct drm_device *dev)
 		 * Disable CRTCs directly since we want to preserve sw state
 		 * for _thaw.
 		 */
+		mutex_lock(&dev->mode_config.mutex);
 		list_for_each_entry(crtc, &dev->mode_config.crtc_list, head)
 			dev_priv->display.crtc_disable(crtc);
+		mutex_unlock(&dev->mode_config.mutex);
 
 		intel_modeset_suspend_hw(dev);
 	}
Signature · 1 line
1.7.9.5