mirror of https://github.com/acidanthera/audk.git
UefiCpuPkg/CpuCommonFeaturesLib: Add CPUID MCA support check
Add CPUID check to see if the CPU supports the Machine Check Architecture before accessing the Machine Check Architecture related MSRs. Cc: Michael Kinney <michael.d.kinney@intel.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
This commit is contained in:
parent
ef5e0db22c
commit
ac40197558
|
@ -41,6 +41,10 @@ LmceSupport (
|
|||
{
|
||||
MSR_IA32_MCG_CAP_REGISTER McgCap;
|
||||
|
||||
if (!McaSupport (ProcessorNumber, CpuInfo, ConfigData)) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
McgCap.Uint64 = AsmReadMsr64 (MSR_IA32_MCG_CAP);
|
||||
if (ProcessorNumber == 0) {
|
||||
DEBUG ((EFI_D_INFO, "LMCE eanble = %x\n", (BOOLEAN) (McgCap.Bits.MCG_LMCE_P != 0)));
|
||||
|
|
Loading…
Reference in New Issue