From c793d384c12ebaa13487aeee35532e52b888c049 Mon Sep 17 00:00:00 2001 From: Iago Toral Quiroga Date: Wed, 2 Nov 2022 08:49:37 +0100 Subject: [PATCH] v3dv: remove unnecessary check for NULL MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We are initializing the device, so we know this will be NULL. Reviewed-by: Alejandro PiƱeiro Reviewed-by: Eric Engestrom cc: mesa-stable Part-of: --- src/broadcom/vulkan/v3dv_device.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/broadcom/vulkan/v3dv_device.c b/src/broadcom/vulkan/v3dv_device.c index 7be8b137107..8f8f39e7735 100644 --- a/src/broadcom/vulkan/v3dv_device.c +++ b/src/broadcom/vulkan/v3dv_device.c @@ -2104,11 +2104,9 @@ v3dv_CreateDevice(VkPhysicalDevice physicalDevice, device->device_address_mem_ctx); mtx_init(&device->events.lock, mtx_plain); - if (!device->events.bo) { - result = v3dv_event_allocate_resources(device); - if (result != VK_SUCCESS) - goto fail; - } + result = v3dv_event_allocate_resources(device); + if (result != VK_SUCCESS) + goto fail; if (list_is_empty(&device->events.free_list)) { result = vk_error(device, VK_ERROR_OUT_OF_DEVICE_MEMORY);