|
@@ -87,9 +87,7 @@ int pmd_huge_support(void)
|
|
}
|
|
}
|
|
#endif
|
|
#endif
|
|
|
|
|
|
-/* x86_64 also uses this file */
|
|
|
|
-
|
|
|
|
-#ifdef HAVE_ARCH_HUGETLB_UNMAPPED_AREA
|
|
|
|
|
|
+#ifdef CONFIG_HUGETLB_PAGE
|
|
static unsigned long hugetlb_get_unmapped_area_bottomup(struct file *file,
|
|
static unsigned long hugetlb_get_unmapped_area_bottomup(struct file *file,
|
|
unsigned long addr, unsigned long len,
|
|
unsigned long addr, unsigned long len,
|
|
unsigned long pgoff, unsigned long flags)
|
|
unsigned long pgoff, unsigned long flags)
|
|
@@ -99,7 +97,7 @@ static unsigned long hugetlb_get_unmapped_area_bottomup(struct file *file,
|
|
|
|
|
|
info.flags = 0;
|
|
info.flags = 0;
|
|
info.length = len;
|
|
info.length = len;
|
|
- info.low_limit = TASK_UNMAPPED_BASE;
|
|
|
|
|
|
+ info.low_limit = current->mm->mmap_legacy_base;
|
|
info.high_limit = TASK_SIZE;
|
|
info.high_limit = TASK_SIZE;
|
|
info.align_mask = PAGE_MASK & ~huge_page_mask(h);
|
|
info.align_mask = PAGE_MASK & ~huge_page_mask(h);
|
|
info.align_offset = 0;
|
|
info.align_offset = 0;
|
|
@@ -172,8 +170,7 @@ hugetlb_get_unmapped_area(struct file *file, unsigned long addr,
|
|
return hugetlb_get_unmapped_area_topdown(file, addr, len,
|
|
return hugetlb_get_unmapped_area_topdown(file, addr, len,
|
|
pgoff, flags);
|
|
pgoff, flags);
|
|
}
|
|
}
|
|
-
|
|
|
|
-#endif /*HAVE_ARCH_HUGETLB_UNMAPPED_AREA*/
|
|
|
|
|
|
+#endif /* CONFIG_HUGETLB_PAGE */
|
|
|
|
|
|
#ifdef CONFIG_X86_64
|
|
#ifdef CONFIG_X86_64
|
|
static __init int setup_hugepagesz(char *opt)
|
|
static __init int setup_hugepagesz(char *opt)
|