[PATCH 26/58] mm/internal.h: Declare vma_address unconditionally

From: Josh Triplett
Date: Mon Nov 19 2012 - 00:30:14 EST


mm/internal.h declares vma_address inside an ifdef
CONFIG_TRANSPARENT_HUGEPAGE; however, mm/rmap.c defines the function
unconditionally. Move the function outside of the ifdef.

This eliminates a warning from gcc (-Wmissing-prototypes) and from
Sparse (-Wdecl).

mm/rmap.c:527:1: warning: no previous prototype for âvma_addressâ [-Wmissing-prototypes]

Signed-off-by: Josh Triplett <josh@xxxxxxxxxxxxxxxx>
---
mm/internal.h | 2 --
1 file changed, 2 deletions(-)

diff --git a/mm/internal.h b/mm/internal.h
index a4fa284..6cd14dc 100644
--- a/mm/internal.h
+++ b/mm/internal.h
@@ -221,10 +221,8 @@ static inline void mlock_migrate_page(struct page *newpage, struct page *page)
}
}

-#ifdef CONFIG_TRANSPARENT_HUGEPAGE
extern unsigned long vma_address(struct page *page,
struct vm_area_struct *vma);
-#endif
#else /* !CONFIG_MMU */
static inline int mlocked_vma_newpage(struct vm_area_struct *v, struct page *p)
{
--
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/