RE: [PATCH 1/2] x86, MCE: Do not taint when handling correctableerrors

From: Chumbalkar, Nagananda
Date: Fri Apr 15 2011 - 13:06:11 EST




>-----Original Message-----
>From: linux-edac-owner@xxxxxxxxxxxxxxx [mailto:linux-edac-
>owner@xxxxxxxxxxxxxxx] On Behalf Of Borislav Petkov
>Sent: Friday, April 15, 2011 3:46 AM
>To: H. Peter Anvin; Ingo Molnar; Thomas Gleixner
>Cc: Prarit Bhargava; Tony Luck; Russ Anderson; LKML; EDAC devel;
>Borislav Petkov
>Subject: [PATCH 1/2] x86, MCE: Do not taint when handling correctable
>errors
>
>From: Borislav Petkov <borislav.petkov@xxxxxxx>
>
>Correctable errors are considered something rather normal on modern
>hardware these days. Even more importantly, correctable errors mean
>exactly that - they've been corrected by the hardware - and there's no
>need to taint the kernel since execution hasn't been compromised so far.
>

Would it be okay to extend this reasoning and also remove the tainting
caused by TM1/TM2 thermal events:

diff --git a/arch/x86/kernel/cpu/mcheck/therm_throt.c
b/arch/x86/kernel/cpu/mcheck/therm_throt.c
index 6f8c5e9..9f3b5ae 100644
--- a/arch/x86/kernel/cpu/mcheck/therm_throt.c
+++ b/arch/x86/kernel/cpu/mcheck/therm_throt.c
@@ -188,7 +188,6 @@ static int therm_throt_process(bool new_event, int event,
int level)
level == CORE_LEVEL ? "Core" : "Package",
state->count);

- add_taint(TAINT_MACHINE_CHECK);
return 1;
}
if (old_event) {
@@ -393,7 +392,6 @@ static void unexpected_thermal_interrupt(void)
{
printk(KERN_ERR "CPU%d: Unexpected LVT thermal interrupt!\n",
smp_processor_id());
- add_taint(TAINT_MACHINE_CHECK);
}

static void (*smp_thermal_vector)(void) = unexpected_thermal_interrupt;


- naga -


>Suggested-by: Tony Luck <tony.luck@xxxxxxxxx>
>Signed-off-by: Borislav Petkov <borislav.petkov@xxxxxxx>
>---
> arch/x86/kernel/cpu/mcheck/mce.c | 1 -
> 1 files changed, 0 insertions(+), 1 deletions(-)
>
>diff --git a/arch/x86/kernel/cpu/mcheck/mce.c
>b/arch/x86/kernel/cpu/mcheck/mce.c
>index 3385ea2..68e2303 100644
>--- a/arch/x86/kernel/cpu/mcheck/mce.c
>+++ b/arch/x86/kernel/cpu/mcheck/mce.c
>@@ -590,7 +590,6 @@ void machine_check_poll(enum mcp_flags flags,
>mce_banks_t *b)
> if (!(flags & MCP_DONTLOG) && !mce_dont_log_ce) {
> mce_log(&m);
> atomic_notifier_call_chain(&x86_mce_decoder_chain, 0,
>&m);
>- add_taint(TAINT_MACHINE_CHECK);
> }
>
> /*
>--
>1.7.4.rc2
>
>--
>To unsubscribe from this list: send the line "unsubscribe linux-edac" in
>the body of a message to majordomo@xxxxxxxxxxxxxxx
>More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/