radv: return count of queue families written

The Vulkan spec indicates that
vkGetPhysicalDeviceQueueFamilyProperties() should overwrite
pQueueFamilyPropertyCount with the number of structures actually
written to pQueueFamilyProperties.

Signed-off-by: Damien Grassart <damien@grassart.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
This commit is contained in:
Damien Grassart
2016-12-25 00:41:45 +01:00
committed by Bas Nieuwenhuizen
parent 88b5acfa09
commit 3a30b1a556
+4 -1
View File
@@ -583,8 +583,10 @@ void radv_GetPhysicalDeviceQueueFamilyProperties(
idx++;
}
if (!all_queues)
if (!all_queues) {
*pCount = idx;
return;
}
if (pdevice->rad_info.compute_rings > 0 && pdevice->rad_info.chip_class >= CIK) {
if (*pCount > idx) {
@@ -597,6 +599,7 @@ void radv_GetPhysicalDeviceQueueFamilyProperties(
idx++;
}
}
*pCount = idx;
}
void radv_GetPhysicalDeviceMemoryProperties(