From: Alex Shi Date: Tue, 29 May 2012 22:06:31 +0000 (-0700) Subject: mm: move is_vma_temporary_stack() declaration to huge_mm.h X-Git-Tag: upstream/snapshot3+hdmi~7343^2~146 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2099597401c7710c00b0d7c32b24a44a193836e1;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git mm: move is_vma_temporary_stack() declaration to huge_mm.h When transparent_hugepage_enabled() is used outside mm/, such as in arch/x86/xx/tlb.c: + if (!cpu_has_invlpg || vma->vm_flags & VM_HUGETLB + || transparent_hugepage_enabled(vma)) { + flush_tlb_mm(vma->vm_mm); is_vma_temporary_stack() isn't referenced in huge_mm.h, so it has compile errors: arch/x86/mm/tlb.c: In function `flush_tlb_range': arch/x86/mm/tlb.c:324:4: error: implicit declaration of function `is_vma_temporary_stack' [-Werror=implicit-function-declaration] Since is_vma_temporay_stack() is just used in rmap.c and huge_memory.c, it is better to move it to huge_mm.h from rmap.h to avoid such errors. Signed-off-by: Alex Shi Cc: Andrea Arcangeli Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/include/linux/huge_mm.h b/include/linux/huge_mm.h index c8af7a2..4c59b11 100644 --- a/include/linux/huge_mm.h +++ b/include/linux/huge_mm.h @@ -59,6 +59,8 @@ extern pmd_t *page_check_address_pmd(struct page *page, #define HPAGE_PMD_MASK HPAGE_MASK #define HPAGE_PMD_SIZE HPAGE_SIZE +extern bool is_vma_temporary_stack(struct vm_area_struct *vma); + #define transparent_hugepage_enabled(__vma) \ ((transparent_hugepage_flags & \ (1<