diff options
author | Andrea Arcangeli <aarcange@redhat.com> | 2010-01-08 14:43:05 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-01-11 09:34:06 -0800 |
commit | 74dbdd239bb1348ad86d28b18574d9c1f28b62ca (patch) | |
tree | d29d30ee9d4c3dd64d831fa9d042c76cba829b58 /mm/hugetlb.c | |
parent | b5430a04e995081a308b4419bd0940f2badc6e6b (diff) | |
download | op-kernel-dev-74dbdd239bb1348ad86d28b18574d9c1f28b62ca.zip op-kernel-dev-74dbdd239bb1348ad86d28b18574d9c1f28b62ca.tar.gz |
mm: hugetlb: fix clear_huge_page()
sz is in bytes, MAX_ORDER_NR_PAGES is in pages.
Signed-off-by: Andrea Arcangeli <aarcange@redhat.com>
Acked-by: David Gibson <dwg@au1.ibm.com>
Cc: Mel Gorman <mel@csn.ul.ie>
Cc: David Rientjes <rientjes@google.com>
Cc: Lee Schermerhorn <lee.schermerhorn@hp.com>
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.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/hugetlb.c b/mm/hugetlb.c index 65f38c2..e91b81b 100644 --- a/mm/hugetlb.c +++ b/mm/hugetlb.c @@ -402,7 +402,7 @@ static void clear_huge_page(struct page *page, { int i; - if (unlikely(sz > MAX_ORDER_NR_PAGES)) { + if (unlikely(sz/PAGE_SIZE > MAX_ORDER_NR_PAGES)) { clear_gigantic_page(page, addr, sz); return; } |