aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Yang <[email protected]>2017-10-05 16:00:29 -0400
committerAlex Deucher <[email protected]>2017-10-21 16:49:29 -0400
commite6f4f9cfde0f586c276190f541ecfc80d9b688bc (patch)
treeb1a0bb0cc62aa1a2db8a1de0e12ac286d0ac5de6
parent886daac91d4c794fa76a0e5cf1101bdb329f3fe3 (diff)
drm/amd/display: fix null dereference in reset hw ctx
Signed-off-by: Eric Yang <[email protected]> Reviewed-by: Tony Cheng <[email protected]> Acked-by: Harry Wentland <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
-rw-r--r--drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c b/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
index 867a0eb9f2e0..5e5763c0ee94 100644
--- a/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
+++ b/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
@@ -1877,7 +1877,7 @@ static void dce110_reset_hw_ctx_wrap(
struct clock_source *old_clk = pipe_ctx_old->clock_source;
/* disable already, no need to disable again */
- if (!pipe_ctx->stream->dpms_off)
+ if (pipe_ctx->stream && !pipe_ctx->stream->dpms_off)
core_link_disable_stream(pipe_ctx_old, FREE_ACQUIRED_RESOURCE);
pipe_ctx_old->stream_res.tg->funcs->set_blank(pipe_ctx_old->stream_res.tg, true);