diff -upN reference/include/linux/gfp.h current/include/linux/gfp.h --- reference/include/linux/gfp.h Wed Jun 16 08:19:27 2004 +++ current/include/linux/gfp.h Wed Jun 16 15:53:11 2004 @@ -37,6 +37,7 @@ struct vm_area_struct; #define __GFP_NORETRY 0x1000 /* Do not retry. Might fail */ #define __GFP_NO_GROW 0x2000 /* Slab internal usage */ #define __GFP_COMP 0x4000 /* Add compound page metadata */ +#define __GFP_NODE_STRICT 0x8000/* Do not fall back to other nodes */ #define __GFP_BITS_SHIFT 16 /* Room for 16 __GFP_FOO bits */ #define __GFP_BITS_MASK ((1 << __GFP_BITS_SHIFT) - 1) diff -upN reference/mm/page_alloc.c current/mm/page_alloc.c --- reference/mm/page_alloc.c Wed Jun 16 08:19:27 2004 +++ current/mm/page_alloc.c Wed Jun 16 15:53:11 2004 @@ -610,6 +610,10 @@ __alloc_pages(unsigned int gfp_mask, uns min = (1<protection[alloc_type]; + if ((__GFP_NODE_STRICT & gfp_mask) && + (pfn_to_nid(z->zone_start_pfn) != numa_node_id())) + continue; + /* * We let real-time tasks dip their real-time paws a little * deeper into reserves.