From b11f0ce609e4b38bc889b9d4d727a6b78e6035a7 Mon Sep 17 00:00:00 2001 From: llyyr Date: Mon, 11 May 2026 20:46:56 +0530 Subject: [PATCH] vulkan/wsi/wayland: use mtx helpers in wait_for_present2 present_ids.lock is a mtx_t object, and the rest of the file already uses mtx_(un)lock helpers. Fixes: 3023f31cadc9 ("wsi/wayland: Add support for PresentWait2") Signed-off-by: llyyr Part-of: --- src/vulkan/wsi/wsi_common_wayland.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vulkan/wsi/wsi_common_wayland.c b/src/vulkan/wsi/wsi_common_wayland.c index fd0b398d5f1..73cc78c4c2d 100644 --- a/src/vulkan/wsi/wsi_common_wayland.c +++ b/src/vulkan/wsi/wsi_common_wayland.c @@ -2824,12 +2824,12 @@ wsi_wl_swapchain_wait_for_present2(struct wsi_swapchain *wsi_chain, return result; while (1) { - err = pthread_mutex_lock(&chain->present_ids.lock); - if (err != 0) + err = mtx_lock(&chain->present_ids.lock); + if (err != thrd_success) return VK_ERROR_OUT_OF_DATE_KHR; bool completed = chain->present_ids.max_completed >= present_id; - pthread_mutex_unlock(&chain->present_ids.lock); + mtx_unlock(&chain->present_ids.lock); if (completed) return VK_SUCCESS;