venus: set maxMipLevels to 1 for ahb images

Fixes: dEQP-VK.api.external.memory.android_hardware_buffer.image_formats.*

Cc: 21.2.2 mesa-stable

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Ryan Neph <ryanneph@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12639>
This commit is contained in:
Yiwei Zhang 2021-08-31 20:04:41 +00:00 committed by Marge Bot
parent 6440523077
commit 4a2adb36ae

View file

@ -2173,6 +2173,9 @@ vn_GetPhysicalDeviceImageFormatProperties2(
ahb_usage->androidHardwareBufferUsage = vn_android_get_ahb_usage(
pImageFormatInfo->usage, pImageFormatInfo->flags);
}
/* AHBs with mipmap usage will ignore this property */
pImageFormatProperties->imageFormatProperties.maxMipLevels = 1;
} else {
mem_props->compatibleHandleTypes = supported_handle_types;
mem_props->exportFromImportedHandleTypes =