aboutsummaryrefslogtreecommitdiffstats
path: root/mm/hugetlb.c
diff options
context:
space:
mode:
authorAndrea Arcangeli <aarcange@redhat.com>2014-01-21 18:48:49 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2014-01-21 19:19:43 -0500
commita0368d4e48fc9ad65a66f6819a801f3f542b4f0f (patch)
treecf3ba6417cff86a8b9d0e00d2ce1d80fa70568ec /mm/hugetlb.c
parent0e147aed4c250766e657855db55a395d2c8008a5 (diff)
mm: hugetlb: use get_page_foll() in follow_hugetlb_page()
get_page_foll() is more optimal and is always safe to use under the PT lock. More so for hugetlbfs as there's no risk of race conditions with split_huge_page regardless of the PT lock. Signed-off-by: Andrea Arcangeli <aarcange@redhat.com> Tested-by: Khalid Aziz <khalid.aziz@oracle.com> Cc: Pravin Shelar <pshelar@nicira.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Ben Hutchings <bhutchings@solarflare.com> Cc: Christoph Lameter <cl@linux.com> Cc: Johannes Weiner <jweiner@redhat.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Rik van Riel <riel@redhat.com> Cc: Andi Kleen <andi@firstfloor.org> Cc: Minchan Kim <minchan@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/hugetlb.c')
-rw-r--r--mm/hugetlb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/hugetlb.c b/mm/hugetlb.c
index dee6cf4e6d34..7596e104bffa 100644
--- a/mm/hugetlb.c
+++ b/mm/hugetlb.c
@@ -3079,7 +3079,7 @@ long follow_hugetlb_page(struct mm_struct *mm, struct vm_area_struct *vma,
3079same_page: 3079same_page:
3080 if (pages) { 3080 if (pages) {
3081 pages[i] = mem_map_offset(page, pfn_offset); 3081 pages[i] = mem_map_offset(page, pfn_offset);
3082 get_page(pages[i]); 3082 get_page_foll(pages[i]);
3083 } 3083 }
3084 3084
3085 if (vmas) 3085 if (vmas)