Skip to content

Commit

Permalink
drm/i915: only set the intel_crtc DPMS mode to on if the mode set suc…
Browse files Browse the repository at this point in the history
…ceeded

If it failed, leave it in the "off" state.

Signed-off-by: Jesse Barnes <[email protected]>
Signed-off-by: Keith Packard <[email protected]>
  • Loading branch information
jbarnes993 authored and keith-packard committed Jan 3, 2012
1 parent 7a41986 commit d8e70a2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions drivers/gpu/drm/i915/intel_display.c
Original file line number Diff line number Diff line change
Expand Up @@ -5984,10 +5984,12 @@ static int intel_crtc_mode_set(struct drm_crtc *crtc,

ret = dev_priv->display.crtc_mode_set(crtc, mode, adjusted_mode,
x, y, old_fb);

drm_vblank_post_modeset(dev, pipe);

intel_crtc->dpms_mode = DRM_MODE_DPMS_ON;
if (ret)
intel_crtc->dpms_mode = DRM_MODE_DPMS_OFF;
else
intel_crtc->dpms_mode = DRM_MODE_DPMS_ON;

return ret;
}
Expand Down

0 comments on commit d8e70a2

Please sign in to comment.