Commit 6b187d02 authored by David Rientjes's avatar David Rientjes Committed by Linus Torvalds
Browse files

mm, numa: avoid setting zone_reclaim_mode unless a node is sufficiently distant

Commit 957f822a

 ("mm, numa: reclaim from all nodes within reclaim
distance") caused zone_reclaim_mode to be set for all systems where two
nodes are within RECLAIM_DISTANCE of each other.  This is the opposite
of what we actually want: zone_reclaim_mode should be set if two nodes
are sufficiently distant.
Signed-off-by: default avatarDavid Rientjes <>
Reported-by: default avatarJulian Wollrath <>
Tested-by: default avatarJulian Wollrath <>
Cc: Hugh Dickins <>
Cc: Patrik Kullman <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent f2302505
......@@ -1809,10 +1809,10 @@ static void __paginginit init_zone_allows_reclaim(int nid)
int i;
if (node_distance(nid, i) <= RECLAIM_DISTANCE) {
if (node_distance(nid, i) <= RECLAIM_DISTANCE)
node_set(i, NODE_DATA(nid)->reclaim_nodes);
zone_reclaim_mode = 1;
#else /* CONFIG_NUMA */
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment