diff options
author | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2014-08-18 15:16:02 -0400 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-09-03 05:04:07 -0400 |
commit | 15e899a01b5a50d12c96f696a43d4bd5a1ece8be (patch) | |
tree | 086193d643add46f6ba7537810ad7e0ef6244aec | |
parent | be2c9196e4da55b7351fc17dd6f3d11bd36ba893 (diff) |
drm/i915: Warn about want_panel_vdd in edp_panel_vdd_off_sync()
If we force vdd off warn if someone is still using it. With this
change the delayed vdd off work needs to check want_panel_vdd
itself to make sure it doesn't try to turn vdd off when someone
is using it.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
-rw-r--r-- | drivers/gpu/drm/i915/intel_dp.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 7e4baa8449c5..17389d0273a5 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c | |||
@@ -1241,7 +1241,9 @@ static void edp_panel_vdd_off_sync(struct intel_dp *intel_dp) | |||
1241 | 1241 | ||
1242 | WARN_ON(!drm_modeset_is_locked(&dev->mode_config.connection_mutex)); | 1242 | WARN_ON(!drm_modeset_is_locked(&dev->mode_config.connection_mutex)); |
1243 | 1243 | ||
1244 | if (intel_dp->want_panel_vdd || !edp_have_panel_vdd(intel_dp)) | 1244 | WARN_ON(intel_dp->want_panel_vdd); |
1245 | |||
1246 | if (!edp_have_panel_vdd(intel_dp)) | ||
1245 | return; | 1247 | return; |
1246 | 1248 | ||
1247 | DRM_DEBUG_KMS("Turning eDP VDD off\n"); | 1249 | DRM_DEBUG_KMS("Turning eDP VDD off\n"); |
@@ -1273,7 +1275,8 @@ static void edp_panel_vdd_work(struct work_struct *__work) | |||
1273 | struct drm_device *dev = intel_dp_to_dev(intel_dp); | 1275 | struct drm_device *dev = intel_dp_to_dev(intel_dp); |
1274 | 1276 | ||
1275 | drm_modeset_lock(&dev->mode_config.connection_mutex, NULL); | 1277 | drm_modeset_lock(&dev->mode_config.connection_mutex, NULL); |
1276 | edp_panel_vdd_off_sync(intel_dp); | 1278 | if (!intel_dp->want_panel_vdd) |
1279 | edp_panel_vdd_off_sync(intel_dp); | ||
1277 | drm_modeset_unlock(&dev->mode_config.connection_mutex); | 1280 | drm_modeset_unlock(&dev->mode_config.connection_mutex); |
1278 | } | 1281 | } |
1279 | 1282 | ||