drm/i915: use drm_modeset_lock_all

Two exceptions:
- debugfs files only read information which is not related to crtc, so
  can stay on the modeset_config lock.
- Same holds for the edp vdd work in intel_dp.c. Add a corresponding
  WARN_ON and a comment next to the intel_dp struct fields for
  documentation.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
This commit is contained in:
Daniel Vetter
2012-12-02 01:05:46 +01:00
parent 8484990325
commit a0e99e68c1
5 changed files with 17 additions and 15 deletions

View File

@@ -531,9 +531,9 @@ static int intel_lid_notify(struct notifier_block *nb, unsigned long val,
dev_priv->modeset_on_lid = 0;
mutex_lock(&dev->mode_config.mutex);
drm_modeset_lock_all(dev);
intel_modeset_setup_hw_state(dev, true);
mutex_unlock(&dev->mode_config.mutex);
drm_modeset_unlock_all(dev);
return NOTIFY_OK;
}