From 31a1348a66369a8d664aea6b9e8f5df388e92c16 Mon Sep 17 00:00:00 2001 From: Jonathan Marek Date: Wed, 23 Jan 2019 15:07:31 -0500 Subject: [PATCH] freedreno: fix sysmem rendering being used when clear is used This batch->cleared value is only used to decide to use sysmem rendering or not, so it should include any buffers that are affected by a clear. This is required because the a2xx fast clear doesn't work with sysmem rendering. The a22x "normal" clear path doesn't work with sysmem either. Signed-off-by: Jonathan Marek --- src/gallium/drivers/freedreno/freedreno_draw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/drivers/freedreno/freedreno_draw.c b/src/gallium/drivers/freedreno/freedreno_draw.c index c35b0d9..6703886 100644 --- a/src/gallium/drivers/freedreno/freedreno_draw.c +++ b/src/gallium/drivers/freedreno/freedreno_draw.c @@ -410,7 +410,7 @@ fd_clear(struct pipe_context *pctx, unsigned buffers, * the depth buffer, etc) */ cleared_buffers = buffers & (FD_BUFFER_ALL & ~batch->restore); - batch->cleared |= cleared_buffers; + batch->cleared |= buffers; batch->invalidated |= cleared_buffers; batch->resolve |= buffers; -- 2.7.4