From 684d6f0d68c15e8bdbef193412de45356b03905b Mon Sep 17 00:00:00 2001 From: Lars-Ivar Hesselberg Simonsen Date: Tue, 6 May 2025 16:39:46 +0200 Subject: [PATCH] pan/texture: Correctly handle slice stride for MSAA Currently, we will always be setting the slice stride in the plane descriptor to the surface stride, as the check for multisampling is true even for single sampled surfaces. This change fixes this check. Fixes: db20152c8a8 ("panfrost: Handle Valhall texturing") Reviewed-by: Boris Brezillon Part-of: (cherry picked from commit cc58e30847a84d699c107b14fddc6624dd1b2243) --- .pick_status.json | 2 +- src/panfrost/lib/pan_texture.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index 8b0b94fc726..15df425daf4 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -1144,7 +1144,7 @@ "description": "pan/texture: Correctly handle slice stride for MSAA", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "db20152c8a85a425dd54b27cc00961d2b5a4650f", "notes": null diff --git a/src/panfrost/lib/pan_texture.c b/src/panfrost/lib/pan_texture.c index 99df8f37de1..165ba2c768d 100644 --- a/src/panfrost/lib/pan_texture.c +++ b/src/panfrost/lib/pan_texture.c @@ -435,7 +435,7 @@ panfrost_emit_plane(const struct pan_image_view *iview, cfg.two_plane_yuv_chroma.secondary_pointer = sections[plane_index + 1].pointer; } else if (!panfrost_format_is_yuv(layout->format)) { - cfg.slice_stride = layout->nr_samples + cfg.slice_stride = layout->nr_samples > 1 ? surface_stride : panfrost_get_layer_stride(layout, level); }