From aaebf49ebaf34e92e99608507f42f5f42335a118 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Nicolai=20H=C3=A4hnle?= Date: Fri, 10 Nov 2017 11:28:28 +0100 Subject: [PATCH] gallium/u_threaded: properly initialize fence unflushed tokens MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This got lost in a rebase but never hurt anything because we happened to always sync in fence_finish anyway... Reviewed-by: Marek Olšák --- 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 d0a8ffb..84fbb22 100644 --- a/src/gallium/auxiliary/util/u_threaded_context.c +++ b/src/gallium/auxiliary/util/u_threaded_context.c @@ -1931,7 +1931,6 @@ tc_flush(struct pipe_context *_pipe, struct pipe_fence_handle **fence, if (async && tc->create_fence) { if (fence) { - struct tc_unflushed_batch_token *token = NULL; struct tc_batch *next = &tc->batch_slots[tc->next]; if (!next->token) { @@ -1943,7 +1942,7 @@ tc_flush(struct pipe_context *_pipe, struct pipe_fence_handle **fence, next->token->tc = tc; } - screen->fence_reference(screen, fence, tc->create_fence(pipe, token)); + screen->fence_reference(screen, fence, tc->create_fence(pipe, next->token)); if (!*fence) goto out_of_memory; } -- 2.7.4