panfrost: Expose panfrost_block_dim()
authorBoris Brezillon <boris.brezillon@collabora.com>
Sat, 21 Nov 2020 14:44:10 +0000 (15:44 +0100)
committerBoris Brezillon <boris.brezillon@collabora.com>
Wed, 25 Nov 2020 15:25:12 +0000 (16:25 +0100)
So we can use it from pan_resource.c to retrieve the tile size based on
a modifier.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7653>

src/panfrost/lib/pan_texture.c
src/panfrost/lib/pan_texture.h

index 64ad00f..d42ea50 100644 (file)
@@ -206,7 +206,7 @@ panfrost_estimate_texture_payload_size(
  * line stride as such.
  */
 
-static unsigned
+unsigned
 panfrost_block_dim(uint64_t modifier, bool width, unsigned plane)
 {
         if (!drm_is_afbc(modifier)) {
index 1a270e3..b4032f8 100644 (file)
@@ -89,6 +89,9 @@ bool
 panfrost_afbc_can_ytr(enum pipe_format format);
 
 unsigned
+panfrost_block_dim(uint64_t modifier, bool width, unsigned plane);
+
+unsigned
 panfrost_estimate_texture_payload_size(
                 unsigned first_level, unsigned last_level,
                 unsigned first_layer, unsigned last_layer,