render: use dev_t when creating renderer

We don't actually need to open a DRM node here. We just need a way
to reference a DRM node. A dev_t is better suited for this.
This commit is contained in:
Simon Ser 2023-10-04 15:05:19 +02:00
parent 986a2d9f66
commit 03c344de59
9 changed files with 86 additions and 79 deletions

View file

@ -61,9 +61,9 @@ struct wlr_vk_device {
struct wlr_drm_format_set shm_texture_formats;
};
// Tries to find the VkPhysicalDevice for the given drm fd.
// Tries to find the VkPhysicalDevice for the given DRM device ID.
// Might find none and return VK_NULL_HANDLE.
VkPhysicalDevice vulkan_find_drm_phdev(struct wlr_vk_instance *ini, int drm_fd);
VkPhysicalDevice vulkan_find_drm_phdev(struct wlr_vk_instance *ini, dev_t dev_id);
bool vulkan_get_phdev_drm_dev_id(VkPhysicalDevice phdev, dev_t *dev_id);
// Creates a device for the given instance and physical device.