From 003b6350c3b6063fe6c54956a4205a94a08e907f Mon Sep 17 00:00:00 2001 From: Mel Gorman Date: Thu, 13 Jan 2011 15:46:24 -0800 Subject: [PATCH] --- yaml --- r: 230738 b: refs/heads/master c: 355b09c47a0cbb73b3e65a57c03f157f2e7ddb0b h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/mm/vmscan.c | 10 +++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index d5d608d6b2c8..b5fc1289df03 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 4d40502ea580c35414a1466d86f96484910ebaec +refs/heads/master: 355b09c47a0cbb73b3e65a57c03f157f2e7ddb0b diff --git a/trunk/mm/vmscan.c b/trunk/mm/vmscan.c index dafb9d91b604..388a0447b8e8 100644 --- a/trunk/mm/vmscan.c +++ b/trunk/mm/vmscan.c @@ -2244,8 +2244,16 @@ static bool sleeping_prematurely(pg_data_t *pgdat, int order, long remaining) if (!populated_zone(zone)) continue; - if (zone->all_unreclaimable) + /* + * balance_pgdat() skips over all_unreclaimable after + * DEF_PRIORITY. Effectively, it considers them balanced so + * they must be considered balanced here as well if kswapd + * is to sleep + */ + if (zone->all_unreclaimable) { + balanced += zone->present_pages; continue; + } if (!zone_watermark_ok_safe(zone, order, high_wmark_pages(zone), 0, 0))