// The package level header files this module uses\r
//\r
#include <PiPei.h>\r
+\r
//\r
// The protocols, PPI and GUID defintions for this module\r
//\r
#include <Library/MemoryAllocationLib.h>\r
#include <Library/ArmPlatformLib.h>\r
\r
-//\r
-// Module globals\r
-//\r
-\r
VOID\r
InitMmu (\r
VOID\r
)\r
{\r
- ARM_MEMORY_REGION_DESCRIPTOR *MemoryTable;\r
- VOID *TranslationTableBase;\r
- UINTN TranslationTableSize;\r
+ ARM_MEMORY_REGION_DESCRIPTOR *MemoryTable;\r
+ VOID *TranslationTableBase;\r
+ UINTN TranslationTableSize;\r
\r
- // Get Virtual Memory Map from the Platform Library\r
- ArmPlatformGetVirtualMemoryMap(&MemoryTable);\r
+ // Get Virtual Memory Map from the Platform Library\r
+ ArmPlatformGetVirtualMemoryMap(&MemoryTable);\r
\r
- //Note: Because we called PeiServicesInstallPeiMemory() before to call InitMmu() the MMU Page Table resides in\r
- // DRAM (even at the top of DRAM as it is the first permanent memory allocation)\r
- ArmConfigureMmu (MemoryTable, &TranslationTableBase, &TranslationTableSize);\r
+ //Note: Because we called PeiServicesInstallPeiMemory() before to call InitMmu() the MMU Page Table resides in\r
+ // DRAM (even at the top of DRAM as it is the first permanent memory allocation)\r
+ ArmConfigureMmu (MemoryTable, &TranslationTableBase, &TranslationTableSize);\r
}\r
\r
-// May want to put this into a library so you only need the PCD setings if you are using the feature?\r
+// May want to put this into a library so you only need the PCD settings if you are using the feature?\r
VOID\r
BuildMemoryTypeInformationHob (\r
VOID\r
Info[9].Type = EfiMaxMemoryType;\r
Info[9].NumberOfPages = 0;\r
\r
-\r
BuildGuidDataHob (&gEfiMemoryTypeInformationGuid, &Info, sizeof (Info));\r
}\r
-\r
/*++\r
\r
Routine Description:\r
InitMmu ();\r
\r
if (FeaturePcdGet (PcdPrePiProduceMemoryTypeInformationHob)) {\r
- // Optional feature that helps prevent EFI memory map fragmentation. \r
+ // Optional feature that helps prevent EFI memory map fragmentation.\r
BuildMemoryTypeInformationHob ();\r
}\r
\r