From: Paul Jackson More consistent mm/page_alloc.c ALLOC_* flag names. Signed-off-by: Paul Jackson Signed-off-by: Andrew Morton --- mm/page_alloc.c | 28 ++++++++++++++-------------- 1 files changed, 14 insertions(+), 14 deletions(-) diff -puN mm/page_alloc.c~mm-redo-alloc_-flag-names-again mm/page_alloc.c --- devel/mm/page_alloc.c~mm-redo-alloc_-flag-names-again 2005-11-22 22:30:22.000000000 -0800 +++ devel-akpm/mm/page_alloc.c 2005-11-22 22:30:22.000000000 -0800 @@ -772,10 +772,10 @@ again: return page; } -#define ALLOC_DONT_DIP 0x01 /* don't dip into memory reserves */ -#define ALLOC_DIP_SOME 0x02 /* dip into reserves some */ -#define ALLOC_DIP_ALOT 0x04 /* dip into reserves further */ -#define ALLOC_MUSTHAVE 0x08 /* ignore all constraints */ +#define ALLOC_DIP_NONE 0x01 /* don't dip into memory reserves */ +#define ALLOC_DIP_LESS 0x02 /* dip into reserves some */ +#define ALLOC_DIP_MORE 0x04 /* dip into reserves further */ +#define ALLOC_DIP_FULL 0x08 /* ignore all constraints */ /* * Return 1 if free pages are above 'mark'. This takes into account the order @@ -788,9 +788,9 @@ int zone_watermark_ok(struct zone *z, in long min = mark, free_pages = z->free_pages - (1 << order) + 1; int o; - if (alloc_flags & ALLOC_DIP_SOME) + if (alloc_flags & ALLOC_DIP_LESS) min -= min / 2; - if (alloc_flags & ALLOC_DIP_ALOT) + if (alloc_flags & ALLOC_DIP_MORE) min -= min / 4; if (free_pages <= min + z->lowmem_reserve[classzone_idx]) @@ -825,8 +825,8 @@ get_page_from_freelist(gfp_t gfp_mask, u * See also cpuset_zone_allowed() comment in kernel/cpuset.c. */ do { - if (!(alloc_flags & ALLOC_MUSTHAVE)) { - if (alloc_flags == ALLOC_DONT_DIP) + if (!(alloc_flags & ALLOC_DIP_FULL)) { + if (alloc_flags == ALLOC_DIP_NONE) gfp_mask |= __GFP_HARDWALL; if (!cpuset_zone_allowed(*z, gfp_mask)) continue; @@ -870,7 +870,7 @@ restart: return NULL; } - page = get_page_from_freelist(gfp_mask,order,zonelist,ALLOC_DONT_DIP); + page = get_page_from_freelist(gfp_mask,order,zonelist,ALLOC_DIP_NONE); if (page) goto got_pg; @@ -886,13 +886,13 @@ restart: * The caller may dip into page reserves a bit more if the caller * cannot run direct reclaim, or if the caller has realtime scheduling * policy or is asking for __GFP_HIGH memory. GFP_ATOMIC requests will - * set both ALLOC_DIP_ALOT (!wait) and ALLOC_DIP_SOME (__GFP_HIGH). + * set both ALLOC_DIP_MORE (!wait) and ALLOC_DIP_LESS (__GFP_HIGH). */ alloc_flags = 0; if ((unlikely(rt_task(p)) && !in_interrupt()) || !wait) - alloc_flags |= ALLOC_DIP_ALOT; + alloc_flags |= ALLOC_DIP_MORE; if (gfp_mask & __GFP_HIGH) - alloc_flags |= ALLOC_DIP_SOME; + alloc_flags |= ALLOC_DIP_LESS; page = get_page_from_freelist(gfp_mask, order, zonelist, alloc_flags); if (page) @@ -906,7 +906,7 @@ restart: nofail_alloc: /* go through the zonelist yet again, ignoring mins */ page = get_page_from_freelist(gfp_mask, order, - zonelist, ALLOC_MUSTHAVE); + zonelist, ALLOC_DIP_FULL); if (page) goto got_pg; if (gfp_mask & __GFP_NOFAIL) { @@ -949,7 +949,7 @@ rebalance: * under heavy pressure. */ page = get_page_from_freelist(gfp_mask, order, - zonelist, ALLOC_DONT_DIP); + zonelist, ALLOC_DIP_NONE); if (page) goto got_pg; _