From 99fbf535fa61b87f82cd2bf377c3d45310361555 Mon Sep 17 00:00:00 2001 From: "Liam R. Howlett" Date: Mon, 1 Mar 2021 14:27:28 -0500 Subject: [PATCH] vfio: Use vma_lookup() instead of find_vma_intersection() Use the new vma_lookup() call for abstraction & code readability. Signed-off-by: Liam R. Howlett --- drivers/vfio/vfio_iommu_type1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/vfio/vfio_iommu_type1.c b/drivers/vfio/vfio_iommu_type1.c index 402668fef05d..ffba01063cc6 100644 --- a/drivers/vfio/vfio_iommu_type1.c +++ b/drivers/vfio/vfio_iommu_type1.c @@ -568,7 +568,7 @@ static int vaddr_get_pfns(struct mm_struct *mm, unsigned long vaddr, vaddr = untagged_addr(vaddr); retry: - vma = find_vma_intersection(mm, vaddr, vaddr + 1); + vma = vma_lookup(mm, vaddr); if (vma && vma->vm_flags & VM_PFNMAP) { ret = follow_fault_pfn(vma, mm, vaddr, pfn, prot & IOMMU_WRITE); -- 2.50.1