panfrost: Sanity check layer
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Sat, 22 Jun 2019 00:39:02 +0000 (17:39 -0700)
committerAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Tue, 25 Jun 2019 20:39:17 +0000 (13:39 -0700)
It doesn't make sense to try to render to multiple array elements at
once.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
src/gallium/drivers/panfrost/pan_mfbd.c

index e74a8e6229f511e5c12eb559db1eb28d8ff09762..af59497fa78f436bf1f1aca8f30b9285773c6bd7 100644 (file)
@@ -95,6 +95,7 @@ panfrost_mfbd_set_cbuf(
 
         unsigned level = surf->u.tex.level;
         unsigned first_layer = surf->u.tex.first_layer;
+        assert(surf->u.tex.last_layer == first_layer);
         int stride = rsrc->bo->slices[level].stride;
 
         mali_ptr base = panfrost_get_texture_address(rsrc, level, first_layer);