diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-i386/apic.h | 12 | ||||
-rw-r--r-- | include/asm-i386/nmi.h | 28 | ||||
-rw-r--r-- | include/asm-x86_64/apic.h | 16 | ||||
-rw-r--r-- | include/asm-x86_64/nmi.h | 30 |
4 files changed, 45 insertions, 41 deletions
diff --git a/include/asm-i386/apic.h b/include/asm-i386/apic.h index 1d8362cb2c5d..2c1e371cebb6 100644 --- a/include/asm-i386/apic.h +++ b/include/asm-i386/apic.h | |||
@@ -111,24 +111,12 @@ extern void init_apic_mappings (void); | |||
111 | extern void smp_local_timer_interrupt (struct pt_regs * regs); | 111 | extern void smp_local_timer_interrupt (struct pt_regs * regs); |
112 | extern void setup_boot_APIC_clock (void); | 112 | extern void setup_boot_APIC_clock (void); |
113 | extern void setup_secondary_APIC_clock (void); | 113 | extern void setup_secondary_APIC_clock (void); |
114 | extern void setup_apic_nmi_watchdog (void); | ||
115 | extern int reserve_lapic_nmi(void); | ||
116 | extern void release_lapic_nmi(void); | ||
117 | extern void disable_timer_nmi_watchdog(void); | ||
118 | extern void enable_timer_nmi_watchdog(void); | ||
119 | extern void nmi_watchdog_tick (struct pt_regs * regs); | ||
120 | extern int APIC_init_uniprocessor (void); | 114 | extern int APIC_init_uniprocessor (void); |
121 | extern void disable_APIC_timer(void); | 115 | extern void disable_APIC_timer(void); |
122 | extern void enable_APIC_timer(void); | 116 | extern void enable_APIC_timer(void); |
123 | 117 | ||
124 | extern void enable_NMI_through_LVT0 (void * dummy); | 118 | extern void enable_NMI_through_LVT0 (void * dummy); |
125 | 119 | ||
126 | extern unsigned int nmi_watchdog; | ||
127 | #define NMI_NONE 0 | ||
128 | #define NMI_IO_APIC 1 | ||
129 | #define NMI_LOCAL_APIC 2 | ||
130 | #define NMI_INVALID 3 | ||
131 | |||
132 | extern int disable_timer_pin_1; | 120 | extern int disable_timer_pin_1; |
133 | 121 | ||
134 | void smp_send_timer_broadcast_ipi(struct pt_regs *regs); | 122 | void smp_send_timer_broadcast_ipi(struct pt_regs *regs); |
diff --git a/include/asm-i386/nmi.h b/include/asm-i386/nmi.h index 21f16638fc61..67d994799999 100644 --- a/include/asm-i386/nmi.h +++ b/include/asm-i386/nmi.h | |||
@@ -5,24 +5,38 @@ | |||
5 | #define ASM_NMI_H | 5 | #define ASM_NMI_H |
6 | 6 | ||
7 | #include <linux/pm.h> | 7 | #include <linux/pm.h> |
8 | 8 | ||
9 | struct pt_regs; | 9 | struct pt_regs; |
10 | 10 | ||
11 | typedef int (*nmi_callback_t)(struct pt_regs * regs, int cpu); | 11 | typedef int (*nmi_callback_t)(struct pt_regs * regs, int cpu); |
12 | 12 | ||
13 | /** | 13 | /** |
14 | * set_nmi_callback | 14 | * set_nmi_callback |
15 | * | 15 | * |
16 | * Set a handler for an NMI. Only one handler may be | 16 | * Set a handler for an NMI. Only one handler may be |
17 | * set. Return 1 if the NMI was handled. | 17 | * set. Return 1 if the NMI was handled. |
18 | */ | 18 | */ |
19 | void set_nmi_callback(nmi_callback_t callback); | 19 | void set_nmi_callback(nmi_callback_t callback); |
20 | 20 | ||
21 | /** | 21 | /** |
22 | * unset_nmi_callback | 22 | * unset_nmi_callback |
23 | * | 23 | * |
24 | * Remove the handler previously set. | 24 | * Remove the handler previously set. |
25 | */ | 25 | */ |
26 | void unset_nmi_callback(void); | 26 | void unset_nmi_callback(void); |
27 | 27 | ||
28 | extern void setup_apic_nmi_watchdog (void); | ||
29 | extern int reserve_lapic_nmi(void); | ||
30 | extern void release_lapic_nmi(void); | ||
31 | extern void disable_timer_nmi_watchdog(void); | ||
32 | extern void enable_timer_nmi_watchdog(void); | ||
33 | extern void nmi_watchdog_tick (struct pt_regs * regs); | ||
34 | |||
35 | extern unsigned int nmi_watchdog; | ||
36 | #define NMI_DEFAULT -1 | ||
37 | #define NMI_NONE 0 | ||
38 | #define NMI_IO_APIC 1 | ||
39 | #define NMI_LOCAL_APIC 2 | ||
40 | #define NMI_INVALID 3 | ||
41 | |||
28 | #endif /* ASM_NMI_H */ | 42 | #endif /* ASM_NMI_H */ |
diff --git a/include/asm-x86_64/apic.h b/include/asm-x86_64/apic.h index a731be2204d2..c9e6c2501a48 100644 --- a/include/asm-x86_64/apic.h +++ b/include/asm-x86_64/apic.h | |||
@@ -79,27 +79,11 @@ extern void init_apic_mappings (void); | |||
79 | extern void smp_local_timer_interrupt (struct pt_regs * regs); | 79 | extern void smp_local_timer_interrupt (struct pt_regs * regs); |
80 | extern void setup_boot_APIC_clock (void); | 80 | extern void setup_boot_APIC_clock (void); |
81 | extern void setup_secondary_APIC_clock (void); | 81 | extern void setup_secondary_APIC_clock (void); |
82 | extern void setup_apic_nmi_watchdog (void); | ||
83 | extern int reserve_lapic_nmi(void); | ||
84 | extern void release_lapic_nmi(void); | ||
85 | extern void disable_timer_nmi_watchdog(void); | ||
86 | extern void enable_timer_nmi_watchdog(void); | ||
87 | extern void nmi_watchdog_tick (struct pt_regs * regs, unsigned reason); | ||
88 | extern int APIC_init_uniprocessor (void); | 82 | extern int APIC_init_uniprocessor (void); |
89 | extern void disable_APIC_timer(void); | 83 | extern void disable_APIC_timer(void); |
90 | extern void enable_APIC_timer(void); | 84 | extern void enable_APIC_timer(void); |
91 | extern void clustered_apic_check(void); | 85 | extern void clustered_apic_check(void); |
92 | 86 | ||
93 | extern void nmi_watchdog_default(void); | ||
94 | extern int setup_nmi_watchdog(char *); | ||
95 | |||
96 | extern unsigned int nmi_watchdog; | ||
97 | #define NMI_DEFAULT -1 | ||
98 | #define NMI_NONE 0 | ||
99 | #define NMI_IO_APIC 1 | ||
100 | #define NMI_LOCAL_APIC 2 | ||
101 | #define NMI_INVALID 3 | ||
102 | |||
103 | extern int disable_timer_pin_1; | 87 | extern int disable_timer_pin_1; |
104 | 88 | ||
105 | extern void setup_threshold_lvt(unsigned long lvt_off); | 89 | extern void setup_threshold_lvt(unsigned long lvt_off); |
diff --git a/include/asm-x86_64/nmi.h b/include/asm-x86_64/nmi.h index d3abfc6a8fd5..efb45c894d76 100644 --- a/include/asm-x86_64/nmi.h +++ b/include/asm-x86_64/nmi.h | |||
@@ -5,26 +5,27 @@ | |||
5 | #define ASM_NMI_H | 5 | #define ASM_NMI_H |
6 | 6 | ||
7 | #include <linux/pm.h> | 7 | #include <linux/pm.h> |
8 | #include <asm/io.h> | ||
8 | 9 | ||
9 | struct pt_regs; | 10 | struct pt_regs; |
10 | 11 | ||
11 | typedef int (*nmi_callback_t)(struct pt_regs * regs, int cpu); | 12 | typedef int (*nmi_callback_t)(struct pt_regs * regs, int cpu); |
12 | 13 | ||
13 | /** | 14 | /** |
14 | * set_nmi_callback | 15 | * set_nmi_callback |
15 | * | 16 | * |
16 | * Set a handler for an NMI. Only one handler may be | 17 | * Set a handler for an NMI. Only one handler may be |
17 | * set. Return 1 if the NMI was handled. | 18 | * set. Return 1 if the NMI was handled. |
18 | */ | 19 | */ |
19 | void set_nmi_callback(nmi_callback_t callback); | 20 | void set_nmi_callback(nmi_callback_t callback); |
20 | 21 | ||
21 | /** | 22 | /** |
22 | * unset_nmi_callback | 23 | * unset_nmi_callback |
23 | * | 24 | * |
24 | * Remove the handler previously set. | 25 | * Remove the handler previously set. |
25 | */ | 26 | */ |
26 | void unset_nmi_callback(void); | 27 | void unset_nmi_callback(void); |
27 | 28 | ||
28 | #ifdef CONFIG_PM | 29 | #ifdef CONFIG_PM |
29 | 30 | ||
30 | /** Replace the PM callback routine for NMI. */ | 31 | /** Replace the PM callback routine for NMI. */ |
@@ -56,4 +57,21 @@ extern int unknown_nmi_panic; | |||
56 | 57 | ||
57 | extern int check_nmi_watchdog(void); | 58 | extern int check_nmi_watchdog(void); |
58 | 59 | ||
60 | extern void setup_apic_nmi_watchdog (void); | ||
61 | extern int reserve_lapic_nmi(void); | ||
62 | extern void release_lapic_nmi(void); | ||
63 | extern void disable_timer_nmi_watchdog(void); | ||
64 | extern void enable_timer_nmi_watchdog(void); | ||
65 | extern void nmi_watchdog_tick (struct pt_regs * regs, unsigned reason); | ||
66 | |||
67 | extern void nmi_watchdog_default(void); | ||
68 | extern int setup_nmi_watchdog(char *); | ||
69 | |||
70 | extern unsigned int nmi_watchdog; | ||
71 | #define NMI_DEFAULT -1 | ||
72 | #define NMI_NONE 0 | ||
73 | #define NMI_IO_APIC 1 | ||
74 | #define NMI_LOCAL_APIC 2 | ||
75 | #define NMI_INVALID 3 | ||
76 | |||
59 | #endif /* ASM_NMI_H */ | 77 | #endif /* ASM_NMI_H */ |