mm, vmscan: simplify the logic deciding whether kswapd sleeps
[linux-block.git] / mm / memory_hotplug.c
index c5278360ca66733b45f96dea48fae7f61f85f3fc..065140ecd0816ff88e8d687760d6f7f70c7a60a8 100644 (file)
@@ -1209,9 +1209,10 @@ static pg_data_t __ref *hotadd_new_pgdat(int nid, u64 start)
 
                arch_refresh_nodedata(nid, pgdat);
        } else {
-               /* Reset the nr_zones and classzone_idx to 0 before reuse */
+               /* Reset the nr_zones, order and classzone_idx before reuse */
                pgdat->nr_zones = 0;
-               pgdat->classzone_idx = 0;
+               pgdat->kswapd_order = 0;
+               pgdat->kswapd_classzone_idx = 0;
        }
 
        /* we can use NODE_DATA(nid) from here */