util/u_queue: fix util_queue_finish deadlock by merging lock and finish_lock
authorMarek Olšák <marek.olsak@amd.com>
Sun, 16 Jul 2023 07:24:21 +0000 (03:24 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Tue, 18 Jul 2023 15:11:12 +0000 (11:11 -0400)
commitbfdfe5aa82f349d055d2e69aaf1b46325a6772ca
tree32c7fef00437a1f153e6eb2bf70171ca07cb869a
parentc282f80c98831a2c41792eae39e843e9c3fb4809
util/u_queue: fix util_queue_finish deadlock by merging lock and finish_lock

and by disabling the on-demand thread creation, which breaks the finish logic.

Fixes: 3713dc6b2a7 - util/u_queue: add UTIL_QUEUE_INIT_SCALE_THREADS flag
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8363

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24173>
src/gallium/drivers/etnaviv/etnaviv_shader.c
src/gallium/drivers/freedreno/ir3/ir3_gallium.c
src/gallium/drivers/iris/iris_program.c
src/gallium/drivers/radeonsi/si_pipe.c
src/gallium/drivers/zink/zink_screen.c
src/util/u_queue.c
src/util/u_queue.h