diff options
author | David Miller <davem@davemloft.net> | 2008-08-01 10:11:22 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-08-01 10:46:43 +0200 |
commit | e0fdace10e75dac67d906213b780ff1b1a4cc360 (patch) | |
tree | ca0ab78da383bfe44512bc33a1431d1a9dc4537f /lib/debug_locks.c | |
parent | lockdep: fix combinatorial explosion in lock subgraph traversal (diff) | |
download | linux-e0fdace10e75dac67d906213b780ff1b1a4cc360.tar.xz linux-e0fdace10e75dac67d906213b780ff1b1a4cc360.zip |
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>
Diffstat (limited to 'lib/debug_locks.c')
-rw-r--r-- | lib/debug_locks.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/debug_locks.c b/lib/debug_locks.c index 0ef01d14727c..0218b4693dd8 100644 --- a/lib/debug_locks.c +++ b/lib/debug_locks.c @@ -8,6 +8,7 @@ * * Copyright (C) 2006 Red Hat, Inc., Ingo Molnar <mingo@redhat.com> */ +#include <linux/kernel.h> #include <linux/rwsem.h> #include <linux/mutex.h> #include <linux/module.h> @@ -37,6 +38,7 @@ int debug_locks_off(void) { if (xchg(&debug_locks, 0)) { if (!debug_locks_silent) { + oops_in_progress = 1; console_verbose(); return 1; } |