Thread (8 messages) 8 messages, 2 authors, 2012-08-25

Re: [PATCH 2/5] vmscan: sleep only if backingdev is congested

From: Rik van Riel <hidden>
Date: 2012-08-25 23:03:07
Also in: lkml

On 08/22/2012 03:15 AM, Minchan Kim wrote:
quoted hunk ↗ jump to hunk
+++ b/mm/vmscan.c
@@ -2705,8 +2705,16 @@ loop_again:
  		if (total_scanned && (sc.priority < DEF_PRIORITY - 2)) {
  			if (has_under_min_watermark_zone)
  				count_vm_event(KSWAPD_SKIP_CONGESTION_WAIT);
-			else
-				congestion_wait(BLK_RW_ASYNC, HZ/10);
+			else {
+				for (i = 0; i <= end_zone; i++) {
+					struct zone *zone = pgdat->node_zones
+								+ i;
+					if (!populated_zone(zone))
+						continue;
+					wait_iff_congested(zone, BLK_RW_ASYNC,
+								HZ/10);
+				}
+			}
  		}
Do we really want to wait on every zone?

That could increase the sleep time by a factor 3.

-- 
All rights reversed

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help