X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=EdkModulePkg%2FCore%2FPei%2FImage%2FImage.c;h=5edc8479eb04ca4aadd31c43ca684952f07a8a88;hp=8fd71976366866da68bab0ca0490f6313dc326cc;hb=2d10530b2900b58ad5a39d7fec219e9a63df0d48;hpb=84a99d48f4d59e0cf59b6d55328c35225c00246d diff --git a/EdkModulePkg/Core/Pei/Image/Image.c b/EdkModulePkg/Core/Pei/Image/Image.c index 8fd7197636..5edc8479eb 100644 --- a/EdkModulePkg/Core/Pei/Image/Image.c +++ b/EdkModulePkg/Core/Pei/Image/Image.c @@ -50,10 +50,6 @@ Returns: EFI_STATUS Status; VOID *Pe32Data; EFI_PEI_FV_FILE_LOADER_PPI *FvLoadFilePpi; -//#ifdef EFI_NT_EMULATOR -// EFI_PEI_PPI_DESCRIPTOR *PpiDescriptor; -// NT_PEI_LOAD_FILE_PPI *PeiNtService; -//#endif EFI_PHYSICAL_ADDRESS ImageAddress; UINT64 ImageSize; EFI_PHYSICAL_ADDRESS ImageEntryPoint; @@ -107,12 +103,10 @@ Returns: } // - // Retrieve the entry point from the PE/COFF image header + // Got the entry point from ImageEntryPoint // - Status = PeCoffLoaderGetEntryPoint ((VOID *)(UINTN)ImageAddress, EntryPoint); - if (EFI_ERROR (Status)) { - return EFI_NOT_FOUND; - } + *EntryPoint = (VOID *) ((UINTN) ImageEntryPoint); + return EFI_SUCCESS; } else { // // Retrieve the entry point from the TE image header