mm: kswapd: reset kswapd_max_order and classzone_idx after reading
[pandora-kernel.git] / mm / vmscan.c
index 46711f0..dafb9d9 100644 (file)
@@ -2653,6 +2653,8 @@ static int kswapd(void *p)
                        kswapd_try_to_sleep(pgdat, order);
                        order = pgdat->kswapd_max_order;
                        classzone_idx = pgdat->classzone_idx;
+                       pgdat->kswapd_max_order = 0;
+                       pgdat->classzone_idx = MAX_NR_ZONES - 1;
                }
 
                ret = try_to_freeze();