MdeModulePkg/Smbios: Done measure Smbios multiple times.

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2439

In current implementation, the SMBIOS table is measured multiple
time in every readytoboot event.

This causes Smbios Table record appears multiple time in the TCG event log
and confuses people.

This issue makes it hard to implement 800-155 reference measurement.

This patch closes the event to make sure Smbios is measured only once.

Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Hao A Wu <hao.a.wu@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
This commit is contained in:
Jiewen Yao 2019-12-31 09:02:52 +08:00 committed by mergify[bot]
parent 4fa25853cd
commit f273905161
1 changed files with 2 additions and 2 deletions

View File

@ -577,8 +577,8 @@ MeasureSmbiosTable (
TableAddress, // HashData
TableLength // HashDataLen
);
if (EFI_ERROR (Status)) {
return ;
if (!EFI_ERROR (Status)) {
gBS->CloseEvent (Event) ;
}
}