OSDN Git Service

drm/amdkfd: restore userptr ignore bad address error
authorPhilip Yang <Philip.Yang@amd.com>
Tue, 26 Oct 2021 15:59:28 +0000 (11:59 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 28 Oct 2021 18:26:12 +0000 (14:26 -0400)
commit3b8a23ae52dfbf785ea6f7c81358b1225a6bd339
tree17e7481199a63b271df91b7f0db29797fe054ed8
parent68daadf3d673568bb7122b1683fd8b0e27c55d9b
drm/amdkfd: restore userptr ignore bad address error

The userptr can be unmapped by application and still registered to
driver, restore userptr work return user pages will get -EFAULT bad
address error. Pretend this error as succeed. GPU access this userptr
will have VM fault later, it is better than application soft hangs with
stalled user mode queues.

v2: squash in warning fix (Alex)

Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c