Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 #ifndef _ASM_X86_REBOOT_H
0003 #define _ASM_X86_REBOOT_H
0004 
0005 #include <linux/kdebug.h>
0006 
0007 struct pt_regs;
0008 
0009 struct machine_ops {
0010     void (*restart)(char *cmd);
0011     void (*halt)(void);
0012     void (*power_off)(void);
0013     void (*shutdown)(void);
0014     void (*crash_shutdown)(struct pt_regs *);
0015     void (*emergency_restart)(void);
0016 };
0017 
0018 extern struct machine_ops machine_ops;
0019 extern int crashing_cpu;
0020 
0021 void native_machine_crash_shutdown(struct pt_regs *regs);
0022 void native_machine_shutdown(void);
0023 void __noreturn machine_real_restart(unsigned int type);
0024 /* These must match dispatch in arch/x86/realmore/rm/reboot.S */
0025 #define MRR_BIOS    0
0026 #define MRR_APM     1
0027 
0028 typedef void (*nmi_shootdown_cb)(int, struct pt_regs*);
0029 void nmi_panic_self_stop(struct pt_regs *regs);
0030 void nmi_shootdown_cpus(nmi_shootdown_cb callback);
0031 void run_crash_ipi_callback(struct pt_regs *regs);
0032 
0033 #endif /* _ASM_X86_REBOOT_H */