From ffba16450fa51bbc8e34f8a81ba6c67b71615173 Mon Sep 17 00:00:00 2001 From: jsg Date: Thu, 11 Apr 2024 03:20:22 +0000 Subject: [PATCH] drm/amd/display: Prevent crash when disable stream From Chris Park 4356a2c3f296503c8b420ae8adece053960a9f06 in linux-6.6.y/6.6.26 72d72e8fddbcd6c98e1b02d32cf6f2b04e10bd1c in mainline linux --- sys/dev/pci/drm/amd/display/dc/dce110/dce110_hw_sequencer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/dev/pci/drm/amd/display/dc/dce110/dce110_hw_sequencer.c b/sys/dev/pci/drm/amd/display/dc/dce110/dce110_hw_sequencer.c index 357e47d940f..cdb63b90e09 100644 --- a/sys/dev/pci/drm/amd/display/dc/dce110/dce110_hw_sequencer.c +++ b/sys/dev/pci/drm/amd/display/dc/dce110/dce110_hw_sequencer.c @@ -1181,7 +1181,8 @@ void dce110_disable_stream(struct pipe_ctx *pipe_ctx) if (dccg) { dccg->funcs->disable_symclk32_se(dccg, dp_hpo_inst); dccg->funcs->set_dpstreamclk(dccg, REFCLK, tg->inst, dp_hpo_inst); - dccg->funcs->set_dtbclk_dto(dccg, &dto_params); + if (dccg && dccg->funcs->set_dtbclk_dto) + dccg->funcs->set_dtbclk_dto(dccg, &dto_params); } } else if (dccg && dccg->funcs->disable_symclk_se) { dccg->funcs->disable_symclk_se(dccg, stream_enc->stream_enc_inst, -- 2.20.1