From 316c217cd93ee2b6ac57062b6e2a264b5436a3ff Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Mon, 17 Apr 2023 18:06:11 +0200 Subject: [PATCH] radv: fix usage flag for 3D compressed 128 bpp images on GFX9 VK_FORMAT_FEATURE_2_COLOR_ATTACHMENT_BIT is equal to VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT but we want COLOR_ATTACHMENT_BIT. Found by inspection. Cc: mesa-stable Signed-off-by: Samuel Pitoiset Part-of: (cherry picked from commit 72a522fb3692985a4e805b00f6d7e2f5a0386d47) --- .pick_status.json | 2 +- src/amd/vulkan/radv_formats.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index fdc9a33e348..2a63141cd48 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -148,7 +148,7 @@ "description": "radv: fix usage flag for 3D compressed 128 bpp images on GFX9", "nominated": true, "nomination_type": 0, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": null }, diff --git a/src/amd/vulkan/radv_formats.c b/src/amd/vulkan/radv_formats.c index 669f4bec3cc..96e71d366a7 100644 --- a/src/amd/vulkan/radv_formats.c +++ b/src/amd/vulkan/radv_formats.c @@ -1551,7 +1551,7 @@ radv_get_image_format_properties(struct radv_physical_device *physical_device, vk_format_get_blocksizebits(format) == 128 && vk_format_is_compressed(format) && (info->flags & VK_IMAGE_CREATE_BLOCK_TEXEL_VIEW_COMPATIBLE_BIT) && ((info->flags & VK_IMAGE_CREATE_EXTENDED_USAGE_BIT) || - (info->usage & VK_FORMAT_FEATURE_2_COLOR_ATTACHMENT_BIT))) { + (info->usage & VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT))) { goto unsupported; }