Re: [RFC 1/2] workqueue: use the nearest NUMA node, not the local one

2014-07-18 Thread Nish Aravamudan
[ Apologies for replying from a different address, we have a service outage at work. ] On Fri, Jul 18, 2014 at 1:11 AM, Lai Jiangshan wrote: > > Hi, Thank you for your response! > I'm curious about what will it happen when alloc_pages_node(memoryless_node). alloc_pages_node() is only involved

Re: [RFC 1/2] workqueue: use the nearest NUMA node, not the local one

2014-07-18 Thread Lai Jiangshan
Hi, I'm curious about what will it happen when alloc_pages_node(memoryless_node). If the memory is allocated from the most preferable node for the @memoryless_node, why we need to bother and use cpu_to_mem() in the caller site? If not, why the memory allocation subsystem refuses to find a prefe

[RFC 1/2] workqueue: use the nearest NUMA node, not the local one

2014-07-17 Thread Nishanth Aravamudan
In the presence of memoryless nodes, the workqueue code incorrectly uses cpu_to_node() to determine what node to prefer memory allocations come from. cpu_to_mem() should be used instead, which will use the nearest NUMA node with memory. Signed-off-by: Nishanth Aravamudan diff --git a/kernel/work