From: lgao4 Date: Tue, 22 Aug 2006 06:53:46 +0000 (+0000) Subject: Fix one bug in PeiMain to make it output correct ImageStartAddress. And in DxeIplX64P... X-Git-Tag: edk2-stable201903~24525 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=a61513d6f94b0fb4d5498609cbaef60c324858ba Fix one bug in PeiMain to make it output correct ImageStartAddress. And in DxeIplX64Peim/DxeLoadX64.c, install EndOfPeiSignalPpi can delay only if it enters into dxecore. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1348 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/EdkModulePkg/Core/DxeIplPeim/DxeLoad.c b/EdkModulePkg/Core/DxeIplPeim/DxeLoad.c index c53a7316c9..5ec81b2534 100644 --- a/EdkModulePkg/Core/DxeIplPeim/DxeLoad.c +++ b/EdkModulePkg/Core/DxeIplPeim/DxeLoad.c @@ -371,7 +371,6 @@ Returns: // Transfer control to the DXE Core // The handoff state is simply a pointer to the HOB list // -// PERF_END (PeiServices, L"DxeIpl", NULL, 0); Status = PeiServicesInstallPpi (&mPpiSignal); diff --git a/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c b/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c index 4211dd3075..023924c6c8 100644 --- a/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c +++ b/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c @@ -26,15 +26,6 @@ Abstract: BOOLEAN gInMemory = FALSE; -// -// GUID for EM64T -// -#define EFI_PPI_NEEDED_BY_DXE \ - { \ - 0x4d37da42, 0x3a0c, 0x4eda, 0xb9, 0xeb, 0xbc, 0x0e, 0x1d, 0xb4, 0x71, 0x3b \ - } -EFI_GUID mPpiNeededByDxeGuid = EFI_PPI_NEEDED_BY_DXE; - // // Module Globals used in the DXE to PEI handoff // These must be module globals, so the stack can be switched @@ -256,12 +247,8 @@ Returns: // // Install the PEI Protocols that are shared between PEI and DXE // -#ifdef EFI_NT_EMULATOR - PeiEfiPeiPeCoffLoader = (EFI_PEI_PE_COFF_LOADER_PROTOCOL *)GetPeCoffLoaderProtocol (); - ASSERT (PeiEfiPeiPeCoffLoader != NULL); -#else PeiEfiPeiPeCoffLoader = (EFI_PEI_PE_COFF_LOADER_PROTOCOL *)GetPeCoffLoaderX64Protocol (); -#endif + ASSERT (PeiEfiPeiPeCoffLoader != NULL); // // Allocate 128KB for the Stack @@ -309,15 +296,6 @@ Returns: ); ASSERT_EFI_ERROR (Status); - // - // Transfer control to the DXE Core - // The handoff state is simply a pointer to the HOB list - // - // PEI_PERF_END (PeiServices, L"DxeIpl", NULL, 0); - - Status = PeiServicesInstallPpi (&mPpiSignal); - ASSERT_EFI_ERROR (Status); - // // Load the GDT of Go64. Since the GDT of 32-bit Tiano locates in the BS_DATA \ // memory, it may be corrupted when copying FV to high-end memory @@ -342,6 +320,14 @@ Returns: ); ASSERT_EFI_ERROR (Status); + // + // Transfer control to the DXE Core + // The handoff state is simply a pointer to the HOB list + // + + Status = PeiServicesInstallPpi (&mPpiSignal); + ASSERT_EFI_ERROR (Status); + // // // Add HOB for the DXE Core diff --git a/EdkModulePkg/Core/Pei/Image/Image.c b/EdkModulePkg/Core/Pei/Image/Image.c index 32f0fe6523..c5c68c1d92 100644 --- a/EdkModulePkg/Core/Pei/Image/Image.c +++ b/EdkModulePkg/Core/Pei/Image/Image.c @@ -131,7 +131,7 @@ Returns: // // Print debug message: Loading PEIM at 0x12345678 EntryPoint=0x12345688 Driver.efi // - DEBUG ((EFI_D_INFO | EFI_D_LOAD, "Loading PEIM at 0x%08x EntryPoint=0x%08x ", Pe32Data, *EntryPoint)); + DEBUG ((EFI_D_INFO | EFI_D_LOAD, "Loading PEIM at 0x%08x EntryPoint=0x%08x ", (UINTN) ImageAddress, *EntryPoint)); DEBUG_CODE_BEGIN (); EFI_IMAGE_DATA_DIRECTORY *DirectoryEntry; EFI_IMAGE_DEBUG_DIRECTORY_ENTRY *DebugEntry;