From 1fa4da043a5cc2a29a98c20f67d5c999819a2b6b Mon Sep 17 00:00:00 2001 From: Daniel Vetter Date: Wed, 29 Mar 2017 19:41:36 +0200 Subject: [PATCH] drm: Fixup failure paths in drm_atomic_helper_set_config I've screwed this up when removing the legacy backoff hack. Fixes: 38b6441e4e75 ("drm/atomic-helper: Remove the backoff hack from set_config") Cc: Harry Wentland Cc: Daniel Vetter Cc: Daniel Vetter Cc: Jani Nikula Cc: Sean Paul Cc: David Airlie Cc: dri-devel@lists.freedesktop.org Reviewed-by: Harry Wentland Signed-off-by: Daniel Vetter Link: http://patchwork.freedesktop.org/patch/msgid/20170329174136.10330-1-daniel.vetter@ffwll.ch --- drivers/gpu/drm/drm_atomic_helper.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/drm_atomic_helper.c b/drivers/gpu/drm/drm_atomic_helper.c index c4538c5dbc97..c3994b4d5f32 100644 --- a/drivers/gpu/drm/drm_atomic_helper.c +++ b/drivers/gpu/drm/drm_atomic_helper.c @@ -2293,10 +2293,11 @@ int drm_atomic_helper_set_config(struct drm_mode_set *set, state->acquire_ctx = ctx; ret = __drm_atomic_helper_set_config(set, state); if (ret != 0) - return ret; + goto fail; ret = drm_atomic_commit(state); +fail: drm_atomic_state_put(state); return ret; } -- 2.39.5