aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBoris Brezillon <[email protected]>2019-09-05 21:01:20 +0200
committerBoris Brezillon <[email protected]>2019-09-13 16:25:06 +0200
commit835439b84fc0830447bc4c8c672c0acd237b2801 (patch)
tree9bcbc8ce4f49985a030d4edc8d95bd545eda8057 /src
parent4166ca92e273dbd2180c74da68c0467cf3fd1860 (diff)
panfrost: Delay payloads[].offset_start initialization
panfrost_draw_vbo() Might call the primeconvert/without_prim_restart helpers which will enter the ->draw_vbo() again. Let's delay payloads[].offset_start initialization so we don't initialize them twice. Signed-off-by: Boris Brezillon <[email protected]> Reviewed-by: Alyssa Rosenzweig <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/panfrost/pan_context.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gallium/drivers/panfrost/pan_context.c b/src/gallium/drivers/panfrost/pan_context.c
index 745d42e314f..de11dae0fc2 100644
--- a/src/gallium/drivers/panfrost/pan_context.c
+++ b/src/gallium/drivers/panfrost/pan_context.c
@@ -1577,9 +1577,6 @@ panfrost_draw_vbo(
if (panfrost_scissor_culls_everything(ctx))
return;
- ctx->payloads[PIPE_SHADER_VERTEX].offset_start = info->start;
- ctx->payloads[PIPE_SHADER_FRAGMENT].offset_start = info->start;
-
int mode = info->mode;
/* Fallback unsupported restart index */
@@ -1610,6 +1607,9 @@ panfrost_draw_vbo(
}
}
+ ctx->payloads[PIPE_SHADER_VERTEX].offset_start = info->start;
+ ctx->payloads[PIPE_SHADER_FRAGMENT].offset_start = info->start;
+
/* Now that we have a guaranteed terminating path, find the job.
* Assignment commented out to prevent unused warning */