diff options
Diffstat (limited to 'mm')
-rw-r--r-- | mm/page_alloc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 228194728ccd..2e6635993558 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c | |||
@@ -1595,6 +1595,7 @@ static bool __zone_watermark_ok(struct zone *z, int order, unsigned long mark, | |||
1595 | { | 1595 | { |
1596 | /* free_pages my go negative - that's OK */ | 1596 | /* free_pages my go negative - that's OK */ |
1597 | long min = mark; | 1597 | long min = mark; |
1598 | long lowmem_reserve = z->lowmem_reserve[classzone_idx]; | ||
1598 | int o; | 1599 | int o; |
1599 | 1600 | ||
1600 | free_pages -= (1 << order) - 1; | 1601 | free_pages -= (1 << order) - 1; |
@@ -1603,7 +1604,7 @@ static bool __zone_watermark_ok(struct zone *z, int order, unsigned long mark, | |||
1603 | if (alloc_flags & ALLOC_HARDER) | 1604 | if (alloc_flags & ALLOC_HARDER) |
1604 | min -= min / 4; | 1605 | min -= min / 4; |
1605 | 1606 | ||
1606 | if (free_pages <= min + z->lowmem_reserve[classzone_idx]) | 1607 | if (free_pages <= min + lowmem_reserve) |
1607 | return false; | 1608 | return false; |
1608 | for (o = 0; o < order; o++) { | 1609 | for (o = 0; o < order; o++) { |
1609 | /* At the next order, this order's pages become unavailable */ | 1610 | /* At the next order, this order's pages become unavailable */ |