summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjyao1 <jyao1@6f19259b-4bc3-4df7-8a09-765794883524>2011-10-11 13:25:18 +0000
committerjyao1 <jyao1@6f19259b-4bc3-4df7-8a09-765794883524>2011-10-11 13:25:18 +0000
commit47f8d0f3c346b7e77ba84cfef88888d15959bfbc (patch)
tree41128af946789a5e34c99a8b70579e586dfa310d
parent30d636c8d97057a2b5b3d696757c868710a94d2c (diff)
downloadedk2-platforms-47f8d0f3c346b7e77ba84cfef88888d15959bfbc.tar.xz
Fix Smbios table checksum error, by zero IntermediateChecksum and EntryPointStructureChecksum before checksum calculation.
signed-off-by: jyao1 reviewed-by: elvinli git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12527 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.c b/MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.c
index 80ccb1995e..b39ea23a8f 100644
--- a/MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.c
+++ b/MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.c
@@ -994,6 +994,9 @@ SmbiosCreateTable (
//
// Fixup checksums in the Entry Point Structure
//
+ EntryPointStructure->IntermediateChecksum = 0;
+ EntryPointStructure->EntryPointStructureChecksum = 0;
+
EntryPointStructure->IntermediateChecksum =
CalculateCheckSum8 ((UINT8 *) EntryPointStructure + 0x10, EntryPointStructure->EntryPointLength - 0x10);
EntryPointStructure->EntryPointStructureChecksum =