Re: SLUB doesn't work with kdump kernel on Cell

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 8/15/07, Christoph Lameter <[email protected]> wrote:
> On Tue, 14 Aug 2007, Lucio Correia wrote:
>
> > > SLAB boots because it falls back to node 0 for the control structures. So
> > > it creates useless control structures for node 1. These are then never
> > > used since any allocation  attempt to node 1 falls back to node 0.
> >
> > Hi Christoph,
> >
> > Shouldn't SLUB falls back to other node also for the case it can't
> > allocate memory?
>
> Yes SLUB will fall back but not during bootstrap. Bootstrap needs to
> carefully place structures on the right nodes. We fail during bootstrap
> because there is *no* memory available on it.

Sure, you want to have the structures on the right node if possible.
But seeing as there's no memory available, what is wrong with just
falling back?

Something like:

diff --git a/mm/slub.c b/mm/slub.c
index 9b2d617..0fc29d2 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -1876,6 +1876,8 @@ static struct kmem_cache_node * __init early_kmem_cache_no
        BUG_ON(kmalloc_caches->size < sizeof(struct kmem_cache_node));

        page = new_slab(kmalloc_caches, gfpflags | GFP_THISNODE, node);
+       if (!page)
+               page = new_slab(kmalloc_caches, gfpflags, node);

        BUG_ON(!page);
        n = page->freelist;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux