From: SivapiriyanKumarasamy Date: Sat, 24 Feb 2018 00:01:07 +0000 (-0500) Subject: drm/amd/display: Varibright add null check X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=a7596f25db13b1f5a2f8a068d8e9a60a23e34451;p=linux.git drm/amd/display: Varibright add null check Add null check for stream update Signed-off-by: SivapiriyanKumarasamy Reviewed-by: Krunoslav Kovac Acked-by: Harry Wentland Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c index 40a65cb9ee232..e72fdb5697fc5 100644 --- a/drivers/gpu/drm/amd/display/dc/core/dc.c +++ b/drivers/gpu/drm/amd/display/dc/core/dc.c @@ -1363,7 +1363,7 @@ static void commit_planes_for_stream(struct dc *dc, dc->hwss.apply_ctx_for_surface( dc, pipe_ctx->stream, stream_status->plane_count, context); - if (stream_update->abm_level && pipe_ctx->stream_res.abm) { + if (stream_update && stream_update->abm_level && pipe_ctx->stream_res.abm) { if (pipe_ctx->stream_res.tg->funcs->is_blanked) { // if otg funcs defined check if blanked before programming if (!pipe_ctx->stream_res.tg->funcs->is_blanked(pipe_ctx->stream_res.tg))