diff --git a/src/virtio/vulkan/vn_physical_device.c b/src/virtio/vulkan/vn_physical_device.c index a67c238d354..bdf4813f711 100644 --- a/src/virtio/vulkan/vn_physical_device.c +++ b/src/virtio/vulkan/vn_physical_device.c @@ -925,10 +925,12 @@ vn_physical_device_get_native_extensions( { memset(exts, 0, sizeof(*exts)); - if (physical_dev->renderer_sync_fd.fence_exportable) + if (physical_dev->instance->renderer->info.has_external_sync && + physical_dev->renderer_sync_fd.fence_exportable) exts->KHR_external_fence_fd = true; - if (physical_dev->renderer_sync_fd.semaphore_importable && + if (physical_dev->instance->renderer->info.has_external_sync && + physical_dev->renderer_sync_fd.semaphore_importable && physical_dev->renderer_sync_fd.semaphore_exportable) exts->KHR_external_semaphore_fd = true; diff --git a/src/virtio/vulkan/vn_queue.c b/src/virtio/vulkan/vn_queue.c index 0b9a06774f9..4848f96b5a7 100644 --- a/src/virtio/vulkan/vn_queue.c +++ b/src/virtio/vulkan/vn_queue.c @@ -1669,6 +1669,11 @@ vn_GetFenceFdKHR(VkDevice device, vn_sync_payload_release(dev, &fence->temporary); fence->payload = &fence->permanent; + +#ifdef VN_USE_WSI_PLATFORM + if (!dev->renderer->info.has_implicit_fencing) + sync_wait(fd, -1); +#endif } else { assert(payload->type == VN_SYNC_TYPE_IMPORTED_SYNC_FD); @@ -2126,6 +2131,10 @@ vn_GetSemaphoreFdKHR(VkDevice device, if (result != VK_SUCCESS) return vn_error(dev->instance, result); +#ifdef VN_USE_WSI_PLATFORM + if (!dev->renderer->info.has_implicit_fencing) + sync_wait(fd, -1); +#endif } else { assert(payload->type == VN_SYNC_TYPE_IMPORTED_SYNC_FD);