summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/display/dc/dce110
diff options
context:
space:
mode:
authorRoman Li <Roman.Li@amd.com>2018-03-14 18:02:07 -0400
committerAlex Deucher <alexander.deucher@amd.com>2018-04-11 13:07:42 -0500
commit7a84077304e84d0254d505a76cc40971cb74c2de (patch)
treec2abe1800fb02ad45af6564b885a56d64cf571ed /drivers/gpu/drm/amd/display/dc/dce110
parenta052a516de4c3e46f2e442ec118c391dbf9932e3 (diff)
downloadblackbird-obmc-linux-7a84077304e84d0254d505a76cc40971cb74c2de.tar.gz
blackbird-obmc-linux-7a84077304e84d0254d505a76cc40971cb74c2de.zip
drm/amd/display: add assert in enable FBC
Adding assert to prevent possible null deref warning. Only can happen under abnormal circumstances. Signed-off-by: Roman Li <Roman.Li@amd.com> Reviewed-by: Tony Cheng <Tony.Cheng@amd.com> Acked-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/dce110')
-rw-r--r--drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c3
1 files changed, 3 insertions, 0 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 daa4673675f1..075ab291cdc7 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
@@ -1801,6 +1801,9 @@ static bool should_enable_fbc(struct dc *dc,
}
}
+ /* Pipe context should be found */
+ ASSERT(pipe_ctx);
+
/* Only supports eDP */
if (pipe_ctx->stream->sink->link->connector_signal != SIGNAL_TYPE_EDP)
return false;
OpenPOWER on IntegriCloud