From a4b1ae1f03c422957cb16a6c57cec5e9f90eab95 Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Tue, 28 Feb 2023 16:05:08 -0500 Subject: [PATCH] zink: propagate valid_buffer_range when replacing buffer storage this is otherwise unreliable cc: mesa-stable Part-of: --- src/gallium/drivers/zink/zink_context.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/drivers/zink/zink_context.c b/src/gallium/drivers/zink/zink_context.c index 1faeca11..021fa0a 100644 --- a/src/gallium/drivers/zink/zink_context.c +++ b/src/gallium/drivers/zink/zink_context.c @@ -5008,6 +5008,7 @@ zink_context_replace_buffer_storage(struct pipe_context *pctx, struct pipe_resou zink_batch_reference_resource(&ctx->batch, d); /* don't be too creative */ zink_resource_object_reference(screen, &d->obj, s->obj); + d->valid_buffer_range = s->valid_buffer_range; /* force counter buffer reset */ d->so_valid = false; if (num_rebinds && rebind_buffer(ctx, d, rebind_mask, num_rebinds) < num_rebinds) -- 2.7.4