diff --git a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c index ed956c447c..ae16f25c7c 100644 --- a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c +++ b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c @@ -559,7 +559,6 @@ PayloadEntry ( { EFI_STATUS Status; PHYSICAL_ADDRESS DxeCoreEntryPoint; - EFI_HOB_HANDOFF_INFO_TABLE *HandoffHobTable; UINTN MemBase; UINTN HobMemBase; UINTN HobMemTop; @@ -603,7 +602,7 @@ PayloadEntry ( IoWrite8 (LEGACY_8259_MASK_REGISTER_MASTER, 0xFF); IoWrite8 (LEGACY_8259_MASK_REGISTER_SLAVE, 0xFF); - Hob.HandoffInformationTable = HandoffHobTable; + Hob.HandoffInformationTable = (EFI_HOB_HANDOFF_INFO_TABLE *) GetFirstHob(EFI_HOB_TYPE_HANDOFF); HandOffToDxeCore (DxeCoreEntryPoint, Hob); // Should not get here diff --git a/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c b/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c index a67653eb11..7a00a56ab9 100644 --- a/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c +++ b/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c @@ -364,7 +364,6 @@ _ModuleEntryPoint ( { EFI_STATUS Status; PHYSICAL_ADDRESS DxeCoreEntryPoint; - EFI_HOB_HANDOFF_INFO_TABLE *HandoffHobTable; EFI_PEI_HOB_POINTERS Hob; EFI_FIRMWARE_VOLUME_HEADER *DxeFv; @@ -393,8 +392,7 @@ _ModuleEntryPoint ( IoWrite8 (LEGACY_8259_MASK_REGISTER_MASTER, 0xFF); IoWrite8 (LEGACY_8259_MASK_REGISTER_SLAVE, 0xFF); - HandoffHobTable = (EFI_HOB_HANDOFF_INFO_TABLE *) GetFirstHob(EFI_HOB_TYPE_HANDOFF); - Hob.HandoffInformationTable = HandoffHobTable; + Hob.HandoffInformationTable = (EFI_HOB_HANDOFF_INFO_TABLE *) GetFirstHob(EFI_HOB_TYPE_HANDOFF); HandOffToDxeCore (DxeCoreEntryPoint, Hob); // Should not get here