drm/amdkfd: svm range eviction and restore
authorFelix Kuehling <Felix.Kuehling@amd.com>
Wed, 24 Feb 2021 23:47:52 +0000 (18:47 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 21 Apr 2021 01:47:27 +0000 (21:47 -0400)
commit8a7c184a16d73ab25360e0f5997f82306ff5d5a2
treedf31fa3b64fa1b0408615e16785757751da618c3
parentf80fe9d3c1149bb2ad0d7807aaaf5eff7c4e80a6
drm/amdkfd: svm range eviction and restore

HMM interval notifier callback notify CPU page table will be updated,
stop process queues if the updated address belongs to svm range
registered in process svms objects tree. Scheduled restore work to
update GPU page table using new pages address in the updated svm range.

The restore worker flushes any deferred work to make sure it restores
an up-to-date svm_range_list.

Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_priv.h
drivers/gpu/drm/amd/amdkfd/kfd_process.c
drivers/gpu/drm/amd/amdkfd/kfd_svm.c
drivers/gpu/drm/amd/amdkfd/kfd_svm.h