aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_dp.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2012-12-19 11:08:43 -0500
committerDaniel Vetter <daniel.vetter@ffwll.ch>2012-12-20 15:09:55 -0500
commitc0c36b941b6f0be6ac74f340040cbb29d6a0b06c (patch)
tree68e8846f56be510e48f91d3896c768011248608d /drivers/gpu/drm/i915/intel_dp.c
parent1c45140d3da0c98fa7eda2cd10f9805232a5e9ac (diff)
drm/i915: Return the real error code from intel_set_mode()
Note: This patch also adds a little helper intel_crtc_restore_mode for the common case where we do a full modeset but with the same parameters, e.g. to undo bios damage or update a property. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@gmail.com> [danvet: Added note.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_dp.c')
-rw-r--r--drivers/gpu/drm/i915/intel_dp.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 2d3b26832397..1dd89d5fe511 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -2483,11 +2483,8 @@ intel_dp_set_property(struct drm_connector *connector,
2483 return -EINVAL; 2483 return -EINVAL;
2484 2484
2485done: 2485done:
2486 if (intel_encoder->base.crtc) { 2486 if (intel_encoder->base.crtc)
2487 struct drm_crtc *crtc = intel_encoder->base.crtc; 2487 intel_crtc_restore_mode(intel_encoder->base.crtc);
2488 intel_set_mode(crtc, &crtc->mode,
2489 crtc->x, crtc->y, crtc->fb);
2490 }
2491 2488
2492 return 0; 2489 return 0;
2493} 2490}