diff options
Diffstat (limited to 'include/linux/mmzone.h')
-rw-r--r-- | include/linux/mmzone.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 0aa4445b0b8a..dd8487f0442f 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h | |||
@@ -163,6 +163,17 @@ static inline int is_unevictable_lru(enum lru_list l) | |||
163 | #endif | 163 | #endif |
164 | } | 164 | } |
165 | 165 | ||
166 | enum zone_watermarks { | ||
167 | WMARK_MIN, | ||
168 | WMARK_LOW, | ||
169 | WMARK_HIGH, | ||
170 | NR_WMARK | ||
171 | }; | ||
172 | |||
173 | #define min_wmark_pages(z) (z->watermark[WMARK_MIN]) | ||
174 | #define low_wmark_pages(z) (z->watermark[WMARK_LOW]) | ||
175 | #define high_wmark_pages(z) (z->watermark[WMARK_HIGH]) | ||
176 | |||
166 | struct per_cpu_pages { | 177 | struct per_cpu_pages { |
167 | int count; /* number of pages in the list */ | 178 | int count; /* number of pages in the list */ |
168 | int high; /* high watermark, emptying needed */ | 179 | int high; /* high watermark, emptying needed */ |
@@ -275,7 +286,10 @@ struct zone_reclaim_stat { | |||
275 | 286 | ||
276 | struct zone { | 287 | struct zone { |
277 | /* Fields commonly accessed by the page allocator */ | 288 | /* Fields commonly accessed by the page allocator */ |
278 | unsigned long pages_min, pages_low, pages_high; | 289 | |
290 | /* zone watermarks, access with *_wmark_pages(zone) macros */ | ||
291 | unsigned long watermark[NR_WMARK]; | ||
292 | |||
279 | /* | 293 | /* |
280 | * We don't know if the memory that we're going to allocate will be freeable | 294 | * We don't know if the memory that we're going to allocate will be freeable |
281 | * or/and it will be released eventually, so to avoid totally wasting several | 295 | * or/and it will be released eventually, so to avoid totally wasting several |