From: Paul Jackson Date: Wed, 22 Mar 2006 08:09:11 +0000 (-0800) Subject: [PATCH] mm: slab cache interleave rotor fix X-Git-Tag: v2.6.17-rc1~1129^2~17 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=442295c94bf650221af3ef20fc68fa3e93876818;p=linux-2.6 [PATCH] mm: slab cache interleave rotor fix The alien cache rotor in mm/slab.c assumes that the first online node is node 0. Eventually for some archs, especially with hotplug, this will no longer be true. Fix the interleave rotor to handle the general case of node numbering. Signed-off-by: Paul Jackson Acked-by: Christoph Lameter Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/slab.c b/mm/slab.c index 6b691ecbac..1c8f5ee230 100644 --- a/mm/slab.c +++ b/mm/slab.c @@ -830,7 +830,7 @@ static void init_reap_node(int cpu) node = next_node(cpu_to_node(cpu), node_online_map); if (node == MAX_NUMNODES) - node = 0; + node = first_node(node_online_map); __get_cpu_var(reap_node) = node; }