aboutsummaryrefslogtreecommitdiffstats
path: root/arch/i386/kernel/nmi.c
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@novell.com>2006-12-06 20:14:09 -0500
committerAndi Kleen <andi@basil.nowhere.org>2006-12-06 20:14:09 -0500
commitc6ea396de6836bdeb2d2433368130642bf0f6e15 (patch)
tree1a2b243da4769f5a8b5f017180bacda2cd987ffb /arch/i386/kernel/nmi.c
parentb0bfece40b1988aa8e3d910938691dce7859d82d (diff)
[PATCH] i386: Don't touch per cpu memory of offline CPUs in touch_nmi_watchdog
Just like on x86-64, don't touch foreign CPUs' memory if the watchdog isn't enabled at all. Signed-off-by: Jan Beulich <jbeulich@novell.com> Signed-off-by: Andi Kleen <ak@suse.de>
Diffstat (limited to 'arch/i386/kernel/nmi.c')
-rw-r--r--arch/i386/kernel/nmi.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/arch/i386/kernel/nmi.c b/arch/i386/kernel/nmi.c
index 171194ccb7bc..f5bc7e1be801 100644
--- a/arch/i386/kernel/nmi.c
+++ b/arch/i386/kernel/nmi.c
@@ -870,14 +870,16 @@ static unsigned int
870 870
871void touch_nmi_watchdog (void) 871void touch_nmi_watchdog (void)
872{ 872{
873 int i; 873 if (nmi_watchdog > 0) {
874 unsigned cpu;
874 875
875 /* 876 /*
876 * Just reset the alert counters, (other CPUs might be 877 * Just reset the alert counters, (other CPUs might be
877 * spinning on locks we hold): 878 * spinning on locks we hold):
878 */ 879 */
879 for_each_possible_cpu(i) 880 for_each_present_cpu (cpu)
880 alert_counter[i] = 0; 881 alert_counter[cpu] = 0;
882 }
881 883
882 /* 884 /*
883 * Tickle the softlockup detector too: 885 * Tickle the softlockup detector too: