Fix Athlon MCA
PATCH 1/1 Fix Athlon MCA
Hi,
on boot I'm seeing a lot of messages like this:
MCE: The hardware reports a non fatal, correctable incident occurred on CPU 0. Bank 0: d47fa0000000bfee
This messages go away if I revert cset 1.1119.9.1. AFAIK you were trying to decrease the logging level. After reading IA32 Architecture Software Developers Manual, vol3 - chapter 14.5 "Machine-Check Initialization" I think that the right way to do it is this:
arch/i386/kernel/cpu/mcheck/k7.c renamed from arch/i386/kernel/cpu/mcheck/k7.c~ +3 -2
@@ -81,8 +81,9 @@wrmsr (MSR_IA32_MCG_CTL ,0xffffffff ,0xffffffff ); nr_mce_banks = l &0xff ; -for (i=1 ; i<nr_mce_banks; i++) { -wrmsr (MSR_IA32_MC0_CTL +4 *i,0xffffffff ,0xffffffff ); +for (i=0 ; i<nr_mce_banks; i++) { +if (i) +wrmsr (MSR_IA32_MC0_CTL +4 *i,0xffffffff ,0xffffffff );wrmsr (MSR_IA32_MC0_STATUS +4 *i,0x0 ,0x0 ); }
We really want to clean all MC*_STATUS. I'm currently running linux 2.6.0-t5
+ this patch and I don't see the MCE messages on boot anymore.
Luca
Signature · 6 lines
Reply-To: [email protected] Home: http://kronoz.cjb.net "L'abilita` politica e` l'abilita` di prevedere quello che accadra` domani, la prossima settimana, il prossimo mese e l'anno prossimo. E di essere cosi` abili, piu` tardi, da spiegare perche' non e` accaduto."
Quoted 2 lines · Kronos
We really want to clean all MC*_STATUS. I'm currently running linux 2.6.0-t5
+ this patch and I don't see the MCE messages on boot anymore.
Patch looks good to me.
Dave
Signature · 1 line
Dave Jones http://www.codemonkey.org.uk
Quoted 5 lines · Kronos
This messages go away if I revert cset 1.1119.9.1. AFAIK you were trying to decrease the logging level. After reading IA32 Architecture Software Developers Manual, vol3 - chapter 14.5 "Machine-Check Initialization" I think that the right way to do it is this:
Why not just handling the (different) 0-based case in front of the loop:
/* Clear status for MC index 0 separately, we don't touch CTL. */ wrmsr (MSR_IA32_MC0_STATUS, 0x0, 0x0);
and leave the loop 1-based.
Dave, up to you..
Linus
Quoted 5 lines · Linus Torvalds
Quoted 4 lines
This messages go away if I revert cset 1.1119.9.1. AFAIK you were trying to decrease the logging level. After reading IA32 Architecture Software Developers Manual, vol3 - chapter 14.5 "Machine-Check Initialization" I think that the right way to do it is this:
Quoted 8 lines
Why not just handling the (different) 0-based case in front of the loop:
/* Clear status for MC index 0 separately, we don't touch CTL. */ wrmsr (MSR_IA32_MC0_STATUS, 0x0, 0x0);and leave the loop 1-based.
Dave, up to you..
yeah, I prefer that way just for the added comment outside the loop. expanding it to mention "some athlons don't work with bank 0 enabled" would be a nice finishing touch.
Dave
Signature · 1 line
Dave Jones http://www.codemonkey.org.uk
Quoted 2 lines · Dave Jones
yeah, I prefer that way just for the added comment outside the loop. expanding it to mention "some athlons don't work with bank 0 enabled"
Would this MCE message be of the same flavour as the one this thread is about?
Message from syslogd@lexx at Mon Sep 22 21:38:01 2003 ...
lexx kernel: MCE: The hardware reports a non fatal, correctable incident occurred on CPU 0.
Message from syslogd@lexx at Mon Sep 22 21:38:01 2003 ... lexx kernel: Bank 2: 940040000000017a
I don't have my stick of RAM plugged into the first RAM slot but rather the 3rd of 4. I guess this correspends to bank 2 above. I've been ignoring them uptil now but is this a linux hassle or a h/w one?
Signature · 2 lines
And so the stripper looks down and asks 'Can you breathe?' - from a friend's bucks night
Quoted 3 lines · CaT
I don't have my stick of RAM plugged into the first RAM slot but rather the 3rd of 4. I guess this correspends to bank 2 above. I've been ignoring them uptil now but is this a linux hassle or a h/w one?
The bank is referring to an MCE bank rather than a memory slot. Each MCE bank checks different things.
Dave
Signature · 1 line
Dave Jones http://www.codemonkey.org.uk
Quoted 2 lines · Dave Jones
The bank is referring to an MCE bank rather than a memory slot. Each MCE bank checks different things.
ahhh. ok. Well... I found your parsemce.c source. got it compiled it. Ran:
./parsemce -b 2 -e 940040000000017a
and got:
Status: (940040000000017a) Error IP valid
Restart IP invalid.
What the snot does that mean? 8)
(if you can help it'd be appreciated :)
Signature · 2 lines
And so the stripper looks down and asks 'Can you breathe?' - from a friend's bucks night
Quoted 6 lines · CaT
Quoted 2 lines · Dave Jones
The bank is referring to an MCE bank rather than a memory slot. Each MCE bank checks different things.
ahhh. ok. Well... I found your
parsemce.csource. got it compiled it. Ran:
Quoted 8 lines
./parsemce -b 2 -e
940040000000017aand got:
Status: (
940040000000017a) Error IP valid
Restart IP invalid.What the snot does that mean? 8)
If this was from a kernel that didn't clear that bank on boot, it's bogus, and you can ignore it.
Dave
Signature · 1 line
Dave Jones http://www.codemonkey.org.uk
Quoted 9 lines · Dave Jones
Quoted 5 lines · CaT
On Mon, Sep 22, 2003 at 03:43:45PM +0100, Dave Jones wrote:
Status: (940040000000017a) Error IP valid
Restart IP invalid.What the snot does that mean? 8)
If this was from a kernel that didn't clear that bank on boot, it's bogus, and you can ignore it.
Ahhh. Phew. Thanks. I've been wondering. I take it this can show up on a long-running system too? (hopefully someone will find this bit of the thread useful because I saw 1 or 2 msgs in the past but I didn't quite understand the answers)
Signature · 2 lines
And so the stripper looks down and asks 'Can you breathe?' - from a friend's bucks night
Quoted 4 lines · CaT
Ahhh. Phew. Thanks. I've been wondering. I take it this can show up on a long-running system too? (hopefully someone will find this bit of the thread useful because I saw 1 or 2 msgs in the past but I didn't quite understand the answers)
Ones that turn up after a while should be something different. This bug was crap left in that register that gets reported, and then zero'd away. As we don't enable checking in that bank, once its zero it stays zero. Anything that triggers afterwards should be coming from a different bank.
Dave
Signature · 1 line
Dave Jones http://www.codemonkey.org.uk
I'm seeing this message too on all my athlons, also if it seems harmless. Will try this patch tomorrow.
bests
Luigi
Quoted 49 lines · Kronos
Date: Sun, 21 Sep 2003 16:39:34 +0200
From: Kronos <[email protected]>
To: [email protected]
Cc: [email protected]
Subject: [PATCH] Fix Athlon MCAHi,
on boot I'm seeing a lot of messages like this:MCE: The hardware reports a non fatal, correctable incident occurred on CPU 0. Bank 0:
d47fa0000000bfeeThis messages go away if I revert cset 1.1119.9.1. AFAIK you were trying to decrease the logging level. After reading IA32 Architecture Software Developers Manual, vol3 - chapter 14.5 "Machine-Check Initialization" I think that the right way to do it is this:
arch/i386/kernel/cpu/mcheck/k7.c renamed from arch/i386/kernel/cpu/mcheck/k7.c~ +3
-2@@ -81,8 +81,9 @@wrmsr (MSR_IA32_MCG_CTL ,0xffffffff ,0xffffffff ); nr_mce_banks = l &0xff ; -for (i=1 ; i<nr_mce_banks; i++) { -wrmsr (MSR_IA32_MC0_CTL +4 *i,0xffffffff ,0xffffffff ); +for (i=0 ; i<nr_mce_banks; i++) { +if (i) +wrmsr (MSR_IA32_MC0_CTL +4 *i,0xffffffff ,0xffffffff );wrmsr (MSR_IA32_MC0_STATUS +4 *i,0x0 ,0x0 ); }We really want to clean all MC*_STATUS. I'm currently running linux 2.6.0-t5
+ this patch and I don't see the MCE messages on boot anymore.Luca
--
Reply-To: [email protected]
Home: http://kronoz.cjb.net
"L'abilitapolitica el'abilita` di prevedere quello che
accadradomani, la prossima settimana, il prossimo mese e l'anno prossimo. E di essere cosiabili, piu` tardi,
da spiegare perche' non e` accaduto."
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/