summaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert@linux-m68k.org>2017-07-12 14:33:08 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2017-07-12 16:25:59 -0700
commit91a90140f9987101d730b7dad8c6406321285da8 (patch)
treebba4c184c2978fb99c901bc975da4af45eac196d /mm
parentc7acec713d14c6ce8a20154f9dfda258d6bcad3b (diff)
downloadlinux-91a90140f9987101d730b7dad8c6406321285da8.tar.bz2
mm/memory.c: mark create_huge_pmd() inline to prevent build failure
With gcc 4.1.2: mm/memory.o: In function `create_huge_pmd': memory.c:(.text+0x93e): undefined reference to `do_huge_pmd_anonymous_page' Interestingly, create_huge_pmd() is emitted in the assembler output, but never called. Converting transparent_hugepage_enabled() from a macro to a static inline function reduced the ability of the compiler to remove unused code. Fix this by marking create_huge_pmd() inline. Fixes: 16981d763501c0e0 ("mm: improve readability of transparent_hugepage_enabled()") Link: http://lkml.kernel.org/r/1499842660-10665-1-git-send-email-geert@linux-m68k.org Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r--mm/memory.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/memory.c b/mm/memory.c
index cbb57194687e..0e517be91a89 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -3591,7 +3591,7 @@ out:
return 0;
}
-static int create_huge_pmd(struct vm_fault *vmf)
+static inline int create_huge_pmd(struct vm_fault *vmf)
{
if (vma_is_anonymous(vmf->vma))
return do_huge_pmd_anonymous_page(vmf);