Re: [patch] lock debugging: fix DEBUG_LOCKS_WARN_ON() & debug_locks_silent

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Matthew Wilcox <[email protected]> wrote:

> On Tue, Dec 19, 2006 at 10:31:35AM +0100, Ingo Molnar wrote:
> > 
> > * Jarek Poplawski <[email protected]> wrote:
> > 
> > > >  	if (unlikely(c)) {						\
> > > > -		if (debug_locks_silent || debug_locks_off())		\
> > > > +		if (!debug_locks_silent && debug_locks_off())		\
> > 
> > btw., updated patch is below - the right order is to first do 
> > debug_locks_off(), then debug_locks_silent.
> 
> Then how does one re-enable lock debugging after running the locking 
> testsuite?

see the lib/locking-selftest.c:locking_selftest() function, if all 
testcases pass then it re-enables lock debugging. If a testcase turns 
off lock debugging because it triggers a bug (as many of them 
legitimately do), then reset_locks()->lockdep_reset() will set 
debug_locks back to 1.

	Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux