aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAndy Whitcroft <apw@shadowen.org>2006-02-01 06:05:27 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-02-01 11:53:15 -0500
commitce2ea89ba101d976907128441ba3aca72a8804b9 (patch)
treef08184cdd2c70eff0018c49ceee94a0b25b3b5f0 /include
parent79046ae07ae21245520ca0aab985ee6678a879f8 (diff)
[PATCH] GFP_ZONETYPES: calculate from GFP_ZONEMASK
GFP_ZONETYPES calculate from GFP_ZONEMASK GFP_ZONETYPES's value is directly related to the value of GFP_ZONEMASK. It takes one of two forms depending whether the top bit of GFP_ZONEMASK is a 'loner'. Supply both forms, enabling the loner. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mmzone.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h
index 88c30f844abf..ebfc238cc243 100644
--- a/include/linux/mmzone.h
+++ b/include/linux/mmzone.h
@@ -98,11 +98,14 @@ struct per_cpu_pageset {
98 * of three zone modifier bits, we could require up to eight zonelists. 98 * of three zone modifier bits, we could require up to eight zonelists.
99 * If the left most zone modifier is a "loner" then the highest valid 99 * If the left most zone modifier is a "loner" then the highest valid
100 * zonelist would be four allowing us to allocate only five zonelists. 100 * zonelist would be four allowing us to allocate only five zonelists.
101 * Use the first form for GFP_ZONETYPES when the left most bit is not
102 * a "loner", otherwise use the second.
101 * 103 *
102 * NOTE! Make sure this matches the zones in <linux/gfp.h> 104 * NOTE! Make sure this matches the zones in <linux/gfp.h>
103 */ 105 */
104#define GFP_ZONEMASK 0x07 106#define GFP_ZONEMASK 0x07
105#define GFP_ZONETYPES 5 107/* #define GFP_ZONETYPES (GFP_ZONEMASK + 1) */ /* Non-loner */
108#define GFP_ZONETYPES ((GFP_ZONEMASK + 1) / 2 + 1) /* Loner */
106 109
107/* 110/*
108 * On machines where it is needed (eg PCs) we divide physical memory 111 * On machines where it is needed (eg PCs) we divide physical memory