diff --git a/src/freedreno/vulkan/tu_device.c b/src/freedreno/vulkan/tu_device.c index 2feb05f3262..5d4ae2bb192 100644 --- a/src/freedreno/vulkan/tu_device.c +++ b/src/freedreno/vulkan/tu_device.c @@ -1438,17 +1438,23 @@ tu_CreateDevice(VkPhysicalDevice physicalDevice, /* Initialize a condition variable for timeline semaphore */ pthread_condattr_t condattr; if (pthread_condattr_init(&condattr) != 0) { - result = VK_ERROR_INITIALIZATION_FAILED; + result = vk_startup_errorf(physical_device->instance, + VK_ERROR_INITIALIZATION_FAILED, + "pthread condattr init"); goto fail_timeline_cond; } if (pthread_condattr_setclock(&condattr, CLOCK_MONOTONIC) != 0) { pthread_condattr_destroy(&condattr); - result = VK_ERROR_INITIALIZATION_FAILED; + result = vk_startup_errorf(physical_device->instance, + VK_ERROR_INITIALIZATION_FAILED, + "pthread condattr clock setup"); goto fail_timeline_cond; } if (pthread_cond_init(&device->timeline_cond, &condattr) != 0) { pthread_condattr_destroy(&condattr); - result = VK_ERROR_INITIALIZATION_FAILED; + result = vk_startup_errorf(physical_device->instance, + VK_ERROR_INITIALIZATION_FAILED, + "pthread cond init"); goto fail_timeline_cond; } pthread_condattr_destroy(&condattr); diff --git a/src/freedreno/vulkan/tu_drm.c b/src/freedreno/vulkan/tu_drm.c index 14bced0e2fa..0c6454e796f 100644 --- a/src/freedreno/vulkan/tu_drm.c +++ b/src/freedreno/vulkan/tu_drm.c @@ -446,26 +446,20 @@ tu_drm_device_init(struct tu_physical_device *device, device->local_fd = fd; if (tu_drm_get_gpu_id(device, &device->gpu_id)) { - if (instance->debug_flags & TU_DEBUG_STARTUP) - mesa_logi("Could not query the GPU ID"); - result = vk_errorf(instance, VK_ERROR_INITIALIZATION_FAILED, - "could not get GPU ID"); + result = vk_startup_errorf(instance, VK_ERROR_INITIALIZATION_FAILED, + "could not get GPU ID"); goto fail; } if (tu_drm_get_gmem_size(device, &device->gmem_size)) { - if (instance->debug_flags & TU_DEBUG_STARTUP) - mesa_logi("Could not query the GMEM size"); - result = vk_errorf(instance, VK_ERROR_INITIALIZATION_FAILED, - "could not get GMEM size"); + result = vk_startup_errorf(instance, VK_ERROR_INITIALIZATION_FAILED, + "could not get GMEM size"); goto fail; } if (tu_drm_get_gmem_base(device, &device->gmem_base)) { - if (instance->debug_flags & TU_DEBUG_STARTUP) - mesa_logi("Could not query the GMEM size"); - result = vk_errorf(instance, VK_ERROR_INITIALIZATION_FAILED, - "could not get GMEM size"); + result = vk_startup_errorf(instance, VK_ERROR_INITIALIZATION_FAILED, + "could not get GMEM size"); goto fail; }