Subject: Re: [Bug 10575] New: WARNING: at mm/slub.c:2444

From: Pekka Enberg <[email-masked]>
Date: Tue, 29 Apr 2008 22:39:13 +0300

Andrew Morton wrote:
> Sorry, I confused it with a similar-looking USB trace.  Pekka added some
> additional debug at that site which might help here - it will tell us the
> name of the slab cache:
> 
> void kmem_cache_destroy(struct kmem_cache *s)
> {
> 	down_write(&slub_lock);
> 	s->refcount--;
> 	if (!s->refcount) {
> 		list_del(&s->list);
> 		up_write(&slub_lock);
> 		if (kmem_cache_close(s)) {
> 			printk(KERN_ERR "SLUB %s: %s called for cache that "
> 				"still has objects.\n", s->name, __func__);
> 			dump_stack();
> 		}
> 		sysfs_slab_remove(s);
> 	} else
> 		up_write(&slub_lock);
> }
> 			
> that was merged into mainline yesterday.

Christoph added even nicer debugging code that dumps the objects in the 
cache:

http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=33b12c38134e95e5afa73214af6f49abd7b8418e