nmi_watchdog: Use a boolean config flag for compiling
authorDon Zickus <dzickus@redhat.com>
Fri, 12 Feb 2010 22:19:18 +0000 (17:19 -0500)
committerIngo Molnar <mingo@elte.hu>
Sun, 14 Feb 2010 08:19:43 +0000 (09:19 +0100)
Determines if an arch has setup arch specific perf_events and
nmi_watchdog code.  This should restrict compiles to only those
arches ready.

Signed-off-by: Don Zickus <dzickus@redhat.com>
Cc: peterz@infradead.org
Cc: gorcunov@gmail.com
Cc: aris@redhat.com
LKML-Reference: <1266013161-31197-1-git-send-email-dzickus@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/Kconfig
init/Kconfig
lib/Kconfig.debug

index cbcbfdee3ee08695b8dbdbf873755dac7762d324..4f9685fa3a3a07cb45e452ea09a58c2afdcfe06e 100644 (file)
@@ -52,6 +52,7 @@ config X86
        select HAVE_KERNEL_LZO
        select HAVE_HW_BREAKPOINT
        select PERF_EVENTS
+       select PERF_EVENTS_NMI
        select ANON_INODES
        select HAVE_ARCH_KMEMCHECK
        select HAVE_USER_RETURN_NOTIFIER
index ada48441aff88725cb09bf5b71eaa004538911c9..7331a16dd82cb2a764563a0f4e9ba02101c5345a 100644 (file)
@@ -946,6 +946,11 @@ config PERF_USE_VMALLOC
        help
          See tools/perf/design.txt for details
 
+config PERF_EVENTS_NMI
+       bool
+       help
+         Arch has support for nmi_watchdog
+
 menu "Kernel Performance Events And Counters"
 
 config PERF_EVENTS
index acef88239e15487c04ccce9e1b5976874d752efa..01a4d85ee746e99386b953f051a7ffc23ebff174 100644 (file)
@@ -172,8 +172,7 @@ config DETECT_SOFTLOCKUP
 
 config NMI_WATCHDOG
        bool "Detect Hard Lockups with an NMI Watchdog"
-       depends on DEBUG_KERNEL && PERF_EVENTS
-       depends on X86
+       depends on DEBUG_KERNEL && PERF_EVENTS && PERF_EVENTS_NMI
        default y
        help
          Say Y here to enable the kernel to use the NMI as a watchdog