Avoid duplicating some checks and code by making anv_GetDeviceQueue a
subcase of anv_GetDeviceQueue2, like radv does.
Signed-off-by: Ricardo Garcia <rgarcia@igalia.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
uint32_t queueIndex,
VkQueue* pQueue)
{
- ANV_FROM_HANDLE(anv_device, device, _device);
-
- assert(queueIndex == 0);
+ const VkDeviceQueueInfo2 info = {
+ .sType = VK_STRUCTURE_TYPE_DEVICE_QUEUE_INFO_2,
+ .pNext = NULL,
+ .flags = 0,
+ .queueFamilyIndex = queueNodeIndex,
+ .queueIndex = queueIndex,
+ };
- *pQueue = anv_queue_to_handle(&device->queue);
+ anv_GetDeviceQueue2(_device, &info, pQueue);
}
void anv_GetDeviceQueue2(