From 6f96d029091e66e13bfa3d5f48c36b651f142ec1 Mon Sep 17 00:00:00 2001 From: jsg Date: Mon, 9 Sep 2024 10:02:33 +0000 Subject: [PATCH] drm/amd/display: Skip wbscl_set_scaler_filter if filter is null From Alex Hung e3a95f29647ae45d1ec9541cd7df64f40bf2120a in linux-6.6.y/6.6.50 c4d31653c03b90e51515b1380115d1aedad925dd in mainline linux --- sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_dwb_scl.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_dwb_scl.c b/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_dwb_scl.c index 994fb732a7c..a0d437f0ce2 100644 --- a/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_dwb_scl.c +++ b/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_dwb_scl.c @@ -690,6 +690,9 @@ static void wbscl_set_scaler_filter( int pair; uint16_t odd_coef, even_coef; + if (!filter) + return; + for (phase = 0; phase < (NUM_PHASES / 2 + 1); phase++) { for (pair = 0; pair < tap_pairs; pair++) { even_coef = filter[phase * taps + 2 * pair]; -- 2.20.1