]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Core/Pei/Memory/MemoryServices.c
MdeModulePkg: Clean up source files
[mirror_edk2.git] / MdeModulePkg / Core / Pei / Memory / MemoryServices.c
index 516311d09189db05f7507aac18d49a906b5f1068..4dc62d2262dbcc76089ede584f6bfb043c9ec8e9 100644 (file)
@@ -1,14 +1,14 @@
 /** @file\r
   EFI PEI Core memory services\r
-  \r
-Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials                          \r
-are licensed and made available under the terms and conditions of the BSD License         \r
-which accompanies this distribution.  The full text of the license may be found at        \r
-http://opensource.org/licenses/bsd-license.php                                            \r
-                                                                                          \r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+\r
+Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>\r
+This program and the accompanying materials\r
+are licensed and made available under the terms and conditions of the BSD License\r
+which accompanies this distribution.  The full text of the license may be found at\r
+http://opensource.org/licenses/bsd-license.php\r
+\r
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
 **/\r
 \r
@@ -33,7 +33,7 @@ InitializeMemoryServices (
   IN PEI_CORE_INSTANCE           *OldCoreData\r
   )\r
 {\r
-  \r
+\r
   PrivateData->SwitchStackSignal    = FALSE;\r
 \r
   //\r
@@ -44,7 +44,7 @@ InitializeMemoryServices (
 \r
     PrivateData->PeiMemoryInstalled = FALSE;\r
     PrivateData->HobList.Raw        = SecCoreData->PeiTemporaryRamBase;\r
-    \r
+\r
     PeiCoreBuildHobHandoffInfoTable (\r
       BOOT_WITH_FULL_CONFIGURATION,\r
       (EFI_PHYSICAL_ADDRESS) (UINTN) SecCoreData->PeiTemporaryRamBase,\r
@@ -56,7 +56,7 @@ InitializeMemoryServices (
     //\r
     PrivateData->Ps = &(PrivateData->ServiceTableShadow);\r
   }\r
-  \r
+\r
   return;\r
 }\r
 \r
@@ -68,7 +68,7 @@ InitializeMemoryServices (
   This routine will hold discoveried memory information into PeiCore's private data,\r
   and set SwitchStackSignal flag. After PEIM who discovery memory is dispatched,\r
   PeiDispatcher will migrate temporary memory to permenement memory.\r
-  \r
+\r
   @param PeiServices        An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.\r
   @param MemoryBegin        Start of memory address.\r
   @param MemoryLength       Length of memory.\r
@@ -93,20 +93,20 @@ PeiInstallPeiMemory (
   // PEI_SERVICE.InstallPeiMemory should only be called one time during whole PEI phase.\r
   // If it is invoked more than one time, ASSERT information is given for developer debugging in debug tip and\r
   // simply return EFI_SUCESS in release tip to ignore it.\r
-  // \r
+  //\r
   if (PrivateData->PeiMemoryInstalled) {\r
     DEBUG ((EFI_D_ERROR, "ERROR: PeiInstallPeiMemory is called more than once!\n"));\r
     ASSERT (FALSE);\r
     return EFI_SUCCESS;\r
   }\r
-  \r
+\r
   PrivateData->PhysicalMemoryBegin   = MemoryBegin;\r
   PrivateData->PhysicalMemoryLength  = MemoryLength;\r
   PrivateData->FreePhysicalMemoryTop = MemoryBegin + MemoryLength;\r
-   \r
+\r
   PrivateData->SwitchStackSignal      = TRUE;\r
 \r
-  return EFI_SUCCESS;   \r
+  return EFI_SUCCESS;\r
 }\r
 \r
 /**\r
@@ -765,8 +765,8 @@ PeiFreePages (
 /**\r
 \r
   Pool allocation service. Before permanent memory is discoveried, the pool will\r
-  be allocated the heap in the temporary memory. Genenrally, the size of heap in temporary \r
-  memory does not exceed to 64K, so the biggest pool size could be allocated is \r
+  be allocated the heap in the temporary memory. Genenrally, the size of heap in temporary\r
+  memory does not exceed to 64K, so the biggest pool size could be allocated is\r
   64K.\r
 \r
   @param PeiServices               An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.\r
@@ -793,7 +793,7 @@ PeiAllocatePool (
   // If some "post-memory" PEIM wishes to allocate larger pool,\r
   // it should use AllocatePages service instead.\r
   //\r
-  \r
+\r
   //\r
   // Generally, the size of heap in temporary memory does not exceed to 64K,\r
   // HobLength is multiples of 8 bytes, so the maxmium size of pool is 0xFFF8 - sizeof (EFI_HOB_MEMORY_POOL)\r
@@ -801,14 +801,14 @@ PeiAllocatePool (
   if (Size > (0xFFF8 - sizeof (EFI_HOB_MEMORY_POOL))) {\r
     return EFI_OUT_OF_RESOURCES;\r
   }\r
-  \r
+\r
   Status = PeiServicesCreateHob (\r
              EFI_HOB_TYPE_MEMORY_POOL,\r
              (UINT16)(sizeof (EFI_HOB_MEMORY_POOL) + Size),\r
              (VOID **)&Hob\r
              );\r
   ASSERT_EFI_ERROR (Status);\r
-  *Buffer = Hob+1;  \r
+  *Buffer = Hob+1;\r
 \r
   return Status;\r
 }\r