From 90546c070d7ae9f9db95212f062ed2f234eb8d48 Mon Sep 17 00:00:00 2001 From: Catalin Marinas Date: Fri, 28 Sep 2012 10:19:51 +1000 Subject: [PATCH] mm: thp: fix the pmd_clear() arguments in pmdp_get_and_clear() The CONFIG_TRANSPARENT_HUGEPAGE implementation of pmdp_get_and_clear() calls pmd_clear() with 3 arguments instead of 1. This happens only for !__HAVE_ARCH_PMDP_GET_AND_CLEAR which doesn't seem to happen because x86 defines this and it uses pmd_update. [mhocko@suse.cz: changelog addition] Signed-off-by: Catalin Marinas Signed-off-by: Steve Capper Signed-off-by: Will Deacon Cc: Arnd Bergmann Reviewed-by: Michal Hocko Reviewed-by: Kirill A. Shutemov Cc: Gerald Schaefer Reviewed-by: Andrea Arcangeli Cc: Chris Metcalf Signed-off-by: Andrew Morton --- include/asm-generic/pgtable.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/asm-generic/pgtable.h b/include/asm-generic/pgtable.h index ebdd74fb8d6a..b36ce40bd1c6 100644 --- a/include/asm-generic/pgtable.h +++ b/include/asm-generic/pgtable.h @@ -87,7 +87,7 @@ static inline pmd_t pmdp_get_and_clear(struct mm_struct *mm, pmd_t *pmdp) { pmd_t pmd = *pmdp; - pmd_clear(mm, address, pmdp); + pmd_clear(pmdp); return pmd; } #endif /* CONFIG_TRANSPARENT_HUGEPAGE */ -- 2.39.5