From: Alyssa Rosenzweig Date: Tue, 22 Feb 2022 01:22:49 +0000 (-0500) Subject: asahi: Don't clobber clear colours X-Git-Tag: upstream/22.3.5~11405 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1c6e77bd0484df5f131ca5f1f51b763978147397;p=platform%2Fupstream%2Fmesa.git asahi: Don't clobber clear colours Signed-off-by: Alyssa Rosenzweig Part-of: --- diff --git a/src/gallium/drivers/asahi/agx_pipe.c b/src/gallium/drivers/asahi/agx_pipe.c index 7f82eea..0dfe421 100644 --- a/src/gallium/drivers/asahi/agx_pipe.c +++ b/src/gallium/drivers/asahi/agx_pipe.c @@ -389,7 +389,9 @@ agx_clear(struct pipe_context *pctx, unsigned buffers, const struct pipe_scissor { struct agx_context *ctx = agx_context(pctx); ctx->batch->clear |= buffers; - memcpy(ctx->batch->clear_color, color->f, sizeof(color->f)); + + if (buffers & PIPE_CLEAR_COLOR0) + memcpy(ctx->batch->clear_color, color->f, sizeof(color->f)); }