lkml.org 
[lkml]   [2008]   [May]   [13]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateTue, 13 May 2008 09:14:05 +0300
From"Pekka Enberg" <>
SubjectRe: [PATCH] SLUB: clear c->freelist in __slab_alloc()/load_freelist:/SlabDebug path
On Mon, May 12, 2008 at 11:32 PM, Benny Halevy <bhalevy@panasas.com> wrote:
> In the __slab_alloc()/load_freelist:/SlabDebug(c->page) path we only
> use the object at the head of c->page->freelist
> and the tail goes back to c->page->freelist.
> We then set c->node = -1 to force __slab_alloc in next allocation.
> c->freelist therefore needs to be cleared as it is invalid at this point.
>
> @@ -1606,6 +1606,7 @@ debug:
> if (!alloc_debug_processing(s, c->page, object, addr))
> goto another_slab;
>
> + c->freelist = NULL;
> c->page->inuse++;
> c->page->freelist = object[c->offset];
> c->node = -1;

Makes sense. Christoph?


\
 
 \ /
  Last update: 2008-05-13 08:17    [from the cache]
©2003-2009