mesa/hash: make the mtx non-recursive

Now that no one is recursively locking it we can switch to
a plain mutex.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9533>
This commit is contained in:
Pierre-Eric Pelloux-Prayer 2021-03-10 11:59:24 +01:00 committed by Marge Bot
parent 46c4ae5ff1
commit 0a78c22666
1 changed files with 1 additions and 5 deletions

View File

@ -62,11 +62,7 @@ _mesa_NewHashTable(void)
}
_mesa_hash_table_set_deleted_key(table->ht, uint_key(DELETED_KEY_VALUE));
/*
* Needs to be recursive, since the callback in _mesa_HashWalk()
* is allowed to call _mesa_HashRemove().
*/
mtx_init(&table->Mutex, mtx_recursive);
mtx_init(&table->Mutex, mtx_plain);
}
else {
_mesa_error_no_memory(__func__);