drm/rockchip: vop2: not to register crtc for inactive video port

Make sure that the vp to be registered has at least
one connector, otherwise it will be as an inactive vp.

Fixes: 6092eb96b6 ("drm/rockchip: vop2: add possible_vp_mask to calculate the exact possible_crtcs")
Change-Id: Ibc078d9f50e47877e4296c2e570721a6f69c9058
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
This commit is contained in:
Damon Ding
2024-03-15 18:26:17 +08:00
committed by Tao Huang
parent 0ce65b9ff3
commit 1568e5614d

View File

@@ -12580,6 +12580,12 @@ static int vop2_create_crtc(struct vop2 *vop2, uint8_t enabled_vp_mask)
primary = NULL;
cursor = NULL;
/*
* make sure that the vp to be registered has at least one connector.
*/
if (!(enabled_vp_mask & BIT(vp->id)))
continue;
/*
* we assume a vp with a zero plane_mask(set from dts or bootloader)
* as unused.