diff options
author | Eric Dong <eric.dong@intel.com> | 2017-08-04 08:46:41 +0800 |
---|---|---|
committer | Eric Dong <eric.dong@intel.com> | 2017-08-04 08:49:05 +0800 |
commit | 3d6275c1137c9633ce24e31522b71105367bd6a0 (patch) | |
tree | deb9e4efdf735fa78145963abfec57689e862825 /UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c | |
parent | ac36ef87d4743cb4f13a148b74ba78f511eefa15 (diff) | |
download | edk2-3d6275c1137c9633ce24e31522b71105367bd6a0.tar.gz edk2-3d6275c1137c9633ce24e31522b71105367bd6a0.tar.bz2 edk2-3d6275c1137c9633ce24e31522b71105367bd6a0.zip |
UefiCpuPkg CpuCommonFeaturesLib: Enable LMCE feature.
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
Diffstat (limited to 'UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c')
-rw-r--r-- | UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c index b88b7d1e6d..4c78209a18 100644 --- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c +++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/CpuCommonFeaturesLib.c @@ -217,6 +217,18 @@ CpuCommonFeaturesLibConstructor ( );
ASSERT_EFI_ERROR (Status);
}
+ if (IsCpuFeatureSupported (CPU_FEATURE_LMCE)) {
+ Status = RegisterCpuFeature (
+ "LMCE",
+ NULL,
+ LmceSupport,
+ LmceInitialize,
+ CPU_FEATURE_LMCE,
+ CPU_FEATURE_LOCK_FEATURE_CONTROL_REGISTER | CPU_FEATURE_BEFORE,
+ CPU_FEATURE_END
+ );
+ ASSERT_EFI_ERROR (Status);
+ }
return RETURN_SUCCESS;
}
|