Commit abebfed2 authored by Chenyuan Yang's avatar Chenyuan Yang Committed by Rob Clark
Browse files

drm/msm/dpu: Add a null ptr check for dpu_encoder_needs_modeset



The drm_atomic_get_new_connector_state() can return NULL if the
connector is not part of the atomic state. Add a check to prevent
a NULL pointer dereference.

This follows the same pattern used in dpu_encoder_update_topology()
within the same file, which checks for NULL before using conn_state.

Signed-off-by: default avatarChenyuan Yang <chenyuan0y@gmail.com>
Fixes: 1ce69c26 ("drm/msm/dpu: move resource allocation to CRTC")
Reviewed-by: default avatarDmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Patchwork: https://patchwork.freedesktop.org/patch/665188/


Signed-off-by: default avatarRob Clark <robin.clark@oss.qualcomm.com>
parent 7ab3b757
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment