Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1309728

[PATCH 1/5] x86, mce: Fix order of AMD MCE init function call

From Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com>
Newsgroups linux.kernel
Subject [PATCH 1/5] x86, mce: Fix order of AMD MCE init function call
Date 2016-01-14 23:40 +0100
Message-ID <qQYIG-5f6-23@gated-at.bofh.it> (permalink)
References <qQY61-4Io-53@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


In mce_amd_feature_init() we take decisions based
on mce_flags being set or not. So the feature
detection using cpuid should naturally be ordered before
we call mce_amd_feature_init()

Fixing that here.

Signed-off-by: Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com>
---
 arch/x86/kernel/cpu/mcheck/mce.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/cpu/mcheck/mce.c b/arch/x86/kernel/cpu/mcheck/mce.c
index a006f4c..b718080 100644
--- a/arch/x86/kernel/cpu/mcheck/mce.c
+++ b/arch/x86/kernel/cpu/mcheck/mce.c
@@ -1617,10 +1617,10 @@ static void __mcheck_cpu_init_vendor(struct cpuinfo_x86 *c)
 	case X86_VENDOR_AMD: {
 		u32 ebx = cpuid_ebx(0x80000007);
 
-		mce_amd_feature_init(c);
 		mce_flags.overflow_recov = !!(ebx & BIT(0));
 		mce_flags.succor	 = !!(ebx & BIT(1));
 		mce_flags.smca		 = !!(ebx & BIT(3));
+		mce_amd_feature_init(c);
 
 		break;
 		}
-- 
2.7.0

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/5] Updates to AMD MCE driver per Scalable MCA spec Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> - 2016-01-14 23:40 +0100
  Re: [PATCH 3/5] x86/mcheck/AMD: Reduce number of blocks scanned per  bank Borislav Petkov <bp@alien8.de> - 2016-01-14 23:40 +0100
    Re: [PATCH 3/5] x86/mcheck/AMD: Reduce number of blocks scanned per  bank Borislav Petkov <bp@alien8.de> - 2016-01-15 00:00 +0100
      Re: [PATCH 3/5] x86/mcheck/AMD: Reduce number of blocks scanned per  bank Borislav Petkov <bp@alien8.de> - 2016-01-15 12:20 +0100
  [PATCH 1/5] x86, mce: Fix order of AMD MCE init function call Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> - 2016-01-14 23:40 +0100
  [PATCH 3/5] x86/mcheck/AMD: Reduce number of blocks scanned per bank Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> - 2016-01-14 23:40 +0100
  [PATCH 2/5] x86/mcheck/AMD: Do not perform shared bank check for future processors Aravind Gopalakrishnan <Aravind.Gopalakrishnan@amd.com> - 2016-01-14 23:40 +0100

csiph-web