]> git.proxmox.com Git - mirror_edk2.git/commitdiff
ArmVirtPkg/PrePi: base GCD memory space size on CPU's PA range
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Mon, 26 Nov 2018 21:35:02 +0000 (22:35 +0100)
committerArd Biesheuvel <ard.biesheuvel@linaro.org>
Thu, 29 Nov 2018 17:57:20 +0000 (18:57 +0100)
Derive the size of the GCD memory space map directly from the CPU's
information registers rather than from the PcdPrePiCpuMemorySize PCD,
which will be removed.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Acked-by: Laszlo Ersek <lersek@redhat.com>
ArmVirtPkg/PrePi/ArmVirtPrePiUniCoreRelocatable.inf
ArmVirtPkg/PrePi/PrePi.c

index 1587bd92f20681f5738db297f3620b441d16618b..034ddb41cb486235cbb8a823ad53109f5f172335 100755 (executable)
@@ -85,7 +85,6 @@
 \r
   gArmPlatformTokenSpaceGuid.PcdCoreCount\r
 \r
 \r
   gArmPlatformTokenSpaceGuid.PcdCoreCount\r
 \r
-  gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize\r
   gEmbeddedTokenSpaceGuid.PcdPrePiCpuIoSize\r
 \r
   gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIReclaimMemory\r
   gEmbeddedTokenSpaceGuid.PcdPrePiCpuIoSize\r
 \r
   gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIReclaimMemory\r
index f6abe2f2016bd654726f36d0b4a1ae9c22b89f5e..61de6cfd4ae676ec95b273c85b65b151679d6ae4 100755 (executable)
@@ -80,7 +80,7 @@ PrePiMain (
   BuildStackHob (StacksBase, StacksSize);\r
 \r
   //TODO: Call CpuPei as a library\r
   BuildStackHob (StacksBase, StacksSize);\r
 \r
   //TODO: Call CpuPei as a library\r
-  BuildCpuHob (PcdGet8 (PcdPrePiCpuMemorySize), PcdGet8 (PcdPrePiCpuIoSize));\r
+  BuildCpuHob (ArmGetPhysicalAddressBits (), PcdGet8 (PcdPrePiCpuIoSize));\r
 \r
   // Set the Boot Mode\r
   SetBootMode (BOOT_WITH_FULL_CONFIGURATION);\r
 \r
   // Set the Boot Mode\r
   SetBootMode (BOOT_WITH_FULL_CONFIGURATION);\r