From 0fd8c895534ba20c89899148583b11bb60d7c0df Mon Sep 17 00:00:00 2001 From: Eric Yang Date: Tue, 15 Mar 2016 11:00:26 -0400 Subject: [PATCH 0897/1110] drm/amd/dal: zero current context after powerdown Just in case we ever decide to use current_context in powerdown. Signed-off-by: Eric Yang Acked-by: Harry Wentland Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/dal/dc/core/dc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/dal/dc/core/dc.c b/drivers/gpu/drm/amd/dal/dc/core/dc.c index 5d87597..3f28446 100644 --- a/drivers/gpu/drm/amd/dal/dc/core/dc.c +++ b/drivers/gpu/drm/amd/dal/dc/core/dc.c @@ -1081,14 +1081,14 @@ void dc_set_power_state( /* NULL means "reset/release all DC targets" */ dc_commit_targets(dc, NULL, 0); + core_dc->hwss.power_down(core_dc); + /* Zero out the current context so that on resume we start with * clean state, and dc hw programming optimizations will not * cause any trouble. */ memset(&core_dc->current_context, 0, sizeof(core_dc->current_context)); - - core_dc->hwss.power_down(core_dc); break; } -- 2.7.4