forked from Qortal/Brooklyn
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
411 B
23 lines
411 B
// SPDX-License-Identifier: GPL-2.0-or-later |
|
/* |
|
*/ |
|
|
|
#include <linux/kernel.h> |
|
#include <linux/printk.h> |
|
#include <linux/ptrace.h> |
|
|
|
#include <asm/reg.h> |
|
|
|
int machine_check_4xx(struct pt_regs *regs) |
|
{ |
|
unsigned long reason = regs->esr; |
|
|
|
if (reason & ESR_IMCP) { |
|
printk("Instruction"); |
|
mtspr(SPRN_ESR, reason & ~ESR_IMCP); |
|
} else |
|
printk("Data"); |
|
printk(" machine check in kernel mode.\n"); |
|
|
|
return 0; |
|
}
|
|
|