The patch titled Subject: slub: fall back to node_to_mem_node() node if allocating on memoryless node has been removed from the -mm tree. Its filename was slub-fallback-to-node_to_mem_node-node-if-allocating-on-memoryless-node.patch This patch was dropped because it was merged into mainline or a subsystem tree ------------------------------------------------------ From: Joonsoo Kim <iamjoonsoo.kim@xxxxxxx> Subject: slub: fall back to node_to_mem_node() node if allocating on memoryless node Update the SLUB code to search for partial slabs on the nearest node with memory in the presence of memoryless nodes. Additionally, do not consider it to be an ALLOC_NODE_MISMATCH (and deactivate the slab) when a memoryless-node specified allocation goes off-node. Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@xxxxxxx> Signed-off-by: Nishanth Aravamudan <nacc@xxxxxxxxxxxxxxxxxx> Cc: David Rientjes <rientjes@xxxxxxxxxx> Cc: Han Pingtian <hanpt@xxxxxxxxxxxxxxxxxx> Cc: Pekka Enberg <penberg@xxxxxxxxxx> Cc: Paul Mackerras <paulus@xxxxxxxxx> Cc: Benjamin Herrenschmidt <benh@xxxxxxxxxxxxxxxxxxx> Cc: Michael Ellerman <mpe@xxxxxxxxxxxxxx> Cc: Anton Blanchard <anton@xxxxxxxxx> Cc: Christoph Lameter <cl@xxxxxxxxx> Cc: Wanpeng Li <liwanp@xxxxxxxxxxxxxxxxxx> Cc: Tejun Heo <tj@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/slub.c | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff -puN mm/slub.c~slub-fallback-to-node_to_mem_node-node-if-allocating-on-memoryless-node mm/slub.c --- a/mm/slub.c~slub-fallback-to-node_to_mem_node-node-if-allocating-on-memoryless-node +++ a/mm/slub.c @@ -1699,7 +1699,12 @@ static void *get_partial(struct kmem_cac struct kmem_cache_cpu *c) { void *object; - int searchnode = (node == NUMA_NO_NODE) ? numa_mem_id() : node; + int searchnode = node; + + if (node == NUMA_NO_NODE) + searchnode = numa_mem_id(); + else if (!node_present_pages(node)) + searchnode = node_to_mem_node(node); object = get_partial_node(s, get_node(s, searchnode), c, flags); if (object || node != NUMA_NO_NODE) @@ -2280,11 +2285,18 @@ static void *__slab_alloc(struct kmem_ca redo: if (unlikely(!node_match(page, node))) { - stat(s, ALLOC_NODE_MISMATCH); - deactivate_slab(s, page, c->freelist); - c->page = NULL; - c->freelist = NULL; - goto new_slab; + int searchnode = node; + + if (node != NUMA_NO_NODE && !node_present_pages(node)) + searchnode = node_to_mem_node(node); + + if (unlikely(!node_match(page, searchnode))) { + stat(s, ALLOC_NODE_MISMATCH); + deactivate_slab(s, page, c->freelist); + c->page = NULL; + c->freelist = NULL; + goto new_slab; + } } /* _ Patches currently in -mm which might be from iamjoonsoo.kim@xxxxxxx are origin.patch drivers-dma-coherent-add-initialization-from-device-tree.patch drivers-dma-coherent-add-initialization-from-device-tree-fix.patch drivers-dma-coherent-add-initialization-from-device-tree-fix-fix.patch drivers-dma-coherent-add-initialization-from-device-tree-checkpatch-fixes.patch drivers-dma-contiguous-add-initialization-from-device-tree.patch page-owners-correct-page-order-when-to-free-page.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html