iris: assert bufmgr->bo_deps_lock is held
This is the only place that touches bo->deps but does not explicitly lock it and is not a setup/teardown function where locking won't help anything. I'm confident we won't hit this assertion, but I've recently had this lock as the suspect of a bug and had to check the callers to see if we could be calling from any unlocked place. Having the assert helps increasing our confidence. Reviewed-by: José Roberto de Souza <jose.souza@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25236>
This commit is contained in:
@@ -744,6 +744,8 @@ update_bo_syncobjs(struct iris_batch *batch, struct iris_bo *bo, bool write)
|
||||
struct iris_bufmgr *bufmgr = screen->bufmgr;
|
||||
struct iris_context *ice = batch->ice;
|
||||
|
||||
simple_mtx_assert_locked(iris_bufmgr_get_bo_deps_lock(bufmgr));
|
||||
|
||||
/* Make sure bo->deps is big enough */
|
||||
if (screen->id >= bo->deps_size) {
|
||||
int new_size = screen->id + 1;
|
||||
|
Reference in New Issue
Block a user