* Define easier to handle GFP_THISNODE
@ 2006-08-10 2:14 Christoph Lameter
0 siblings, 0 replies; only message in thread
From: Christoph Lameter @ 2006-08-10 2:14 UTC (permalink / raw)
To: akpm; +Cc: linux-mm
In many places we will need to use the same combination of flags.
Specify a single GFP_THISNODE definition for ease of use in gfp.h.
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Index: linux-2.6.18-rc3-mm2/include/linux/gfp.h
===================================================================
--- linux-2.6.18-rc3-mm2.orig/include/linux/gfp.h 2006-08-08 09:20:41.727897528 -0700
+++ linux-2.6.18-rc3-mm2/include/linux/gfp.h 2006-08-09 18:40:35.417771186 -0700
@@ -67,6 +67,8 @@ struct vm_area_struct;
#define GFP_HIGHUSER (__GFP_WAIT | __GFP_IO | __GFP_FS | __GFP_HARDWALL | \
__GFP_HIGHMEM)
+#define GFP_THISNODE (__GFP_THISNODE | __GFP_NOWARN | __GFP_NORETRY)
+
/* Flag - indicates that the buffer will be suitable for DMA. Ignored on some
platforms, used as appropriate on others */
Index: linux-2.6.18-rc3-mm2/mm/migrate.c
===================================================================
--- linux-2.6.18-rc3-mm2.orig/mm/migrate.c 2006-08-08 09:25:41.388119893 -0700
+++ linux-2.6.18-rc3-mm2/mm/migrate.c 2006-08-09 18:40:35.418747688 -0700
@@ -745,9 +745,7 @@ static struct page *new_page_node(struct
*result = &pm->status;
- return alloc_pages_node(pm->node,
- GFP_HIGHUSER | __GFP_THISNODE | __GFP_NOWARN | __GFP_NORETRY,
- 0);
+ return alloc_pages_node(pm->node, GFP_HIGHUSER | GFP_THISNODE, 0);
}
/*
Index: linux-2.6.18-rc3-mm2/arch/ia64/kernel/uncached.c
===================================================================
--- linux-2.6.18-rc3-mm2.orig/arch/ia64/kernel/uncached.c 2006-08-09 18:40:32.653293682 -0700
+++ linux-2.6.18-rc3-mm2/arch/ia64/kernel/uncached.c 2006-08-09 18:41:04.237278284 -0700
@@ -98,8 +98,7 @@ static int uncached_add_chunk(struct unc
/* attempt to allocate a granule's worth of cached memory pages */
- page = alloc_pages_node(nid, GFP_KERNEL | __GFP_ZERO |
- __GFP_THISNODE | __GFP_NORETRY | __GFP_NOWARN,
+ page = alloc_pages_node(nid, GFP_KERNEL | __GFP_ZERO | GFP_THISNODE,
IA64_GRANULE_SHIFT-PAGE_SHIFT);
if (!page) {
mutex_unlock(&uc_pool->add_chunk_mutex);
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2006-08-10 2:15 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-08-10 2:14 Define easier to handle GFP_THISNODE Christoph Lameter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox