Module: Mesa Branch: main Commit: 7caf3e70a1cfcd6c8e00c418d96ff8be0e777ac0 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=7caf3e70a1cfcd6c8e00c418d96ff8be0e777ac0
Author: Danylo Piliaiev <[email protected]> Date: Thu Oct 5 15:11:35 2023 +0200 tu: Fix VK_FORMAT_A8_UNORM_KHR using UBWC when !has_8bpp_ubwc Fixes hangs in Anno 1800 with DXVK 2.3 Fixes: 302907e347612c3d748c88aed90fd6ab60a638f5 ("tu: Expose VK_KHR_maintenance5") Signed-off-by: Danylo Piliaiev <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25567> --- src/freedreno/vulkan/tu_image.cc | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/freedreno/vulkan/tu_image.cc b/src/freedreno/vulkan/tu_image.cc index 73276a97d02..00134d1c767 100644 --- a/src/freedreno/vulkan/tu_image.cc +++ b/src/freedreno/vulkan/tu_image.cc @@ -316,11 +316,8 @@ ubwc_possible(struct tu_device *device, return false; if (!info->a6xx.has_8bpp_ubwc && - (format == VK_FORMAT_R8_UNORM || - format == VK_FORMAT_R8_SNORM || - format == VK_FORMAT_R8_UINT || - format == VK_FORMAT_R8_SINT || - format == VK_FORMAT_R8_SRGB)) + vk_format_get_blocksizebits(format) == 8 && + tu6_plane_count(format) == 1) return false; if (type == VK_IMAGE_TYPE_3D) {
