diff options
| author | Christian König <[email protected]> | 2022-11-09 11:41:08 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2022-11-17 05:23:43 +0000 |
| commit | d4cbff464d2932a71d7d3b7d17ffef7700b58edd (patch) | |
| tree | 945cfc7dc7d16e34478b1bfe98b222a667064410 /drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c | |
| parent | drm/amdgpu: rename the files for HMM handling (diff) | |
| download | kernel-d4cbff464d2932a71d7d3b7d17ffef7700b58edd.tar.gz kernel-d4cbff464d2932a71d7d3b7d17ffef7700b58edd.zip | |
drm/amdgpu: cleanup amdgpu_hmm_range_get_pages
Remove unused parameters and cleanup dead code.
Signed-off-by: Christian König <[email protected]>
Reviewed-by: Alex Deucher <[email protected]>
Reviewed-by: Felix Kuehling <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c')
| -rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c index a68072f766c7..a48ea62b12b0 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c @@ -158,10 +158,9 @@ void amdgpu_hmm_unregister(struct amdgpu_bo *bo) } int amdgpu_hmm_range_get_pages(struct mmu_interval_notifier *notifier, - struct mm_struct *mm, struct page **pages, - uint64_t start, uint64_t npages, - struct hmm_range **phmm_range, bool readonly, - bool mmap_locked, void *owner) + uint64_t start, uint64_t npages, bool readonly, + void *owner, struct page **pages, + struct hmm_range **phmm_range) { struct hmm_range *hmm_range; unsigned long timeout; @@ -194,14 +193,7 @@ int amdgpu_hmm_range_get_pages(struct mmu_interval_notifier *notifier, retry: hmm_range->notifier_seq = mmu_interval_read_begin(notifier); - - if (likely(!mmap_locked)) - mmap_read_lock(mm); - r = hmm_range_fault(hmm_range); - - if (likely(!mmap_locked)) - mmap_read_unlock(mm); if (unlikely(r)) { /* * FIXME: This timeout should encompass the retry from |
