forked from Minki/linux
5bc329503e
When we are about to kexec a crash kernel and right then and there a broadcasted MCE fires while we're still in the first kernel and while the other CPUs remain in a holding pattern, the #MC handler of the first kernel will timeout and then panic due to never completing MCE synchronization. Handle this in a similar way as to when the CPUs are offlined when that broadcasted MCE happens. [ Boris: rewrote commit message and comments. ] Suggested-by: Borislav Petkov <bp@alien8.de> Signed-off-by: Xunlei Pang <xlpang@redhat.com> Signed-off-by: Borislav Petkov <bp@suse.de> Acked-by: Tony Luck <tony.luck@intel.com> Cc: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Cc: kexec@lists.infradead.org Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/1487857012-9059-1-git-send-email-xlpang@redhat.com Link: http://lkml.kernel.org/r/20170313095019.19351-1-bp@alien8.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
32 lines
811 B
C
32 lines
811 B
C
#ifndef _ASM_X86_REBOOT_H
|
|
#define _ASM_X86_REBOOT_H
|
|
|
|
#include <linux/kdebug.h>
|
|
|
|
struct pt_regs;
|
|
|
|
struct machine_ops {
|
|
void (*restart)(char *cmd);
|
|
void (*halt)(void);
|
|
void (*power_off)(void);
|
|
void (*shutdown)(void);
|
|
void (*crash_shutdown)(struct pt_regs *);
|
|
void (*emergency_restart)(void);
|
|
};
|
|
|
|
extern struct machine_ops machine_ops;
|
|
extern int crashing_cpu;
|
|
|
|
void native_machine_crash_shutdown(struct pt_regs *regs);
|
|
void native_machine_shutdown(void);
|
|
void __noreturn machine_real_restart(unsigned int type);
|
|
/* These must match dispatch in arch/x86/realmore/rm/reboot.S */
|
|
#define MRR_BIOS 0
|
|
#define MRR_APM 1
|
|
|
|
typedef void (*nmi_shootdown_cb)(int, struct pt_regs*);
|
|
void nmi_shootdown_cpus(nmi_shootdown_cb callback);
|
|
void run_crash_ipi_callback(struct pt_regs *regs);
|
|
|
|
#endif /* _ASM_X86_REBOOT_H */
|