]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/amdgpu/userq: Fix the mutex_init cleanup for fence_drv_lock
authorSunil Khatri <sunil.khatri@amd.com>
Tue, 19 May 2026 09:42:42 +0000 (15:12 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 27 May 2026 15:55:38 +0000 (11:55 -0400)
commitba4c0ff47ee098c8e17d25f9dc050e6276bf9979
tree2208f5958d1edb5e23877c8abb785cb139c6bd99
parent4a03d23ce6ad474cb15862563bc9132e16e3e31e
drm/amdgpu/userq: Fix the mutex_init cleanup for fence_drv_lock

mutex fence_drv_lock is destroyed in amdgpu_userq_fence_driver_free
also in one of the jump condition mutex_destroy is also called leading
to double mutex_destroy.

So rearranging the code so amdgpu_userq_fence_driver_free takes care
of the clean up along with mutex_destroy.

Signed-off-by: Sunil Khatri <sunil.khatri@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit 384dbef269d101e5b671fc7b942c56734cd1d186)
drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c