radv: fix non-square compressed image copy on gfx9
authorChia-I Wu <olvaffe@gmail.com>
Wed, 7 Jun 2023 01:14:54 +0000 (18:14 -0700)
committerMarge Bot <emma+marge@anholt.net>
Thu, 8 Jun 2023 04:58:31 +0000 (04:58 +0000)
There is a typo in fixup_gfx9_cs_copy.

Fixed dEQP-VK.api.copy_and_blit.*.image_to_buffer.2d_images.mip_copies_bc*_64x192_* in deqp 1.3.6.0.

Fixes: 35f053ba8cd ("radv: Fix corrupted mipmap copies on GFX9+")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23483>

src/amd/vulkan/meta/radv_meta_bufimage.c

index 1867eaf..eabeaa2 100644 (file)
@@ -1275,7 +1275,7 @@ fixup_gfx9_cs_copy(struct radv_cmd_buffer *cmd_buffer,
          RADV_CMD_FLAG_CS_PARTIAL_FLUSH | RADV_CMD_FLAG_INV_L2 | RADV_CMD_FLAG_INV_VCACHE;
    }
 
-   for (uint32_t y = 0; y < mip_extent.width; y++) {
+   for (uint32_t y = 0; y < mip_extent.height; y++) {
       uint32_t coordY = y + mip_offset.y;
       /* If the default copy algorithm (done previously) has already seen this
        * scanline, then we can bias the starting X coordinate over to skip the