Skip to contentSkip to conversation

x86: IO-APIC - use NMI_NONE instead of numeric constant

PATCH Applied Cyrill Gorcunov 2 participants 2 messages May 29, 2008 – Jun 2, 2008 x86

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86: IO-APIC - use NMI_NONE instead of numeric constant

---

Not sure but maybe it is better to use NMI_DISABLED, will take a look. But for now this patch is not change anything in logic so it will not hurt/broke the kernel. For most cases nmi_watchdog assignment is by one of NMI_* macro so I think there it make sense too.

arch/x86/kernel/io_apic_32.c +1 -1
Index: linux-2.6.git/arch/x86/kernel/io_apic_32.c
====================================================================
@@ -2217,7 +2217,7 @@ static inline void __init check_timer(vo
 
 	if (nmi_watchdog == NMI_IO_APIC) {
 		printk(KERN_WARNING "timer doesn't work through the IO-APIC - disabling NMI Watchdog!\n");
-		nmi_watchdog = 0;
+		nmi_watchdog = NMI_NONE;
 	}
 
 	printk(KERN_INFO "...trying to set up timer as Virtual Wire IRQ...");
arch/x86/kernel/io_apic_64.c +1 -1
Index: linux-2.6.git/arch/x86/kernel/io_apic_64.c
====================================================================
@@ -1735,7 +1735,7 @@ static inline void __init check_timer(vo
 
 	if (nmi_watchdog == NMI_IO_APIC) {
 		printk(KERN_WARNING "timer doesn't work through the IO-APIC - disabling NMI Watchdog!\n");
-		nmi_watchdog = 0;
+		nmi_watchdog = NMI_NONE;
 	}
 
 	apic_printk(APIC_VERBOSE, KERN_INFO "...trying to set up timer as Virtual Wire IRQ...");
Applied
#1 lore raw
Quoted 4 lines · Cyrill Gorcunov

Not sure but maybe it is better to use NMI_DISABLED, will take a look. But for now this patch is not change anything in logic so it will not hurt/broke the kernel. For most cases nmi_watchdog assignment is by one of NMI_* macro so I think there it make sense too.

applied to -tip, thanks Cyrill.

Ingo