1. PEI core needs to check image machine type
2. In BDS, Legacy free may make BdsLibConnectAllDefaultConsoles fail. 3. Pci22.h, we need to add more definition in that 4. EBC: EBC Exception Subclass should add EFI_SUBCLASS_SPECIFIC 5. PciEnumeratorSupport Null Pointer Error git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2340 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
/*++
|
||||
|
||||
Copyright (c) 2006, Intel Corporation
|
||||
Copyright (c) 2006 - 2007, Intel Corporation
|
||||
All rights reserved. This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions of the BSD License
|
||||
which accompanies this distribution. The full text of the license may be found at
|
||||
@ -56,6 +56,7 @@ Returns:
|
||||
UINT64 ImageSize;
|
||||
EFI_PHYSICAL_ADDRESS ImageEntryPoint;
|
||||
EFI_TE_IMAGE_HEADER *TEImageHeader;
|
||||
UINT16 Machine;
|
||||
|
||||
*EntryPoint = NULL;
|
||||
TEImageHeader = NULL;
|
||||
@ -114,7 +115,7 @@ Returns:
|
||||
// Retrieve the entry point from the TE image header
|
||||
//
|
||||
ImageAddress = (EFI_PHYSICAL_ADDRESS) (UINTN) TEImageHeader;
|
||||
*EntryPoint = (VOID *)((UINTN) TEImageHeader + sizeof (EFI_TE_IMAGE_HEADER) +
|
||||
*EntryPoint = (VOID *)((UINTN) TEImageHeader + sizeof (EFI_TE_IMAGE_HEADER) +
|
||||
TEImageHeader->AddressOfEntryPoint - TEImageHeader->StrippedSize);
|
||||
}
|
||||
} else {
|
||||
@ -128,6 +129,17 @@ Returns:
|
||||
}
|
||||
}
|
||||
|
||||
if (((EFI_TE_IMAGE_HEADER *) (UINTN) ImageAddress)->Signature == EFI_TE_IMAGE_HEADER_SIGNATURE) {
|
||||
TEImageHeader = (EFI_TE_IMAGE_HEADER *) (UINTN) ImageAddress;
|
||||
Machine = TEImageHeader->Machine;
|
||||
} else {
|
||||
Machine = PeCoffLoaderGetMachineType (Pe32Data);
|
||||
}
|
||||
|
||||
if (!EFI_IMAGE_MACHINE_TYPE_SUPPORTED (Machine)) {
|
||||
return EFI_UNSUPPORTED;
|
||||
}
|
||||
|
||||
//
|
||||
// Print debug message: Loading PEIM at 0x12345678 EntryPoint=0x12345688 Driver.efi
|
||||
//
|
||||
|
Reference in New Issue
Block a user