From: Rob Clark Date: Sun, 1 Mar 2020 22:16:59 +0000 (-0800) Subject: freedreno: fix FD_MESA_DEBUG=inorder X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b3efa2a4da206112f6c9b5adb2df37c2efe646e6;p=mesa.git freedreno: fix FD_MESA_DEBUG=inorder Fixes: 2c07e03b792 ("freedreno: allow ctx->batch to be NULL") Signed-off-by: Rob Clark Part-of: --- diff --git a/src/gallium/drivers/freedreno/freedreno_state.c b/src/gallium/drivers/freedreno/freedreno_state.c index 8a757ee96d4..d9c8f9f89a2 100644 --- a/src/gallium/drivers/freedreno/freedreno_state.c +++ b/src/gallium/drivers/freedreno/freedreno_state.c @@ -252,7 +252,7 @@ fd_set_framebuffer_state(struct pipe_context *pctx, } fd_batch_reference(&old_batch, NULL); - } else { + } else if (ctx->batch) { DBG("%d: cbufs[0]=%p, zsbuf=%p", ctx->batch->needs_flush, framebuffer->cbufs[0], framebuffer->zsbuf); fd_batch_flush(ctx->batch);