Skip to content

Commit 660a467

Browse files
Ilya Bakoulinalexdeucher
authored andcommitted
drm/amd/display: Separate set_gsl from set_gsl_source_select
[Why/How] Separate the checks for set_gsl and set_gsl_source_select, since source_select may not be implemented/necessary. Reviewed-by: Nevenko Stupar <nevenko.stupar@amd.com> Signed-off-by: Ilya Bakoulin <Ilya.Bakoulin@amd.com> Signed-off-by: Ray Wu <ray.wu@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 86fa0b9 commit 660a467

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

drivers/gpu/drm/amd/display/dc/hwss/dcn20/dcn20_hwseq.c

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -283,14 +283,13 @@ void dcn20_setup_gsl_group_as_lock(
283283
}
284284

285285
/* at this point we want to program whether it's to enable or disable */
286-
if (pipe_ctx->stream_res.tg->funcs->set_gsl != NULL &&
287-
pipe_ctx->stream_res.tg->funcs->set_gsl_source_select != NULL) {
286+
if (pipe_ctx->stream_res.tg->funcs->set_gsl != NULL) {
288287
pipe_ctx->stream_res.tg->funcs->set_gsl(
289288
pipe_ctx->stream_res.tg,
290289
&gsl);
291-
292-
pipe_ctx->stream_res.tg->funcs->set_gsl_source_select(
293-
pipe_ctx->stream_res.tg, group_idx, enable ? 4 : 0);
290+
if (pipe_ctx->stream_res.tg->funcs->set_gsl_source_select != NULL)
291+
pipe_ctx->stream_res.tg->funcs->set_gsl_source_select(
292+
pipe_ctx->stream_res.tg, group_idx, enable ? 4 : 0);
294293
} else
295294
BREAK_TO_DEBUGGER();
296295
}

0 commit comments

Comments
 (0)