From f0519c9cf9fdccf93b0c3b81b47911de2422b285 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Fri, 17 Jan 2020 23:03:41 -0600 Subject: [PATCH] anv: Stop allocating WSI event fences off the instance Fixes: 16eb390834d "anv: add VK_EXT_display_control to anv driver [v5]" Reviewed-by: Lionel Landwerlin Part-of: --- src/intel/vulkan/anv_wsi_display.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/intel/vulkan/anv_wsi_display.c b/src/intel/vulkan/anv_wsi_display.c index a6326c738de..d876d294c1c 100644 --- a/src/intel/vulkan/anv_wsi_display.c +++ b/src/intel/vulkan/anv_wsi_display.c @@ -255,7 +255,7 @@ anv_RegisterDeviceEventEXT(VkDevice _device, struct anv_fence *fence; VkResult ret; - fence = vk_zalloc2(&device->instance->alloc, allocator, sizeof (*fence), 8, + fence = vk_zalloc2(&device->alloc, allocator, sizeof (*fence), 8, VK_SYSTEM_ALLOCATION_SCOPE_OBJECT); if (!fence) return vk_error(VK_ERROR_OUT_OF_HOST_MEMORY); @@ -270,7 +270,7 @@ anv_RegisterDeviceEventEXT(VkDevice _device, if (ret == VK_SUCCESS) *_fence = anv_fence_to_handle(fence); else - vk_free2(&device->instance->alloc, allocator, fence); + vk_free2(&device->alloc, allocator, fence); return ret; } -- 2.30.2