Produce LoadPeImage protocol only in framework compatibility mode.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9586 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
lgao4 2009-12-22 08:02:33 +00:00
parent ad86a50ae7
commit 6320fa42c9
2 changed files with 17 additions and 10 deletions

View File

@ -107,7 +107,7 @@
gEfiStatusCodeRuntimeProtocolGuid ## SOMETIMES_CONSUMES gEfiStatusCodeRuntimeProtocolGuid ## SOMETIMES_CONSUMES
gEfiCapsuleArchProtocolGuid ## CONSUMES gEfiCapsuleArchProtocolGuid ## CONSUMES
gEfiDecompressProtocolGuid ## CONSUMES gEfiDecompressProtocolGuid ## CONSUMES
gEfiLoadPeImageProtocolGuid ## PRODUCES gEfiLoadPeImageProtocolGuid ## SOMETIMES_PRODUCES (Produces when PcdFrameworkCompatibilitySupport is set)
gEfiSimpleFileSystemProtocolGuid ## CONSUMES gEfiSimpleFileSystemProtocolGuid ## CONSUMES
gEfiLoadFileProtocolGuid ## CONSUMES gEfiLoadFileProtocolGuid ## CONSUMES
gEfiLoadFile2ProtocolGuid ## CONSUMES gEfiLoadFile2ProtocolGuid ## CONSUMES
@ -140,3 +140,6 @@
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueBootServiceExit gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueBootServiceExit
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeDriverBegin gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeDriverBegin
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeDriverEnd gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeDriverEnd
[FeaturePcd.common]
gEfiMdeModulePkgTokenSpaceGuid.PcdFrameworkCompatibilitySupport ## CONSUMES

View File

@ -144,15 +144,19 @@ CoreInitializeImageServices (
gDxeCoreImageHandle = Image->Handle; gDxeCoreImageHandle = Image->Handle;
gDxeCoreLoadedImage = &Image->Info; gDxeCoreLoadedImage = &Image->Info;
// if (FeaturePcdGet (PcdFrameworkCompatibilitySupport)) {
// Export DXE Core PE Loader functionality //
// // Export DXE Core PE Loader functionality for backward compatibility.
return CoreInstallProtocolInterface ( //
&mLoadPe32PrivateData.Handle, Status = CoreInstallProtocolInterface (
&gEfiLoadPeImageProtocolGuid, &mLoadPe32PrivateData.Handle,
EFI_NATIVE_INTERFACE, &gEfiLoadPeImageProtocolGuid,
&mLoadPe32PrivateData.Pe32Image EFI_NATIVE_INTERFACE,
); &mLoadPe32PrivateData.Pe32Image
);
}
return Status;
} }
/** /**