spinlock deadlock

buyitian buyit at live.cn
Mon Feb 18 05:29:53 EST 2013


 > Date: Mon, 18 Feb 2013 10:54:44 +0100
> From: tglx at linutronix.de
> To: buyit at live.cn
> CC: mulyadi.santosa at gmail.com; kernelnewbies at kernelnewbies.org; a.p.zijlstra at chello.nl; rabin at rab.in; mingo at kernel.org
> Subject: RE: spinlock deadlock
> 
> On Sun, 17 Feb 2013, buyitian wrote:
> 
> Could you please use a mail client, which creates readable mail?
> 
> > this patch is to prevent deadlock between rq->lock and
> > logbuf_lock. i can understand this thanks to Rabin. 2. in patch
> > 07354eb1a74d1e1ece29f8bafe0b46e8c77a95ef, Thomas did changes as
> > below, which reverted the change from peter, i don't know why: in
> > function console_trylock_for_printk():
> 
> > - spin_unlock(&logbuf_lock);
> >   if (wake)
> >    up(&console_sem);
> > + raw_spin_unlock(&logbuf_lock);
> 
> > and this change exists in the latest kernel source code. it seems
> > that deadlock bewteen rq->lock and logbuf_lock comes back, who can
> > explain this, thanks.  BTW: if i place printk inside schedule(), i
> > may get rq->lock before calling printk.
> 
> That looks like a merge slipup. The patch which converts the lock is
> not supposed to do any other changes. But the patch was based on an
> older kernel version, which did not have Peters changes yet. So the
> fixup of the not longer applying patch failed somehow.  i will provide patch, thanks for your reply.
> 
> Thanks,
> 
> 	tglx
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20130218/36428bc9/attachment.html 


More information about the Kernelnewbies mailing list