radv/amdgpu: Split gang submissions correctly when not chained.
authorTimur Kristóf <timur.kristof@gmail.com>
Fri, 7 Apr 2023 00:57:32 +0000 (02:57 +0200)
committerMarge Bot <emma+marge@anholt.net>
Tue, 11 Apr 2023 17:05:03 +0000 (17:05 +0000)
commit1bdc1bd36c7fa3e2fa784024aac483e63577f462
tree9090286a85d499ce873be436e0e75e6b1755ca5a
parent813885f682aa0c7b1ad484bb1b1f446f6f99dc7c
radv/amdgpu: Split gang submissions correctly when not chained.

In a gang submit, the follower (typically ACE) and leader
(typically GFX) can have synchronization between each other.
We must ensure that these end up in the same submission,
otherwise we can deadlock the GPU.

We rely on radv_queue here to order follower before the leader
in the submitted CS array.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22354>
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_cs.c