Re: [PATCH] Run PCI driver initialization on local node

Andi Kleen
2005-07-07T10:41:39Z

On Wed, Jul 06, 2005 at 12:33:51PM -0700, Christoph Lameter wrote:
> On Wed, 6 Jul 2005, Andi Kleen wrote:
>
> > > That depends on the architecture. Some do round robin allocs for periods
> > > of time during bootup. I think it is better to explicitly place control
> >
> > slab will usually do the right thing because it has a forced
> > local node policy, but __gfp might not.
>
> The slab allocator will do the right thing with the numa slab allocator in
> Andrew's tree but not with the one in Linus'tree. The one is Linus tree
> will just pickup whatever slab is available irregardless of the node.

It should usually do the right thing because it
runs on the correct CPUs. The only case that doesn't work
is freeing on different CPUs than it was allocated, but hopefully
that is not too common during system startup.

And then at some point NUMA aware slab will make it into mainline
I guess.

> Only kmalloc_node will make a reasonable attempt to locate the memory on
> a specific node.

You forgot __get_free_pages.

-Andi