]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] mm: add arch_alloc_page
authorNick Piggin <npiggin@suse.de>
Thu, 7 Dec 2006 04:32:00 +0000 (20:32 -0800)
committerLinus Torvalds <torvalds@woody.osdl.org>
Thu, 7 Dec 2006 16:39:21 +0000 (08:39 -0800)
Add an arch_alloc_page to match arch_free_page.

Signed-off-by: Nick Piggin <npiggin@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
include/linux/gfp.h
mm/page_alloc.c

index bf2b6bc3f6fd4fc35dec4dc8072b26c160458dfe..00c314aedab7d8f9487112e9a4d16182185b6332 100644 (file)
@@ -116,6 +116,9 @@ static inline enum zone_type gfp_zone(gfp_t flags)
 #ifndef HAVE_ARCH_FREE_PAGE
 static inline void arch_free_page(struct page *page, int order) { }
 #endif
+#ifndef HAVE_ARCH_ALLOC_PAGE
+static inline void arch_alloc_page(struct page *page, int order) { }
+#endif
 
 extern struct page *
 FASTCALL(__alloc_pages(gfp_t, unsigned int, struct zonelist *));
index 230771d3c6b6f98f62a6f2bef02bd4e9e80ee267..cd47e8f7bd5bfda18ad83e546a202da2781964c7 100644 (file)
@@ -598,6 +598,8 @@ static int prep_new_page(struct page *page, int order, gfp_t gfp_flags)
                        1 << PG_checked | 1 << PG_mappedtodisk);
        set_page_private(page, 0);
        set_page_refcounted(page);
+
+       arch_alloc_page(page, order);
        kernel_map_pages(page, 1 << order, 1);
 
        if (gfp_flags & __GFP_ZERO)