LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH -rt] make spin_unlock to slab_spin_unlock
@ 2007-01-22 19:15 Steven Rostedt
  2007-01-22 19:18 ` Ingo Molnar
  0 siblings, 1 reply; 2+ messages in thread
From: Steven Rostedt @ 2007-01-22 19:15 UTC (permalink / raw)
  To: Ingo Molnar; +Cc: LKML


Ingo,

I hit this bug on one of my work test machines. This bug is probably what
caused my laptop to crash ever so often too, but since I don't have a
serial or other debug output, my laptop never showed what was wrong.

Here's the call trace:

------------[ cut here ]------------
kernel BUG at kernel/rtmutex.c:649!
invalid opcode: 0000 [1] PREEMPT SMP
CPU 2
[...]
Call Trace:
 [<ffffffff802661a7>] rt_spin_lock+0x1f/0x21
 [<ffffffff802df73b>] drain_freelist+0x4f/0xeb
 [<ffffffff802df941>] cache_reap+0x16a/0x26d
 [<ffffffff8024f29e>] run_workqueue+0x9f/0xf9
 [<ffffffff8024bbe3>] worker_thread+0x11b/0x152
 [<ffffffff80233fcb>] kthread+0xee/0x11a
 [<ffffffff802600f8>] child_rip+0xa/0x12


Seems that the goto out of the loop was not updated to be a
slab_spin_unlock, so there was a way out that would not unlock the slab
cpu lock.

-- Steve

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

Index: linux-2.6.20-rc5-rt7/mm/slab.c
===================================================================
--- linux-2.6.20-rc5-rt7.orig/mm/slab.c	2007-01-22 14:05:35.000000000 -0500
+++ linux-2.6.20-rc5-rt7/mm/slab.c	2007-01-22 14:06:07.000000000 -0500
@@ -2564,7 +2564,7 @@ static int drain_freelist(struct kmem_ca
 		slab_spin_lock_irq(&l3->list_lock, this_cpu);
 		p = l3->slabs_free.prev;
 		if (p == &l3->slabs_free) {
-			spin_unlock_irq(&l3->list_lock);
+			slab_spin_unlock_irq(&l3->list_lock, this_cpu);
 			goto out;
 		}



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH -rt] make spin_unlock to slab_spin_unlock
  2007-01-22 19:15 [PATCH -rt] make spin_unlock to slab_spin_unlock Steven Rostedt
@ 2007-01-22 19:18 ` Ingo Molnar
  0 siblings, 0 replies; 2+ messages in thread
From: Ingo Molnar @ 2007-01-22 19:18 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: LKML


* Steven Rostedt <rostedt@goodmis.org> wrote:

> I hit this bug on one of my work test machines. This bug is probably 
> what caused my laptop to crash ever so often too, but since I don't 
> have a serial or other debug output, my laptop never showed what was 
> wrong.

ah, nice one! Thanks, applied,

	Ingo

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-01-22 19:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-22 19:15 [PATCH -rt] make spin_unlock to slab_spin_unlock Steven Rostedt
2007-01-22 19:18 ` Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).