aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/pci-sysfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pci/pci-sysfs.c')
-rw-r--r--drivers/pci/pci-sysfs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index 9c6e9bb674ec..5b4a9d9cd200 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -897,7 +897,7 @@ int pci_mmap_fits(struct pci_dev *pdev, int resno, struct vm_area_struct *vma,
897 897
898 if (pci_resource_len(pdev, resno) == 0) 898 if (pci_resource_len(pdev, resno) == 0)
899 return 0; 899 return 0;
900 nr = (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; 900 nr = vma_pages(vma);
901 start = vma->vm_pgoff; 901 start = vma->vm_pgoff;
902 size = ((pci_resource_len(pdev, resno) - 1) >> PAGE_SHIFT) + 1; 902 size = ((pci_resource_len(pdev, resno) - 1) >> PAGE_SHIFT) + 1;
903 pci_start = (mmap_api == PCI_MMAP_PROCFS) ? 903 pci_start = (mmap_api == PCI_MMAP_PROCFS) ?