radv/winsys: Expand scope of allbos lock.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Thu, 8 Oct 2020 12:36:08 +0000 (14:36 +0200)
committerMarge Bot <eric+marge@anholt.net>
Mon, 12 Oct 2020 10:55:08 +0000 (10:55 +0000)
commit875ff8414f66d10923171178adff49521fd9f70e
tree8fcd42059853704e030fc6cd2a3f84432fe25f51
parentea778693bf1598e1c45b2d3e94bc69e8ebcb7b09
radv/winsys: Expand scope of allbos lock.

With us not creating a bo_list anymore, there is a problem if we
delete a buffer between enumerating all buffers and doing the submission.

Also changes this to a rwlock given the wider scope of the things under
lock. (especialy some of the syncobj stuff is now under the lock)

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7091>
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_bo.c
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_cs.c
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_winsys.c
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_winsys.h