|
@@ -1942,9 +1942,24 @@ zonelist_scan:
|
|
|
continue;
|
|
|
default:
|
|
|
/* did we reclaim enough */
|
|
|
- if (!zone_watermark_ok(zone, order, mark,
|
|
|
+ if (zone_watermark_ok(zone, order, mark,
|
|
|
classzone_idx, alloc_flags))
|
|
|
+ goto try_this_zone;
|
|
|
+
|
|
|
+ /*
|
|
|
+ * Failed to reclaim enough to meet watermark.
|
|
|
+ * Only mark the zone full if checking the min
|
|
|
+ * watermark or if we failed to reclaim just
|
|
|
+ * 1<<order pages or else the page allocator
|
|
|
+ * fastpath will prematurely mark zones full
|
|
|
+ * when the watermark is between the low and
|
|
|
+ * min watermarks.
|
|
|
+ */
|
|
|
+ if (((alloc_flags & ALLOC_WMARK_MASK) == ALLOC_WMARK_MIN) ||
|
|
|
+ ret == ZONE_RECLAIM_SOME)
|
|
|
goto this_zone_full;
|
|
|
+
|
|
|
+ continue;
|
|
|
}
|
|
|
}
|
|
|
|