From f3c7a02a62fdb8941c2201939efcd1caf13456cb Mon Sep 17 00:00:00 2001 From: Chia-I Wu Date: Sat, 6 Jul 2019 12:02:51 -0700 Subject: [PATCH] anv: fix VkExternalBufferProperties for unsupported handles compatibleHandleTypes must include the queried handle type. Signed-off-by: Chia-I Wu Cc: Reviewed-by: Lionel Landwerlin --- src/intel/vulkan/anv_formats.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/intel/vulkan/anv_formats.c b/src/intel/vulkan/anv_formats.c index 3f18553023c..8a5b6827666 100644 --- a/src/intel/vulkan/anv_formats.c +++ b/src/intel/vulkan/anv_formats.c @@ -1170,8 +1170,14 @@ void anv_GetPhysicalDeviceExternalBufferProperties( } unsupported: + /* From the Vulkan 1.1.113 spec: + * + * compatibleHandleTypes must include at least handleType. + */ pExternalBufferProperties->externalMemoryProperties = - (VkExternalMemoryProperties) {0}; + (VkExternalMemoryProperties) { + .compatibleHandleTypes = pExternalBufferInfo->handleType, + }; } VkResult anv_CreateSamplerYcbcrConversion( -- 2.30.2