Merge commit 'v2.6.34-rc7' into perf/nmi
[firefly-linux-kernel-4.4.55.git] / kernel / sysctl.c
index 8686b0f5fc12fc85d19c31d934bbe34bd55d5af2..a38af430f0d8ac708609720070fd12ca52b432d3 100644 (file)
 #include <scsi/sg.h>
 #endif
 
+#ifdef CONFIG_NMI_WATCHDOG
+#include <linux/nmi.h>
+#endif
+
 
 #if defined(CONFIG_SYSCTL)
 
@@ -682,7 +686,16 @@ static struct ctl_table kern_table[] = {
                .mode           = 0444,
                .proc_handler   = proc_dointvec,
        },
-#if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86)
+#if defined(CONFIG_NMI_WATCHDOG)
+       {
+               .procname       = "nmi_watchdog",
+               .data           = &nmi_watchdog_enabled,
+               .maxlen         = sizeof (int),
+               .mode           = 0644,
+               .proc_handler   = proc_nmi_enabled,
+       },
+#endif
+#if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86) && !defined(CONFIG_NMI_WATCHDOG)
        {
                .procname       = "unknown_nmi_panic",
                .data           = &unknown_nmi_panic,