panfrost: Align WSI strides for tiled AFBC
authorAlyssa Rosenzweig <alyssa@collabora.com>
Wed, 14 Dec 2022 01:31:38 +0000 (20:31 -0500)
committerMarge Bot <emma+marge@anholt.net>
Fri, 16 Dec 2022 18:27:47 +0000 (18:27 +0000)
commita3f9aa3b3e4db19d7a33bc0017d0291336efea10
tree95e65044da75324c80bb72ebabb77ba553a0c113
parentb08a7e9db51c8f991a349e34338fd78c921c1b9d
panfrost: Align WSI strides for tiled AFBC

When calculating legacy WSI strides for tiled AFBC, we need to account for the
greater alignment requirement of tiled AFBC, or importing resources will fail
later.

Since tiled AFBC is only supported on v7 and later, and AFBC of window surfaces
isn't being used on Linux on v7 and later, this probably hasn't been hit in
practice. Probably.

We're about to fix AFBC of window surfaces so we need to fix this side first.

Fixes: 0255f554f39 ("panfrost: Advertise 16x16 tiled AFBC")
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20311>
src/panfrost/lib/pan_layout.c