Skip to content

Commit eea24fe

Browse files
committed
drm/rockchip: cdn-dp: fix a possible NULL pointer dereference in cdn_dp_enable()
Change-Id: Ibf24dadd08e871d0531dab517d7f1e1f6ebeb206 Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
1 parent 758ca4c commit eea24fe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/gpu/drm/rockchip/cdn-dp-core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -729,7 +729,7 @@ static int cdn_dp_enable(struct cdn_dp_device *dp)
729729
}
730730

731731
/* Enable hdcp if it's desired */
732-
if (dp->connector.state->content_protection ==
732+
if (dp->connector.state && dp->connector.state->content_protection ==
733733
DRM_MODE_CONTENT_PROTECTION_DESIRED)
734734
ret = cdn_dp_start_hdcp1x_auth(dp);
735735

0 commit comments

Comments
 (0)