diff options
| author | 2012-01-06 07:53:52 -0800 | |
|---|---|---|
| committer | 2012-01-06 07:53:52 -0800 | |
| commit | 15f043a65f655eb8a3aeb831a85da66de520c80f (patch) | |
| tree | 00f5dbc80796a41ef60320a52faeb68aa5755830 /kernel/panic.c | |
| parent | Merge branch 'core-debugobjects-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip (diff) | |
| parent | lockdep/waitqueues: Add better annotation (diff) | |
| download | wireguard-linux-15f043a65f655eb8a3aeb831a85da66de520c80f.tar.xz wireguard-linux-15f043a65f655eb8a3aeb831a85da66de520c80f.zip | |
Merge branch 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
* 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
lockdep/waitqueues: Add better annotation
lockdep, bug: Exclude TAINT_OOT_MODULE from disabling lock debugging
lockdep: Print lock name in lockdep_init_error()
init/main.c: Execute lockdep_init() as early as possible
lockdep, kmemcheck: Annotate ->lock in lockdep_init_map()
lockdep, rtmutex, bug: Show taint flags on error
lockdep, bug: Exclude TAINT_FIRMWARE_WORKAROUND from disabling lockdep
lockdep: Always try to set ->class_cache in register_lock_class() lockdep_init_map()
Diffstat (limited to 'kernel/panic.c')
| -rw-r--r-- | kernel/panic.c | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/kernel/panic.c b/kernel/panic.c index b26593604214..3458469eb7c3 100644 --- a/kernel/panic.c +++ b/kernel/panic.c @@ -237,11 +237,20 @@ void add_taint(unsigned flag) * Can't trust the integrity of the kernel anymore. * We don't call directly debug_locks_off() because the issue * is not necessarily serious enough to set oops_in_progress to 1 - * Also we want to keep up lockdep for staging development and - * post-warning case. + * Also we want to keep up lockdep for staging/out-of-tree + * development and post-warning case. */ - if (flag != TAINT_CRAP && flag != TAINT_WARN && __debug_locks_off()) - printk(KERN_WARNING "Disabling lock debugging due to kernel taint\n"); + switch (flag) { + case TAINT_CRAP: + case TAINT_OOT_MODULE: + case TAINT_WARN: + case TAINT_FIRMWARE_WORKAROUND: + break; + + default: + if (__debug_locks_off()) + printk(KERN_WARNING "Disabling lock debugging due to kernel taint\n"); + } set_bit(flag, &tainted_mask); } |
