Now that we dropped all ArmPlatformGlobalVariableLib dependencies,
there is no longer a need to allocate and clear out the global
variable region in the PrePi init code. So remove it.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Acked-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18991
6f19259b-4bc3-4df7-8a09-
765794883524
cmp x0, #1\r
bne _PrepareArguments\r
\r
cmp x0, #1\r
bne _PrepareArguments\r
\r
-_ReserveGlobalVariable:\r
- LoadConstantToReg (FixedPcdGet32(PcdPeiGlobalVariableSize), x0)\r
- // InitializePrimaryStack($GlobalVariableSize, $Tmp1, $Tmp2)\r
- InitializePrimaryStack(x0, x1, x2)\r
-\r
_PrepareArguments:\r
mov x0, x10\r
mov x1, x11\r
mov x2, x12\r
_PrepareArguments:\r
mov x0, x10\r
mov x1, x11\r
mov x2, x12\r
\r
// Move sec startup address into a data register\r
// Ensure we're jumping to FV version of the code (not boot remapped alias)\r
\r
// Move sec startup address into a data register\r
// Ensure we're jumping to FV version of the code (not boot remapped alias)\r
// x0 = MpId\r
// x1 = UefiMemoryBase\r
// x2 = StacksBase\r
// x0 = MpId\r
// x1 = UefiMemoryBase\r
// x2 = StacksBase\r
- // x3 = GlobalVariableBase\r
blr x4\r
\r
_NeverReturn:\r
blr x4\r
\r
_NeverReturn:\r
gArmMpCoreInfoPpiGuid\r
\r
[Guids]\r
gArmMpCoreInfoPpiGuid\r
\r
[Guids]\r
- gArmGlobalVariableGuid\r
gArmMpCoreInfoGuid\r
\r
[FeaturePcd]\r
gArmMpCoreInfoGuid\r
\r
[FeaturePcd]\r
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize\r
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecondaryStackSize\r
\r
gArmPlatformTokenSpaceGuid.PcdCPUCorePrimaryStackSize\r
gArmPlatformTokenSpaceGuid.PcdCPUCoreSecondaryStackSize\r
\r
- gArmPlatformTokenSpaceGuid.PcdPeiGlobalVariableSize\r
-\r
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize\r
\r
gArmPlatformTokenSpaceGuid.PcdCoreCount\r
gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize\r
\r
gArmPlatformTokenSpaceGuid.PcdCoreCount\r
#include <Ppi/GuidedSectionExtraction.h>\r
#include <Ppi/ArmMpCoreInfo.h>\r
#include <Guid/LzmaDecompress.h>\r
#include <Ppi/GuidedSectionExtraction.h>\r
#include <Ppi/ArmMpCoreInfo.h>\r
#include <Guid/LzmaDecompress.h>\r
-#include <Guid/ArmGlobalVariableHob.h>\r
\r
#include "PrePi.h"\r
#include "LzmaDecompress.h"\r
\r
\r
#include "PrePi.h"\r
#include "LzmaDecompress.h"\r
\r
-// Not used when PrePi in run in XIP mode\r
-UINTN mGlobalVariableBase = 0;\r
-\r
EFI_STATUS\r
EFIAPI\r
ExtractGuidedSectionLibConstructor (\r
EFI_STATUS\r
EFIAPI\r
ExtractGuidedSectionLibConstructor (\r
-VOID\r
-EFIAPI\r
-BuildGlobalVariableHob (\r
- IN EFI_PHYSICAL_ADDRESS GlobalVariableBase,\r
- IN UINT32 GlobalVariableSize\r
- )\r
-{\r
- ARM_HOB_GLOBAL_VARIABLE *Hob;\r
-\r
- Hob = CreateHob (EFI_HOB_TYPE_GUID_EXTENSION, sizeof (ARM_HOB_GLOBAL_VARIABLE));\r
- ASSERT(Hob != NULL);\r
-\r
- CopyGuid (&(Hob->Header.Name), &gArmGlobalVariableGuid);\r
- Hob->GlobalVariableBase = GlobalVariableBase;\r
- Hob->GlobalVariableSize = GlobalVariableSize;\r
-}\r
-\r
EFI_STATUS\r
GetPlatformPpi (\r
IN EFI_GUID *PpiGuid,\r
EFI_STATUS\r
GetPlatformPpi (\r
IN EFI_GUID *PpiGuid,\r
PrePiMain (\r
IN UINTN UefiMemoryBase,\r
IN UINTN StacksBase,\r
PrePiMain (\r
IN UINTN UefiMemoryBase,\r
IN UINTN StacksBase,\r
- IN UINTN GlobalVariableBase,\r
IN UINT64 StartTimeStamp\r
)\r
{\r
IN UINT64 StartTimeStamp\r
)\r
{\r
StacksSize = PcdGet32 (PcdCPUCorePrimaryStackSize);\r
BuildStackHob (StacksBase, StacksSize);\r
\r
StacksSize = PcdGet32 (PcdCPUCorePrimaryStackSize);\r
BuildStackHob (StacksBase, StacksSize);\r
\r
- // Declare the Global Variable HOB\r
- BuildGlobalVariableHob (GlobalVariableBase, FixedPcdGet32 (PcdPeiGlobalVariableSize));\r
-\r
//TODO: Call CpuPei as a library\r
BuildCpuHob (PcdGet8 (PcdPrePiCpuMemorySize), PcdGet8 (PcdPrePiCpuIoSize));\r
\r
//TODO: Call CpuPei as a library\r
BuildCpuHob (PcdGet8 (PcdPrePiCpuMemorySize), PcdGet8 (PcdPrePiCpuIoSize));\r
\r
CEntryPoint (\r
IN UINTN MpId,\r
IN UINTN UefiMemoryBase,\r
CEntryPoint (\r
IN UINTN MpId,\r
IN UINTN UefiMemoryBase,\r
- IN UINTN StacksBase,\r
- IN UINTN GlobalVariableBase\r
)\r
{\r
UINT64 StartTimeStamp;\r
)\r
{\r
UINT64 StartTimeStamp;\r
// Enable Instruction Caches on all cores.\r
ArmEnableInstructionCache ();\r
\r
// Enable Instruction Caches on all cores.\r
ArmEnableInstructionCache ();\r
\r
- // Define the Global Variable region\r
- mGlobalVariableBase = GlobalVariableBase;\r
-\r
- PrePiMain (UefiMemoryBase, StacksBase, GlobalVariableBase, StartTimeStamp);\r
+ PrePiMain (UefiMemoryBase, StacksBase, StartTimeStamp);\r
\r
// DXE Core should always load and never return\r
ASSERT (FALSE);\r
\r
// DXE Core should always load and never return\r
ASSERT (FALSE);\r
PrePiMain (\r
IN UINTN UefiMemoryBase,\r
IN UINTN StacksBase,\r
PrePiMain (\r
IN UINTN UefiMemoryBase,\r
IN UINTN StacksBase,\r
- IN UINTN GlobalVariableBase,\r
IN UINT64 StartTimeStamp\r
);\r
\r
IN UINT64 StartTimeStamp\r
);\r
\r