[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200903152006.21160.nickpiggin@yahoo.com.au>
Date: Sun, 15 Mar 2009 20:06:20 +1100
From: Nick Piggin <nickpiggin@...oo.com.au>
To: Ingo Molnar <mingo@...e.hu>
Cc: linux-tip-commits@...r.kernel.org, Nick Piggin <npiggin@...e.de>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
Pekka Enberg <penberg@...helsinki.fi>,
Matt Mackall <mpm@...enic.com>, linux-kernel@...r.kernel.org,
hpa@...or.com, mingo@...hat.com, tglx@...utronix.de
Subject: Re: SLOB lockup (was: Re: [tip:core/locking] lockdep: annotate reclaim context (__GFP_NOFS), fix SLOB)
On Sunday 15 March 2009 17:48:18 Ingo Molnar wrote:
> > Cc: Nick Piggin <npiggin@...e.de>
> > Cc: Peter Zijlstra <a.p.zijlstra@...llo.nl>
> > LKML-Reference: <20090128135457.350751756@...llo.nl>
> > Signed-off-by: Ingo Molnar <mingo@...e.hu>
>
> and with this fixed, and with SLOB now being tested in -tip, the
> new lockdep assert attached below (followed by a real lockup)
> pops up.
>
> Seems like a genuine SLOB bug, probably present upstream as
> well.
Hmmf. debugobjects calls back into the slab allocator from the page
allocator. The following patch would improve SLOB, but I think it
would be a good idea to avoid a dependency in that direction. Can
debugobjects defer this freeing?
---
mm/slob.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
Index: linux-2.6/mm/slob.c
===================================================================
--- linux-2.6.orig/mm/slob.c
+++ linux-2.6/mm/slob.c
@@ -390,13 +390,14 @@ static void slob_free(void *block, int s
spin_lock_irqsave(&slob_lock, flags);
if (sp->units + units == SLOB_UNITS(PAGE_SIZE)) {
+ spin_lock_irqrestore(&slob_lock, flags);
/* Go directly to page allocator. Do not pass slob allocator */
if (slob_page_free(sp))
clear_slob_page_free(sp);
clear_slob_page(sp);
free_slob_page(sp);
free_page((unsigned long)b);
- goto out;
+ return;
}
if (!slob_page_free(sp)) {
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists