lkml.org 
[lkml]   [2006]   [May]   [29]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
DateMon, 29 May 2006 23:25:50 +0200
FromIngo Molnar <>
Subject[patch 33/61] lock validator: disable NMI watchdog if CONFIG_LOCKDEP
From: Ingo Molnar <mingo@elte.hu>

The NMI watchdog uses spinlocks (notifier chains, etc.),
so it's not lockdep-safe at the moment.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
---
 arch/x86_64/kernel/nmi.c |   12 ++++++++++++
 1 file changed, 12 insertions(+)
Index: linux/arch/x86_64/kernel/nmi.c
===================================================================
--- linux.orig/arch/x86_64/kernel/nmi.c
+++ linux/arch/x86_64/kernel/nmi.c
@@ -205,6 +205,18 @@ int __init check_nmi_watchdog (void)
 	int *counts;
 	int cpu;
 
+#ifdef CONFIG_LOCKDEP
+	/*
+	 * The NMI watchdog uses spinlocks (notifier chains, etc.),
+	 * so it's not lockdep-safe:
+	 */
+	nmi_watchdog = 0;
+	for_each_online_cpu(cpu)
+		per_cpu(nmi_watchdog_ctlblk.enabled, cpu) = 0;
+
+	printk("lockdep: disabled NMI watchdog.\n");
+	return 0;
+#endif
 	if ((nmi_watchdog == NMI_NONE) || (nmi_watchdog == NMI_DEFAULT))
 		return 0;
 
-
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/
\
 
 \ /
  Last update: 2006-05-29 23:39    [from the cache]
©2003-2008