diff options
author | Alyssa Rosenzweig <[email protected]> | 2019-06-21 14:41:14 -0700 |
---|---|---|
committer | Alyssa Rosenzweig <[email protected]> | 2019-06-25 13:39:17 -0700 |
commit | aea3f0ac1d1e281b5d2f2100acad87810ed309c0 (patch) | |
tree | 7177e9a720876fba17f1c69b7b89eb39bb447209 /src/gallium/drivers/panfrost/pan_resource.c | |
parent | ad56dd4e973e181db394fbc68c7f82dfb6f505f8 (diff) |
panfrost: Z/S can't be tiled
As far as we know, Utgard-style tiling only works for color render
targets, not depth/stencil, so ensure we don't try to tile it (rather
than compress or plain old linear) and drive ourselves into a corner.
Signed-off-by: Alyssa Rosenzweig <[email protected]>
Diffstat (limited to 'src/gallium/drivers/panfrost/pan_resource.c')
-rw-r--r-- | src/gallium/drivers/panfrost/pan_resource.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/drivers/panfrost/pan_resource.c b/src/gallium/drivers/panfrost/pan_resource.c index 027cd61f16d..961cecf8cf0 100644 --- a/src/gallium/drivers/panfrost/pan_resource.c +++ b/src/gallium/drivers/panfrost/pan_resource.c @@ -295,6 +295,9 @@ panfrost_create_bo(struct panfrost_screen *screen, const struct pipe_resource *t bool should_tile = is_streaming && is_texture && is_2d; + /* Depth/stencil can't be tiled, only linear or AFBC */ + should_tile &= !(template->bind & PIPE_BIND_DEPTH_STENCIL); + /* Set the layout appropriately */ bo->layout = should_tile ? PAN_TILED : PAN_LINEAR; |