mirror of https://github.com/acidanthera/audk.git
MdeModulePkg PeiCore: Make SetPeiServicesTablePointer() early in EntryPoint
Make SetPeiServicesTablePointer() earlier than ProcessLibraryConstructorList() so the constructor() function can get the correct pei service table pointer. https://bugzilla.tianocore.org/show_bug.cgi?id=238 Cc: Michael Kinney <michael.d.kinney@intel.com> Cc: Star Zeng <star.zeng@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com>
This commit is contained in:
parent
8ae1714047
commit
75fe0a78ae
|
@ -207,16 +207,16 @@ PeiCore (
|
||||||
OldCoreData->FileHandles = (EFI_PEI_FILE_HANDLE *) ((UINT8 *) OldCoreData->FileHandles - OldCoreData->HeapOffset);
|
OldCoreData->FileHandles = (EFI_PEI_FILE_HANDLE *) ((UINT8 *) OldCoreData->FileHandles - OldCoreData->HeapOffset);
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
|
||||||
// Initialize libraries that the PEI Core is linked against
|
|
||||||
//
|
|
||||||
ProcessLibraryConstructorList (NULL, (CONST EFI_PEI_SERVICES **)&OldCoreData->Ps);
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// Fixup for PeiService's address
|
// Fixup for PeiService's address
|
||||||
//
|
//
|
||||||
SetPeiServicesTablePointer ((CONST EFI_PEI_SERVICES **)&OldCoreData->Ps);
|
SetPeiServicesTablePointer ((CONST EFI_PEI_SERVICES **)&OldCoreData->Ps);
|
||||||
|
|
||||||
|
//
|
||||||
|
// Initialize libraries that the PEI Core is linked against
|
||||||
|
//
|
||||||
|
ProcessLibraryConstructorList (NULL, (CONST EFI_PEI_SERVICES **)&OldCoreData->Ps);
|
||||||
|
|
||||||
//
|
//
|
||||||
// Update HandOffHob for new installed permanent memory
|
// Update HandOffHob for new installed permanent memory
|
||||||
//
|
//
|
||||||
|
@ -301,16 +301,16 @@ PeiCore (
|
||||||
//
|
//
|
||||||
PrivateData.Ps = &PrivateData.ServiceTableShadow;
|
PrivateData.Ps = &PrivateData.ServiceTableShadow;
|
||||||
|
|
||||||
//
|
|
||||||
// Initialize libraries that the PEI Core is linked against
|
|
||||||
//
|
|
||||||
ProcessLibraryConstructorList (NULL, (CONST EFI_PEI_SERVICES **)&PrivateData.Ps);
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// Save PeiServicePointer so that it can be retrieved anywhere.
|
// Save PeiServicePointer so that it can be retrieved anywhere.
|
||||||
//
|
//
|
||||||
SetPeiServicesTablePointer ((CONST EFI_PEI_SERVICES **)&PrivateData.Ps);
|
SetPeiServicesTablePointer ((CONST EFI_PEI_SERVICES **)&PrivateData.Ps);
|
||||||
|
|
||||||
|
//
|
||||||
|
// Initialize libraries that the PEI Core is linked against
|
||||||
|
//
|
||||||
|
ProcessLibraryConstructorList (NULL, (CONST EFI_PEI_SERVICES **)&PrivateData.Ps);
|
||||||
|
|
||||||
//
|
//
|
||||||
// Initialize PEI Core Services
|
// Initialize PEI Core Services
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in New Issue