* lockdep and oops_in_progress @ 2010-08-05 6:21 Dave Airlie 2010-08-05 8:10 ` Peter Zijlstra 0 siblings, 1 reply; 7+ messages in thread From: Dave Airlie @ 2010-08-05 6:21 UTC (permalink / raw) To: Peter Zijlstra, Ingo Molnar, Jesse Barnes; +Cc: LKML Hi guys, I was debugging a wierd issue with suspend/resume and fbcon/X with some recent work Jesse and myself did to try and make sure a pinned fbcon always gets the text on it with a panic or oops occurs. It does this by testing the oops_in_progress flag, however once any lockdep issue occurs it looks to me that we leave this flag set forever, in most places I can see in oops code etc they call bust_spinlocks(1) then bust_spinlocks(0) to balance the oops_in_progress value, but lockdep never seems to reset it. I'm wondering if there is an inherent reason for this or if I whip up a patch to reset once the lockdep is printed if this would cause any issues? Dave. ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: lockdep and oops_in_progress 2010-08-05 6:21 lockdep and oops_in_progress Dave Airlie @ 2010-08-05 8:10 ` Peter Zijlstra 2010-08-05 14:59 ` Yong Zhang 0 siblings, 1 reply; 7+ messages in thread From: Peter Zijlstra @ 2010-08-05 8:10 UTC (permalink / raw) To: Dave Airlie; +Cc: Ingo Molnar, Jesse Barnes, LKML On Thu, 2010-08-05 at 16:21 +1000, Dave Airlie wrote: > Hi guys, > > I was debugging a wierd issue with suspend/resume and fbcon/X with > some recent work Jesse and myself did to try and make sure a pinned > fbcon always gets the text on it with a panic or oops occurs. > > It does this by testing the oops_in_progress flag, however once any > lockdep issue occurs it looks to me that we leave this flag set > forever, in most places I can see in oops code etc they call > bust_spinlocks(1) then bust_spinlocks(0) to balance the > oops_in_progress value, but lockdep never seems to reset it. > > I'm wondering if there is an inherent reason for this or if I whip up > a patch to reset once the lockdep is printed if this would cause any > issues? That's debug_locks_off(), right? I don't think there's a particular reason we keep it set, cleaning that up might take a bit of work but shouldn't be too hard. Ingo, do you remember anything about that?, I think that bit comes from before my time. ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: lockdep and oops_in_progress 2010-08-05 8:10 ` Peter Zijlstra @ 2010-08-05 14:59 ` Yong Zhang 2010-09-23 3:57 ` Dave Airlie 2010-11-02 20:51 ` Dave Airlie 0 siblings, 2 replies; 7+ messages in thread From: Yong Zhang @ 2010-08-05 14:59 UTC (permalink / raw) To: Peter Zijlstra Cc: Dave Airlie, Ingo Molnar, Jesse Barnes, LKML, David S. Miller On Thu, Aug 05, 2010 at 10:10:49AM +0200, Peter Zijlstra wrote: > On Thu, 2010-08-05 at 16:21 +1000, Dave Airlie wrote: > > Hi guys, > > > > I was debugging a wierd issue with suspend/resume and fbcon/X with > > some recent work Jesse and myself did to try and make sure a pinned > > fbcon always gets the text on it with a panic or oops occurs. > > > > It does this by testing the oops_in_progress flag, however once any > > lockdep issue occurs it looks to me that we leave this flag set > > forever, in most places I can see in oops code etc they call > > bust_spinlocks(1) then bust_spinlocks(0) to balance the > > oops_in_progress value, but lockdep never seems to reset it. > > > > I'm wondering if there is an inherent reason for this or if I whip up > > a patch to reset once the lockdep is printed if this would cause any > > issues? > > That's debug_locks_off(), right? I don't think there's a particular > reason we keep it set, cleaning that up might take a bit of work but > shouldn't be too hard. commit e0fdace10e75dac67d906213b780ff1b1a4cc360 Author: David Miller <davem@davemloft.net> Date: Fri Aug 1 01:11:22 2008 -0700 debug_locks: set oops_in_progress if we will log messages. Otherwise lock debugging messages on runqueue locks can deadlock the system due to the wakeups performed by printk(). Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Ingo Molnar <mingo@elte.hu> Seems we can revert that commit now because of 'robustify printk'. Dave, what do you think about it? Thanks, Yong > > Ingo, do you remember anything about that?, I think that bit comes from > before my time. > -- > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.tux.org/lkml/ ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: lockdep and oops_in_progress 2010-08-05 14:59 ` Yong Zhang @ 2010-09-23 3:57 ` Dave Airlie 2010-11-02 20:51 ` Dave Airlie 1 sibling, 0 replies; 7+ messages in thread From: Dave Airlie @ 2010-09-23 3:57 UTC (permalink / raw) To: Yong Zhang Cc: Peter Zijlstra, Ingo Molnar, Jesse Barnes, LKML, David S. Miller On Fri, Aug 6, 2010 at 12:59 AM, Yong Zhang <yong.zhang0@gmail.com> wrote: > On Thu, Aug 05, 2010 at 10:10:49AM +0200, Peter Zijlstra wrote: >> On Thu, 2010-08-05 at 16:21 +1000, Dave Airlie wrote: >> > Hi guys, >> > >> > I was debugging a wierd issue with suspend/resume and fbcon/X with >> > some recent work Jesse and myself did to try and make sure a pinned >> > fbcon always gets the text on it with a panic or oops occurs. >> > >> > It does this by testing the oops_in_progress flag, however once any >> > lockdep issue occurs it looks to me that we leave this flag set >> > forever, in most places I can see in oops code etc they call >> > bust_spinlocks(1) then bust_spinlocks(0) to balance the >> > oops_in_progress value, but lockdep never seems to reset it. >> > >> > I'm wondering if there is an inherent reason for this or if I whip up >> > a patch to reset once the lockdep is printed if this would cause any >> > issues? >> >> That's debug_locks_off(), right? I don't think there's a particular >> reason we keep it set, cleaning that up might take a bit of work but >> shouldn't be too hard. > > commit e0fdace10e75dac67d906213b780ff1b1a4cc360 > Author: David Miller <davem@davemloft.net> > Date: Fri Aug 1 01:11:22 2008 -0700 > > debug_locks: set oops_in_progress if we will log messages. > > Otherwise lock debugging messages on runqueue locks can deadlock the > system due to the wakeups performed by printk(). > > Signed-off-by: David S. Miller <davem@davemloft.net> > Signed-off-by: Ingo Molnar <mingo@elte.hu> > > Seems we can revert that commit now because of 'robustify printk'. > > Dave, what do you think about it? DaveM ping? I should probably just push for the revert if printk is robust enough now. Dave. ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: lockdep and oops_in_progress 2010-08-05 14:59 ` Yong Zhang 2010-09-23 3:57 ` Dave Airlie @ 2010-11-02 20:51 ` Dave Airlie 2010-11-02 20:53 ` David Miller 2010-11-02 20:54 ` David Miller 1 sibling, 2 replies; 7+ messages in thread From: Dave Airlie @ 2010-11-02 20:51 UTC (permalink / raw) To: Yong Zhang Cc: Peter Zijlstra, Ingo Molnar, Jesse Barnes, LKML, David S. Miller On Fri, Aug 6, 2010 at 12:59 AM, Yong Zhang <yong.zhang0@gmail.com> wrote: > On Thu, Aug 05, 2010 at 10:10:49AM +0200, Peter Zijlstra wrote: >> On Thu, 2010-08-05 at 16:21 +1000, Dave Airlie wrote: >> > Hi guys, >> > >> > I was debugging a wierd issue with suspend/resume and fbcon/X with >> > some recent work Jesse and myself did to try and make sure a pinned >> > fbcon always gets the text on it with a panic or oops occurs. >> > >> > It does this by testing the oops_in_progress flag, however once any >> > lockdep issue occurs it looks to me that we leave this flag set >> > forever, in most places I can see in oops code etc they call >> > bust_spinlocks(1) then bust_spinlocks(0) to balance the >> > oops_in_progress value, but lockdep never seems to reset it. >> > >> > I'm wondering if there is an inherent reason for this or if I whip up >> > a patch to reset once the lockdep is printed if this would cause any >> > issues? >> >> That's debug_locks_off(), right? I don't think there's a particular >> reason we keep it set, cleaning that up might take a bit of work but >> shouldn't be too hard. > > commit e0fdace10e75dac67d906213b780ff1b1a4cc360 > Author: David Miller <davem@davemloft.net> > Date: Fri Aug 1 01:11:22 2008 -0700 > > debug_locks: set oops_in_progress if we will log messages. > > Otherwise lock debugging messages on runqueue locks can deadlock the > system due to the wakeups performed by printk(). > > Signed-off-by: David S. Miller <davem@davemloft.net> > Signed-off-by: Ingo Molnar <mingo@elte.hu> > > Seems we can revert that commit now because of 'robustify printk'. > > Dave, what do you think about it? Hey DaveM, as mentioned at KS, Dave. ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: lockdep and oops_in_progress 2010-11-02 20:51 ` Dave Airlie @ 2010-11-02 20:53 ` David Miller 2010-11-02 20:54 ` David Miller 1 sibling, 0 replies; 7+ messages in thread From: David Miller @ 2010-11-02 20:53 UTC (permalink / raw) To: airlied; +Cc: yong.zhang0, peterz, mingo, jbarnes, linux-kernel From: Dave Airlie <airlied@gmail.com> Date: Wed, 3 Nov 2010 06:51:07 +1000 > Hey DaveM, as mentioned at KS, Thanks, will take a look. ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: lockdep and oops_in_progress 2010-11-02 20:51 ` Dave Airlie 2010-11-02 20:53 ` David Miller @ 2010-11-02 20:54 ` David Miller 1 sibling, 0 replies; 7+ messages in thread From: David Miller @ 2010-11-02 20:54 UTC (permalink / raw) To: airlied; +Cc: yong.zhang0, peterz, mingo, jbarnes, linux-kernel From: Dave Airlie <airlied@gmail.com> Date: Wed, 3 Nov 2010 06:51:07 +1000 >> commit e0fdace10e75dac67d906213b780ff1b1a4cc360 >> Author: David Miller <davem@davemloft.net> >> Date: Fri Aug 1 01:11:22 2008 -0700 >> >> debug_locks: set oops_in_progress if we will log messages. >> >> Otherwise lock debugging messages on runqueue locks can deadlock the >> system due to the wakeups performed by printk(). >> >> Signed-off-by: David S. Miller <davem@davemloft.net> >> Signed-off-by: Ingo Molnar <mingo@elte.hu> >> >> Seems we can revert that commit now because of 'robustify printk'. I completely agree, this can definitely be reverted. Thanks! ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2010-11-02 20:54 UTC | newest] Thread overview: 7+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2010-08-05 6:21 lockdep and oops_in_progress Dave Airlie 2010-08-05 8:10 ` Peter Zijlstra 2010-08-05 14:59 ` Yong Zhang 2010-09-23 3:57 ` Dave Airlie 2010-11-02 20:51 ` Dave Airlie 2010-11-02 20:53 ` David Miller 2010-11-02 20:54 ` David Miller
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).