mm, vmscan: prevent kswapd sleeping prematurely due to mismatched classzone_idx -fix
Subsystems (2)
PATCH 1/1 mm, vmscan: prevent kswapd sleeping prematurely due to mismatched classzone_idx -fix
The patch "mm, vmscan: prevent kswapd sleeping prematurely due to mismatched classzone_idx" has different initial starting conditions when kswapd is asleep. kswapd initialises it properly when it starts but the patch initialises kswapd_classzone_idx early and trips on a warning in free_area_init_node. This patch leaves the kswapd_classzone_idx as zero and defers to kswapd to initialise it properly when it starts.
This is a fix to the mmotm patch mm-vmscan-prevent-kswapd-sleeping-prematurely-due-to-mismatched-classzone_idx.patch
--- mm/memory_hotplug.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)
mm/memory_hotplug.c +6 -2
@@ -1214,10 +1214,14 @@ static pg_data_t __ref *hotadd_new_pgdat(int nid, u64 start)arch_refresh_nodedata (nid, pgdat); }else { -/* Reset the nr_zones, order and classzone_idx before reuse */ +/* +* Reset the nr_zones, order and classzone_idx before reuse. +* Note that kswapd will init kswapd_classzone_idx properly +* when it starts in the near future. +*/ pgdat->nr_zones =0 ; pgdat->kswapd_order =0 ; - pgdat->kswapd_classzone_idx =MAX_NR_ZONES ; + pgdat->kswapd_classzone_idx =0 ; }/* we can use NODE_DATA(nid) from here */
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>