radv: fix missing texel scale for unaligned linear SDMA copies
texel_scale was 0 which caused GPU hangs for unaligned linear copies.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13195
Fixes: 4b73d7e817 ("radv: fix SDMA copies for linear 96-bits formats")
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35047>
This commit is contained in:
committed by
Marge Bot
parent
e345b03c89
commit
c22d86e844
@@ -521,6 +521,7 @@ radv_sdma_emit_copy_linear_sub_window(const struct radv_device *device, struct r
|
||||
|
||||
/* Adjust offset/extent for 96-bits formats because SDMA expects a power of two bpp. */
|
||||
const uint32_t texel_scale = src->texel_scale == 1 ? dst->texel_scale : src->texel_scale;
|
||||
assert(texel_scale);
|
||||
src_off.x *= texel_scale;
|
||||
dst_off.x *= texel_scale;
|
||||
ext.width *= texel_scale;
|
||||
@@ -729,6 +730,7 @@ radv_sdma_copy_buffer_image_unaligned(const struct radv_device *device, struct r
|
||||
.blk_h = img.blk_h,
|
||||
.pitch = info.aligned_row_pitch * img.blk_w,
|
||||
.slice_pitch = info.aligned_row_pitch * img.blk_w * info.extent_vertical_blocks * img.blk_h,
|
||||
.texel_scale = buf->texel_scale,
|
||||
};
|
||||
|
||||
VkExtent3D extent = base_extent;
|
||||
|
||||
Reference in New Issue
Block a user