From 5b688ec07801937954007497fecde868db29d73c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Thu, 25 Sep 2025 09:24:56 -0400 Subject: [PATCH] gallium/u_threaded: remove refcounting for buffer_unmap Reviewed-By: Mike Blumenkrantz Part-of: --- src/gallium/auxiliary/util/u_threaded_context.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/util/u_threaded_context.c b/src/gallium/auxiliary/util/u_threaded_context.c index 3ff2a8a8fb0..d04cab60852 100644 --- a/src/gallium/auxiliary/util/u_threaded_context.c +++ b/src/gallium/auxiliary/util/u_threaded_context.c @@ -2976,7 +2976,6 @@ tc_call_buffer_unmap(struct pipe_context *pipe, void *call) /* Nothing to do except keeping track of staging uploads */ assert(tres->pending_staging_uploads > 0); p_atomic_dec(&tres->pending_staging_uploads); - tc_drop_resource_reference(p->resource); } else { pipe->buffer_unmap(pipe, p->transfer); } @@ -3055,7 +3054,7 @@ tc_buffer_unmap(struct pipe_context *_pipe, struct pipe_transfer *transfer) struct tc_buffer_unmap *p = tc_add_call(tc, TC_CALL_buffer_unmap, tc_buffer_unmap); if (was_staging_transfer) { - tc_set_resource_reference(&p->resource, &tres->b); + p->resource = &tres->b; p->was_staging_transfer = true; } else { p->transfer = transfer;