diff options
author | Jesse Barnes <jbarnes@virtuousgeek.org> | 2011-11-15 13:28:54 -0500 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2012-01-03 17:55:52 -0500 |
commit | d8e70a254d8f2da141006e496a51502b79115e80 (patch) | |
tree | 24e917c5070da0ad8e04899c29f2d4618a49752d | |
parent | 7a4198664d46b87025a64530f1530ab2bea54c19 (diff) |
drm/i915: only set the intel_crtc DPMS mode to on if the mode set succeeded
If it failed, leave it in the "off" state.
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r-- | drivers/gpu/drm/i915/intel_display.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index bdab82b999e0..29743dee54c2 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c | |||
@@ -5984,10 +5984,12 @@ static int intel_crtc_mode_set(struct drm_crtc *crtc, | |||
5984 | 5984 | ||
5985 | ret = dev_priv->display.crtc_mode_set(crtc, mode, adjusted_mode, | 5985 | ret = dev_priv->display.crtc_mode_set(crtc, mode, adjusted_mode, |
5986 | x, y, old_fb); | 5986 | x, y, old_fb); |
5987 | |||
5988 | drm_vblank_post_modeset(dev, pipe); | 5987 | drm_vblank_post_modeset(dev, pipe); |
5989 | 5988 | ||
5990 | intel_crtc->dpms_mode = DRM_MODE_DPMS_ON; | 5989 | if (ret) |
5990 | intel_crtc->dpms_mode = DRM_MODE_DPMS_OFF; | ||
5991 | else | ||
5992 | intel_crtc->dpms_mode = DRM_MODE_DPMS_ON; | ||
5991 | 5993 | ||
5992 | return ret; | 5994 | return ret; |
5993 | } | 5995 | } |