]> Gentwo Git Trees - linux/.git/commit
drm/amdkfd: Fix mmap write lock not release
authorPhilip Yang <Philip.Yang@amd.com>
Mon, 15 Sep 2025 19:57:32 +0000 (15:57 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 7 Oct 2025 18:09:06 +0000 (14:09 -0400)
commit7574f30337e19045f03126b4c51f525b84e5049e
tree0eda9131a962658f06d5e69a78886ae644770b00
parent58e6fc2fb94f0f409447e5d46cf6a417b6397fbc
drm/amdkfd: Fix mmap write lock not release

If mmap write lock is taken while draining retry fault, mmap write lock
is not released because svm_range_restore_pages calls mmap_read_unlock
then returns. This causes deadlock and system hangs later because mmap
read or write lock cannot be taken.

Downgrade mmap write lock to read lock if draining retry fault fix this
bug.

Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Reviewed-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_svm.c