Re: [PATCH v5] x86: mce: kexec: switch MCE handler for kexec/kdump

Borislav Petkov
2015-03-06T08:30:09Z

On Thu, Mar 05, 2015 at 09:37:52AM +0000, Naoya Horiguchi wrote:
> print_mce() doesn't help?

No, it doesn't because it does a bunch of MCA-specific things too.

> Currently quirk_no_way_out() is set only for a specific CPU model, so even
> if we define another callback for kdump code, setting it to a real function
> need to be done in MCE internal function, __mcheck_cpu_apply_quirks() ?
>
> It seems that in this version I relied on reusing exisiting code too much.
> So I'll do only what I really need. Then, if the model specific behavior
> (what quirk_sandybridge_ifu() does) doesn't affect machine_check_under_kdump()'s
> behavior, simply stop copying this part is a right thing to do?

Just add this to mce.c in a pre-patch:

void mce_mc_callback(void *arg)
{
if (quirk_no_way_out)
quirk_no_way_out(i, m, regs);
}

I'm still not madly in love with it but I can't think of something
better. Maybe Tony would have a better idea...

--
Regards/Gruss,
Boris.

ECO tip #101: Trim your mails when you reply.
--