lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 23 Apr 2013 12:34:03 -0400
From:	Dave Jones <davej@...hat.com>
To:	Peter Zijlstra <a.p.zijlstra@...llo.nl>
Cc:	Ingo Molnar <mingo@...e.hu>,
	Linux Kernel <linux-kernel@...r.kernel.org>
Subject: Print out additional debugging advice when we hit lockdep BUGs

We occasionally get reports of these BUGs being hit, and the stack trace
doesn't necessarily always tell us what we need to know about why we are
hitting those limits.

If users start attaching /proc/lock_stats to reports we may have more of
a clue what's going on.

Signed-off-by: Dave Jones <davej@...hat.com>

-- 
This could be factored out into a separate function as a follow-up patch
if this looks ok.

diff --git a/kernel/lockdep.c b/kernel/lockdep.c
index 7e755e7..e4c001f 100644
--- a/kernel/lockdep.c
+++ b/kernel/lockdep.c
@@ -411,6 +411,7 @@ static int save_trace(struct stack_trace *trace)
 
 		printk("BUG: MAX_STACK_TRACE_ENTRIES too low!\n");
 		printk("turning off the locking correctness validator.\n");
+		printk("Attach output of /proc/lock_stat to bug report\n");
 		dump_stack();
 
 		return 0;
@@ -778,6 +779,7 @@ register_lock_class(struct lockdep_map *lock, unsigned int subclass, int force)
 
 		printk("BUG: MAX_LOCKDEP_KEYS too low!\n");
 		printk("turning off the locking correctness validator.\n");
+		printk("Attach output of /proc/lock_stat to bug report\n");
 		dump_stack();
 		return NULL;
 	}
@@ -849,6 +851,7 @@ static struct lock_list *alloc_list_entry(void)
 
 		printk("BUG: MAX_LOCKDEP_ENTRIES too low!\n");
 		printk("turning off the locking correctness validator.\n");
+		printk("Attach output of /proc/lock_stat to bug report\n");
 		dump_stack();
 		return NULL;
 	}
@@ -2063,6 +2066,7 @@ cache_hit:
 
 		printk("BUG: MAX_LOCKDEP_CHAINS too low!\n");
 		printk("turning off the locking correctness validator.\n");
+		printk("Attach output of /proc/lock_stat to bug report\n");
 		dump_stack();
 		return 0;
 	}
@@ -3207,6 +3211,7 @@ static int __lock_acquire(struct lockdep_map *lock, unsigned int subclass,
 		printk("BUG: MAX_LOCK_DEPTH too low, depth: %i  max: %lu!\n",
 		       curr->lockdep_depth, MAX_LOCK_DEPTH);
 		printk("turning off the locking correctness validator.\n");
+		printk("Attach output of /proc/lock_stat to bug report\n");
 
 		lockdep_print_held_locks(current);
 		debug_show_all_locks();
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ