panfrost: Split stack_shift nibble from unk0
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Mon, 9 Dec 2019 13:41:33 +0000 (08:41 -0500)
committerAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Thu, 12 Dec 2019 16:42:07 +0000 (11:42 -0500)
It's conceptually independent from the upper part (which is not yet
understood, but for spilling generally remains equal to 0x1e).

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
src/gallium/drivers/panfrost/pan_context.c
src/panfrost/include/panfrost-job.h
src/panfrost/pandecode/decode.c

index d24d440be7c9129152658f10a89d001e40db97d6..9b742df836cb2e13bbee8c779f4cd347cd5f3e91 100644 (file)
@@ -149,7 +149,8 @@ panfrost_emit_mfbd(struct panfrost_batch *batch, unsigned vertex_count)
         unsigned height = batch->key.height;
 
         struct bifrost_framebuffer framebuffer = {
-                .unk0 = 0x1e5, /* 1e4 if no spill */
+                .stack_shift = 0x5,
+                .unk0 = 0x1e,
                 .width1 = MALI_POSITIVE(width),
                 .height1 = MALI_POSITIVE(height),
                 .width2 = MALI_POSITIVE(width),
index 2dbda7e813509e5df367d0f044788d7810d17a83..d2334b503f00ffdb412b25457b643ca469aabd41 100644 (file)
@@ -1671,7 +1671,8 @@ struct bifrost_fb_extra {
 #define MALI_MFBD_EXTRA (1 << 13)
 
 struct bifrost_framebuffer {
-        u32 unk0; // = 0x10
+        u32 stack_shift : 4;
+        u32 unk0 : 28;
 
         u32 unknown2; // = 0x1f, same as SFBD
         mali_ptr scratchpad;
index 39ece0c2b46850fe0a8e32e4a56882b4f7865dde..31a43dff0f954fb8dd68d9cab2cf8793fd022d8d 100644 (file)
@@ -1078,6 +1078,7 @@ pandecode_mfbd_bfr(uint64_t gpu_va, int job_no, bool is_fragment)
         pandecode_log("struct bifrost_framebuffer framebuffer_%"PRIx64"_%d = {\n", gpu_va, job_no);
         pandecode_indent++;
 
+        pandecode_prop("stack_shift = 0x%x", fb->stack_shift);
         pandecode_prop("unk0 = 0x%x", fb->unk0);
 
         if (fb->sample_locations)