aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_overlay.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2009-11-30 09:55:49 -0500
committerEric Anholt <eric@anholt.net>2009-11-30 12:50:57 -0500
commit9bedb9743fd906e4160468663ee6e1bbdc4412b8 (patch)
tree07b956e5128d6761fd64da9c26973c1f7d271afc /drivers/gpu/drm/i915/intel_overlay.c
parent12ca45fea91cfbb09df828bea958b47348caee6d (diff)
drm/i915: fixup interrupted overlay switch off calls
When switching to interruptible sleeps in the overlay code, I've forgotten to recover from interruptions at one site. This resulted in the overlay still running when it should have been switched off. This in turn caused a hang on resume because it tried to disable the (not-running) overlay in preparation for the resume modeset. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=24980 Tested-by: maximlevitsky@gmail.com Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Eric Anholt <eric@anholt.net>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_overlay.c')
-rw-r--r--drivers/gpu/drm/i915/intel_overlay.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/gpu/drm/i915/intel_overlay.c b/drivers/gpu/drm/i915/intel_overlay.c
index b97c5c562aa1..49110b3aab6a 100644
--- a/drivers/gpu/drm/i915/intel_overlay.c
+++ b/drivers/gpu/drm/i915/intel_overlay.c
@@ -842,12 +842,15 @@ int intel_overlay_switch_off(struct intel_overlay *overlay)
842 BUG_ON(!mutex_is_locked(&dev->struct_mutex)); 842 BUG_ON(!mutex_is_locked(&dev->struct_mutex));
843 BUG_ON(!mutex_is_locked(&dev->mode_config.mutex)); 843 BUG_ON(!mutex_is_locked(&dev->mode_config.mutex));
844 844
845 if (overlay->hw_wedged) {
846 ret = intel_overlay_recover_from_interrupt(overlay, 1);
847 if (ret != 0)
848 return ret;
849 }
850
845 if (!overlay->active) 851 if (!overlay->active)
846 return 0; 852 return 0;
847 853
848 if (overlay->hw_wedged)
849 return -EBUSY;
850
851 ret = intel_overlay_release_old_vid(overlay); 854 ret = intel_overlay_release_old_vid(overlay);
852 if (ret != 0) 855 if (ret != 0)
853 return ret; 856 return ret;