diff options
Diffstat (limited to 'include/asm-i386/nmi.h')
| -rw-r--r-- | include/asm-i386/nmi.h | 53 |
1 files changed, 35 insertions, 18 deletions
diff --git a/include/asm-i386/nmi.h b/include/asm-i386/nmi.h index 21f16638fc61..269d315719ca 100644 --- a/include/asm-i386/nmi.h +++ b/include/asm-i386/nmi.h | |||
| @@ -5,24 +5,41 @@ | |||
| 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 | /** |
| 10 | 10 | * do_nmi_callback | |
| 11 | typedef int (*nmi_callback_t)(struct pt_regs * regs, int cpu); | ||
| 12 | |||
| 13 | /** | ||
| 14 | * set_nmi_callback | ||
| 15 | * | ||
| 16 | * Set a handler for an NMI. Only one handler may be | ||
| 17 | * set. Return 1 if the NMI was handled. | ||
| 18 | */ | ||
| 19 | void set_nmi_callback(nmi_callback_t callback); | ||
| 20 | |||
| 21 | /** | ||
| 22 | * unset_nmi_callback | ||
| 23 | * | 11 | * |
| 24 | * Remove the handler previously set. | 12 | * Check to see if a callback exists and execute it. Return 1 |
| 13 | * if the handler exists and was handled successfully. | ||
| 25 | */ | 14 | */ |
| 26 | void unset_nmi_callback(void); | 15 | int do_nmi_callback(struct pt_regs *regs, int cpu); |
| 27 | 16 | ||
| 17 | extern int nmi_watchdog_enabled; | ||
| 18 | extern int avail_to_resrv_perfctr_nmi_bit(unsigned int); | ||
| 19 | extern int avail_to_resrv_perfctr_nmi(unsigned int); | ||
| 20 | extern int reserve_perfctr_nmi(unsigned int); | ||
| 21 | extern void release_perfctr_nmi(unsigned int); | ||
| 22 | extern int reserve_evntsel_nmi(unsigned int); | ||
| 23 | extern void release_evntsel_nmi(unsigned int); | ||
| 24 | |||
| 25 | extern void setup_apic_nmi_watchdog (void *); | ||
| 26 | extern void stop_apic_nmi_watchdog (void *); | ||
| 27 | extern void disable_timer_nmi_watchdog(void); | ||
| 28 | extern void enable_timer_nmi_watchdog(void); | ||
| 29 | extern int nmi_watchdog_tick (struct pt_regs * regs, unsigned reason); | ||
| 30 | |||
| 31 | extern atomic_t nmi_active; | ||
| 32 | extern unsigned int nmi_watchdog; | ||
| 33 | #define NMI_DEFAULT -1 | ||
| 34 | #define NMI_NONE 0 | ||
| 35 | #define NMI_IO_APIC 1 | ||
| 36 | #define NMI_LOCAL_APIC 2 | ||
| 37 | #define NMI_INVALID 3 | ||
| 38 | |||
| 39 | struct ctl_table; | ||
| 40 | struct file; | ||
| 41 | extern int proc_nmi_enabled(struct ctl_table *, int , struct file *, | ||
| 42 | void __user *, size_t *, loff_t *); | ||
| 43 | extern int unknown_nmi_panic; | ||
| 44 | |||
| 28 | #endif /* ASM_NMI_H */ | 45 | #endif /* ASM_NMI_H */ |
