Commit 6d376756 authored by Michael S. Tsirkin's avatar Michael S. Tsirkin Committed by Roland Dreier

[IB/mthca]: Use io_remap_pfn_range for PCI space

Use io_remap_pfn_range to remap IO pages (remap_pfn_range is for memory).
Signed-off-by: default avatarMichael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: default avatarRoland Dreier <rolandd@cisco.com>
parent 2181858b
......@@ -349,9 +349,9 @@ static int mthca_mmap_uar(struct ib_ucontext *context,
vma->vm_page_prot = pgprot_noncached(vma->vm_page_prot);
if (remap_pfn_range(vma, vma->vm_start,
to_mucontext(context)->uar.pfn,
PAGE_SIZE, vma->vm_page_prot))
if (io_remap_pfn_range(vma, vma->vm_start,
to_mucontext(context)->uar.pfn,
PAGE_SIZE, vma->vm_page_prot))
return -EAGAIN;
return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment