diff options
author | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2009-03-05 09:18:28 +0000 |
---|---|---|
committer | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2009-03-05 09:18:28 +0000 |
commit | 27b2d249d57f9bde599af477d3b82acc3c62dfac (patch) | |
tree | 79ae97de8054ad0c2be70ec862ed60a2f89ab5b2 /MdePkg/Library/BasePeCoffLib | |
parent | 92650d219962b8acf81ed434e1db92739a50ba85 (diff) | |
download | edk2-27b2d249d57f9bde599af477d3b82acc3c62dfac.zip edk2-27b2d249d57f9bde599af477d3b82acc3c62dfac.tar.gz edk2-27b2d249d57f9bde599af477d3b82acc3c62dfac.tar.bz2 |
Remove PeRemove PeiPeCoffLoader.h and gPeiPeCoffLoaderGuid, and Add PeCoffExtraActionLib class and instances.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7811 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg/Library/BasePeCoffLib')
-rw-r--r-- | MdePkg/Library/BasePeCoffLib/BasePeCoff.c | 11 | ||||
-rw-r--r-- | MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf | 1 | ||||
-rw-r--r-- | MdePkg/Library/BasePeCoffLib/BasePeCoffLibInternals.h | 1 |
3 files changed, 13 insertions, 0 deletions
diff --git a/MdePkg/Library/BasePeCoffLib/BasePeCoff.c b/MdePkg/Library/BasePeCoffLib/BasePeCoff.c index 91df24e..9274f31 100644 --- a/MdePkg/Library/BasePeCoffLib/BasePeCoff.c +++ b/MdePkg/Library/BasePeCoffLib/BasePeCoff.c @@ -540,6 +540,9 @@ PeCoffLoaderRelocateImage ( // If there are no relocation entries, then we are done
//
if (ImageContext->RelocationsStripped) {
+ // Applies additional environment specific actions to relocate fixups
+ // to a PE/COFF image if needed
+ PeCoffLoaderRelocateImageExtraAction (ImageContext);
return RETURN_SUCCESS;
}
@@ -736,6 +739,11 @@ PeCoffLoaderRelocateImage ( ImageContext->EntryPoint -= (UINT64) ImageContext->ImageAddress;
ImageContext->EntryPoint += (UINT64) ImageContext->DestinationAddress;
}
+
+ // Applies additional environment specific actions to relocate fixups
+ // to a PE/COFF image if needed
+ PeCoffLoaderRelocateImageExtraAction (ImageContext);
+
return RETURN_SUCCESS;
}
@@ -1411,5 +1419,8 @@ PeCoffLoaderUnloadImage ( IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
)
{
+ // Applies additional environment specific actions to unload a
+ // PE/COFF image if needed
+ PeCoffLoaderUnloadImageExtraAction (ImageContext);
return RETURN_SUCCESS;
}
diff --git a/MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf b/MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf index 28e942c..534b78e 100644 --- a/MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf +++ b/MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf @@ -41,5 +41,6 @@ [LibraryClasses]
DebugLib
+ PeCoffExtraActionLib
BaseMemoryLib
diff --git a/MdePkg/Library/BasePeCoffLib/BasePeCoffLibInternals.h b/MdePkg/Library/BasePeCoffLib/BasePeCoffLibInternals.h index c8f95a1..864337b 100644 --- a/MdePkg/Library/BasePeCoffLib/BasePeCoffLibInternals.h +++ b/MdePkg/Library/BasePeCoffLib/BasePeCoffLibInternals.h @@ -19,6 +19,7 @@ #include <Library/PeCoffLib.h>
#include <Library/BaseMemoryLib.h>
#include <Library/DebugLib.h>
+#include <Library/PeCoffExtraActionLib.h>
#include <IndustryStandard/PeImage.h>
|