From 5e5f4432cfc971ff95fdd7fd601a84740f075bde Mon Sep 17 00:00:00 2001 From: Lars-Ivar Hesselberg Simonsen Date: Fri, 6 Dec 2024 13:32:13 +0100 Subject: [PATCH] panvk: Remove ZS texture_swizzle_replicate_x The texture_swizzle_replicate_x functionality appears not to be required for Vulkan anymore, so let's remove it. Reviewed-by: Erik Faye-Lund Part-of: --- src/panfrost/vulkan/panvk_vX_buffer_view.c | 5 ----- src/panfrost/vulkan/panvk_vX_image_view.c | 7 +------ 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/src/panfrost/vulkan/panvk_vX_buffer_view.c b/src/panfrost/vulkan/panvk_vX_buffer_view.c index e4e4b09bdc0..2dfd4060d84 100644 --- a/src/panfrost/vulkan/panvk_vX_buffer_view.c +++ b/src/panfrost/vulkan/panvk_vX_buffer_view.c @@ -90,11 +90,6 @@ panvk_per_arch(CreateBufferView)(VkDevice _device, }, }; -#if PAN_ARCH >= 7 - /* v7+ doesn't have an _RRRR component order. */ - if (util_format_is_depth_or_stencil(pfmt)) - GENX(panfrost_texture_swizzle_replicate_x)(&pview); -#endif #if PAN_ARCH == 7 /* v7 requires AFBC reswizzle. */ if (!util_format_is_depth_or_stencil(pfmt) && diff --git a/src/panfrost/vulkan/panvk_vX_image_view.c b/src/panfrost/vulkan/panvk_vX_image_view.c index c18e8fbfa82..dd925081ec2 100644 --- a/src/panfrost/vulkan/panvk_vX_image_view.c +++ b/src/panfrost/vulkan/panvk_vX_image_view.c @@ -89,8 +89,7 @@ prepare_tex_descs(struct panvk_image_view *view) if (util_format_is_depth_or_stencil(view->pview.format)) { /* Vulkan wants R001, where the depth/stencil is stored in the red - * component, but the pan_format/texture logic gives us RRRR. - * Tweak the swizzle so we get what Vulkan wants. + * component. Tweak the swizzle so we get what Vulkan wants. */ static const unsigned char r001[4] = { PIPE_SWIZZLE_X, @@ -100,10 +99,6 @@ prepare_tex_descs(struct panvk_image_view *view) }; util_format_compose_swizzles(r001, view->pview.swizzle, pview.swizzle); - -#if PAN_ARCH >= 7 - GENX(panfrost_texture_swizzle_replicate_x)(&pview); -#endif } #if PAN_ARCH == 7 /* v7 requires AFBC reswizzle. */