drm/vkms: Remove index parameter from init_vkms_output
VKMS currently supports only one CRTC, so it make no sense to have this index configurable. To avoid issues, replace this hardcoded index by drm_crtc_mask when applicable. There is no need to manually set a crtc mask on primary and cursor plane as it is automatically set by drmm_crtc_alloc_with_planes. In addition, this will remove the use of an uninitialized structure in vkms_add_overlay_plane. This currently works by chance because two things: - vkms_plane_init always set a possible_crtcs value, so the problematic branch is never used; - drm_crtc_mask on an kzalloc'd drm_crtc returns BIT(0), and the VKMS CRTC always have this id. Reviewed-by:José Expósito <jose.exposito89@gmail.com> Reviewed-by:
Maíra Canal <mcanal@igalia.com> Link: https://patchwork.freedesktop.org/patch/msgid/20241119-vkms-remove-index-v3-1-976321a3f801@bootlin.com Signed-off-by:
Louis Chauvet <louis.chauvet@bootlin.com>
Showing
- drivers/gpu/drm/vkms/vkms_drv.c 1 addition, 1 deletiondrivers/gpu/drm/vkms/vkms_drv.c
- drivers/gpu/drm/vkms/vkms_drv.h 2 additions, 6 deletionsdrivers/gpu/drm/vkms/vkms_drv.h
- drivers/gpu/drm/vkms/vkms_output.c 16 additions, 33 deletionsdrivers/gpu/drm/vkms/vkms_output.c
- drivers/gpu/drm/vkms/vkms_plane.c 2 additions, 2 deletionsdrivers/gpu/drm/vkms/vkms_plane.c
Loading
Please register or sign in to comment