Skip to content

Commit

Permalink
slub: fix bug in slub debug support
Browse files Browse the repository at this point in the history
We ClearSlabDebug() before the last SlabDebug() check. Clear it later.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Christoph Lameter <clameter@sgi.com>
  • Loading branch information
Peter Zijlstra authored and Christoph Lameter committed Jul 30, 2007
1 parent 02febdf commit 2208b76
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mm/slub.c
Original file line number Diff line number Diff line change
Expand Up @@ -1131,6 +1131,7 @@ static void __free_slab(struct kmem_cache *s, struct page *page)
slab_pad_check(s, page);
for_each_object(p, s, page_address(page))
check_object(s, page, p, 0);
ClearSlabDebug(page);
}

mod_zone_page_state(page_zone(page),
Expand Down Expand Up @@ -1169,7 +1170,6 @@ static void discard_slab(struct kmem_cache *s, struct page *page)

atomic_long_dec(&n->nr_slabs);
reset_page_mapcount(page);
ClearSlabDebug(page);
__ClearPageSlab(page);
free_slab(s, page);
}
Expand Down

0 comments on commit 2208b76

Please sign in to comment.