diff options
author | Nicholas Piggin <npiggin@gmail.com> | 2017-02-28 12:00:47 +1000 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2017-03-10 16:32:07 +1100 |
commit | c1bbf387d6191e6e18f3adc4db45b922822c2ba4 (patch) | |
tree | 701f4206a2c1b082dd31d7ce32ecb92643621de8 /arch/powerpc/kernel/mce.c | |
parent | 1363875bdb6317a2d0798284d7aaf320f0782f6d (diff) | |
download | lwn-c1bbf387d6191e6e18f3adc4db45b922822c2ba4.tar.gz lwn-c1bbf387d6191e6e18f3adc4db45b922822c2ba4.zip |
powerpc/64s: allow machine check handler to set severity and initiator
Currently severity and initiator are always set to MCE_SEV_ERROR_SYNC and
MCE_INITIATOR_CPU in the core mce code. Allow them to be set by the
machine specific mce handlers.
No functional change for existing handlers.
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/kernel/mce.c')
-rw-r--r-- | arch/powerpc/kernel/mce.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/powerpc/kernel/mce.c b/arch/powerpc/kernel/mce.c index c6923ff45131..949507277436 100644 --- a/arch/powerpc/kernel/mce.c +++ b/arch/powerpc/kernel/mce.c @@ -90,13 +90,14 @@ void save_mce_event(struct pt_regs *regs, long handled, mce->gpr3 = regs->gpr[3]; mce->in_use = 1; - mce->initiator = MCE_INITIATOR_CPU; /* Mark it recovered if we have handled it and MSR(RI=1). */ if (handled && (regs->msr & MSR_RI)) mce->disposition = MCE_DISPOSITION_RECOVERED; else mce->disposition = MCE_DISPOSITION_NOT_RECOVERED; - mce->severity = MCE_SEV_ERROR_SYNC; + + mce->initiator = mce_err->initiator; + mce->severity = mce_err->severity; /* * Populate the mce error_type and type-specific error_type. |