summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorJonathan Gray <[email protected]>2019-11-28 16:56:30 +1100
committerMarek Olšák <[email protected]>2019-11-28 15:03:59 -0500
commit3fe3bde4f2c8813e13fa2992212ca46a894e68b6 (patch)
tree67ae0b2f3a09b46b44ff1ce4f05e91db4c0c3580 /src/gallium
parent5e81fbf44a5bfc23873c8bf67ec7adf450a886bf (diff)
winsys/amdgpu: avoid double simple_mtx_unlock()
pthread_mutex_unlock() when unlocked is documented by posix as being undefined behaviour. On OpenBSD pthread_mutex_unlock() will call abort(3) if this happens. This occurs in amdgpu_winsys_create() after cb446dc0fa5c68f681108f4613560543aa4cf553 winsys/amdgpu: Add amdgpu_screen_winsys Signed-off-by: Jonathan Gray <[email protected]> Cc: 19.2 19.3 <[email protected]> Signed-off-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
index 568d3852893..2a341413033 100644
--- a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
+++ b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
@@ -326,7 +326,6 @@ amdgpu_winsys_create(int fd, const struct pipe_screen_config *config,
aws = util_hash_table_get(dev_tab, dev);
if (aws) {
pipe_reference(NULL, &aws->reference);
- simple_mtx_unlock(&dev_tab_mutex);
/* Release the device handle, because we don't need it anymore.
* This function is returning an existing winsys instance, which