diff options
Diffstat (limited to 'MdeModulePkg')
-rw-r--r-- | MdeModulePkg/Universal/Network/IScsiDxe/IScsiIbft.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiIbft.c b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiIbft.c index 60a11b2e0d..6d2b184aad 100644 --- a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiIbft.c +++ b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiIbft.c @@ -448,6 +448,7 @@ IScsiPublishIbft ( UINTN HandleCount;
EFI_HANDLE *HandleBuffer;
UINT8 *Heap;
+ UINT8 Checksum;
Status = gBS->LocateProtocol (&gEfiAcpiTableProtocolGuid, NULL, (VOID **)&AcpiTableProtocol);
if (EFI_ERROR (Status)) {
@@ -481,7 +482,7 @@ IScsiPublishIbft ( //
// Allocate 4k bytes to hold the ACPI table.
//
- Table = AllocatePool (IBFT_MAX_SIZE);
+ Table = AllocateZeroPool (IBFT_MAX_SIZE);
if (Table == NULL) {
return ;
}
@@ -496,6 +497,9 @@ IScsiPublishIbft ( IScsiFillInitiatorSection (Table, &Heap, HandleBuffer[0]);
IScsiFillNICAndTargetSections (Table, &Heap, HandleCount, HandleBuffer);
+ Checksum = CalculateCheckSum8((UINT8 *)Table, Table->Length);
+ Table->Checksum = Checksum;
+
FreePool (HandleBuffer);
//
|