From fbce40641b6d8df6171775986d5aa4cce30b4e28 Mon Sep 17 00:00:00 2001 From: Ilija Hadzic Date: Tue, 29 Oct 2013 11:09:43 -0400 Subject: [PATCH] drm: restore crtc origin if mode_set_base fails Signed-off-by: Ilija Hadzic Signed-off-by: Dave Airlie --- drivers/gpu/drm/drm_crtc_helper.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/drm_crtc_helper.c b/drivers/gpu/drm/drm_crtc_helper.c index 11040a5886d4..acc9c36614df 100644 --- a/drivers/gpu/drm/drm_crtc_helper.c +++ b/drivers/gpu/drm/drm_crtc_helper.c @@ -822,6 +822,8 @@ int drm_crtc_helper_set_config(struct drm_mode_set *set) ret = crtc_funcs->mode_set_base(set->crtc, set->x, set->y, save_set.fb); if (ret != 0) { + set->crtc->x = save_set.x; + set->crtc->y = save_set.y; set->crtc->fb = save_set.fb; goto fail; } -- 2.30.2