aboutsummaryrefslogtreecommitdiffstats
path: root/mm/hugetlb.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/hugetlb.c')
-rw-r--r--mm/hugetlb.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/mm/hugetlb.c b/mm/hugetlb.c
index 8b809ecefa39..e2c80631d36a 100644
--- a/mm/hugetlb.c
+++ b/mm/hugetlb.c
@@ -868,7 +868,8 @@ int hugetlb_fault(struct mm_struct *mm, struct vm_area_struct *vma,
868 868
869int follow_hugetlb_page(struct mm_struct *mm, struct vm_area_struct *vma, 869int follow_hugetlb_page(struct mm_struct *mm, struct vm_area_struct *vma,
870 struct page **pages, struct vm_area_struct **vmas, 870 struct page **pages, struct vm_area_struct **vmas,
871 unsigned long *position, int *length, int i) 871 unsigned long *position, int *length, int i,
872 int write)
872{ 873{
873 unsigned long pfn_offset; 874 unsigned long pfn_offset;
874 unsigned long vaddr = *position; 875 unsigned long vaddr = *position;
@@ -890,7 +891,7 @@ int follow_hugetlb_page(struct mm_struct *mm, struct vm_area_struct *vma,
890 int ret; 891 int ret;
891 892
892 spin_unlock(&mm->page_table_lock); 893 spin_unlock(&mm->page_table_lock);
893 ret = hugetlb_fault(mm, vma, vaddr, 0); 894 ret = hugetlb_fault(mm, vma, vaddr, write);
894 spin_lock(&mm->page_table_lock); 895 spin_lock(&mm->page_table_lock);
895 if (!(ret & VM_FAULT_ERROR)) 896 if (!(ret & VM_FAULT_ERROR))
896 continue; 897 continue;