mesa/src/vulkan/wsi
Iago Toral Quiroga 1bbbdbe666 vulkan/wsi/display: set pDisplay to NULL on error
the spec for vkGetDrmDisplayEXT says:

  "If there is no VkDisplayKHR corresponding to the connectorId on the
   physicalDevice, the returning display must be set to VK_NULL_HANDLE.
   The provided drmFd must correspond to the one owned by the physicalDevice.
   If not, the error code VK_ERROR_UNKNOWN must be returned. (...)
   The given connectorId must be a resource owned by the provided drmFd.
   If not, the error code VK_ERROR_UNKNOWN must be returned"

We were only setting the display pointer to VK_NULL_HANDLE if the provided
drmFd was valid, however, there are CTS tests checking that it is also set
to NULL when it is not.

Fixes the following test on all drivers exposing EXT_acquire_drm_display
(tested with Intel and V3DV):
dEQP-VK.wsi.acquire_drm_display.acquire_drm_display_invalid_fd

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22283>
2023-04-05 06:21:26 +00:00
..
meson.build vulkan/wsi: Fix Windows build 2023-03-16 16:07:14 +00:00
wsi_common.c vulkan/wsi: Fix Windows build 2023-03-16 16:07:14 +00:00
wsi_common.h vk/util: Generate defines to help casting structs with vk_find_struct 2023-03-24 15:49:25 +00:00
wsi_common_display.c vulkan/wsi/display: set pDisplay to NULL on error 2023-04-05 06:21:26 +00:00
wsi_common_display.h vulkan/wsi/display: Wrap wsi_display_fence in a vk_sync 2021-11-16 10:54:27 -06:00
wsi_common_drm.c vulkan/wsi: Use the newly imported dma-buf.h 2023-01-11 22:33:40 +00:00
wsi_common_drm.h vk/wsi: C++-proof wsi_common_drm.h 2023-03-24 15:49:25 +00:00
wsi_common_headless.c vulkan/wsi: add a headless swapchain implementation/option 2023-03-14 14:03:31 +00:00
wsi_common_private.h vulkan/wsi: add a headless swapchain implementation/option 2023-03-14 14:03:31 +00:00
wsi_common_queue.h util/vector: make util_vector_init harder to misuse 2021-10-08 00:15:11 +00:00
wsi_common_wayland.c vulkan/wsi: fix crash in failed swapchain creation for wayland 2023-03-08 17:33:00 +00:00
wsi_common_win32.cpp wsi: move an assertion in wsi_xxx_surface_get_capabilities2() 2023-03-06 14:40:02 +00:00
wsi_common_x11.c wsi: move an assertion in wsi_xxx_surface_get_capabilities2() 2023-03-06 14:40:02 +00:00