Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/msm/dpu: Add missing NULL pointer check for pingpong interface

It is checked almost always in dpu_encoder_phys_wb_setup_ctl(), but in a
single place the check is missing.
Also use convenient locals instead of phys_enc->* where available.

Cc: stable@vger.kernel.org
Fixes: d7d0e73f7de33 ("drm/msm/dpu: introduce the dpu_encoder_phys_* for writeback")
Signed-off-by: Nikolay Kuratov <kniv@yandex-team.ru>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Patchwork: https://patchwork.freedesktop.org/patch/693860/
Link: https://lore.kernel.org/r/20251211093630.171014-1-kniv@yandex-team.ru
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>

authored by

Nikolay Kuratov and committed by
Dmitry Baryshkov
88733a0b da9168d8

+4 -6
+4 -6
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c
··· 247 247 if (hw_cdm) 248 248 intf_cfg.cdm = hw_cdm->idx; 249 249 250 - if (phys_enc->hw_pp->merge_3d && phys_enc->hw_pp->merge_3d->ops.setup_3d_mode) 251 - phys_enc->hw_pp->merge_3d->ops.setup_3d_mode(phys_enc->hw_pp->merge_3d, 252 - mode_3d); 250 + if (hw_pp && hw_pp->merge_3d && hw_pp->merge_3d->ops.setup_3d_mode) 251 + hw_pp->merge_3d->ops.setup_3d_mode(hw_pp->merge_3d, mode_3d); 253 252 254 253 /* setup which pp blk will connect to this wb */ 255 - if (hw_pp && phys_enc->hw_wb->ops.bind_pingpong_blk) 256 - phys_enc->hw_wb->ops.bind_pingpong_blk(phys_enc->hw_wb, 257 - phys_enc->hw_pp->idx); 254 + if (hw_pp && hw_wb->ops.bind_pingpong_blk) 255 + hw_wb->ops.bind_pingpong_blk(hw_wb, hw_pp->idx); 258 256 259 257 phys_enc->hw_ctl->ops.setup_intf_cfg(phys_enc->hw_ctl, &intf_cfg); 260 258 } else if (phys_enc->hw_ctl && phys_enc->hw_ctl->ops.setup_intf_cfg) {