]> git.proxmox.com Git - mirror_edk2.git/blobdiff - EmbeddedPkg/Library/PrePiHobLib/Hob.c
ARM Packages: Removed trailing spaces
[mirror_edk2.git] / EmbeddedPkg / Library / PrePiHobLib / Hob.c
index 320dddfc256aa876cfa251e4db2cc430af9959fb..aff532259ef48fad581d6aaab7f4e860e7d40050 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
 \r
   Copyright (c) 2010, Apple Inc. All rights reserved.<BR>\r
-  \r
+\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
@@ -193,7 +193,7 @@ CreateHobList (
   SetHobList (Hob);\r
 \r
   BuildCpuHob (PcdGet8 (PcdPrePiCpuMemorySize), PcdGet8 (PcdPrePiCpuIoSize));\r
-  \r
+\r
   Attributes =(\r
     EFI_RESOURCE_ATTRIBUTE_PRESENT |\r
     EFI_RESOURCE_ATTRIBUTE_INITIALIZED |\r
@@ -209,25 +209,25 @@ CreateHobList (
   BuildStackHob ((EFI_PHYSICAL_ADDRESS)(UINTN)StackBase, ((UINTN)MemoryBegin + MemoryLength) - (UINTN)StackBase);\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
-  \r
+}\r
+\r
 \r
 VOID\r
 EFIAPI\r
-BuildFvHobs (  \r
+BuildFvHobs (\r
   IN EFI_PHYSICAL_ADDRESS         PhysicalStart,\r
   IN UINT64                       NumberOfBytes,\r
   IN EFI_RESOURCE_ATTRIBUTE_TYPE  *ResourceAttribute\r
-  ) \r
+  )\r
 {\r
 \r
   EFI_RESOURCE_ATTRIBUTE_TYPE Resource;\r
-  \r
+\r
   BuildFvHob (PhysicalStart, NumberOfBytes);\r
-  \r
+\r
   if (ResourceAttribute == NULL) {\r
     Resource = (EFI_RESOURCE_ATTRIBUTE_PRESENT    |\r
                 EFI_RESOURCE_ATTRIBUTE_INITIALIZED |\r
@@ -236,14 +236,14 @@ BuildFvHobs (
   } else {\r
     Resource = *ResourceAttribute;\r
   }\r
-  \r
+\r
   BuildResourceDescriptorHob (EFI_RESOURCE_FIRMWARE_DEVICE, Resource, PhysicalStart, NumberOfBytes);\r
 }\r
 \r
 /**\r
   Returns the next instance of a HOB type from the starting HOB.\r
 \r
-  This function searches the first instance of a HOB type from the starting HOB pointer. \r
+  This function searches the first instance of a HOB type from the starting HOB pointer.\r
   If there does not exist such HOB type from the starting HOB pointer, it will return NULL.\r
   In contrast with macro GET_NEXT_HOB(), this function does not skip the starting HOB pointer\r
   unconditionally: it returns HobStart back if HobStart itself meets the requirement;\r
@@ -266,7 +266,7 @@ GetNextHob (
   EFI_PEI_HOB_POINTERS  Hob;\r
 \r
   ASSERT (HobStart != NULL);\r
-   \r
+\r
   Hob.Raw = (UINT8 *) HobStart;\r
   //\r
   // Parse the HOB list until end of list or matching type is found.\r
@@ -279,14 +279,14 @@ GetNextHob (
   }\r
   return NULL;\r
 }\r
-  \r
-  \r
+\r
+\r
 \r
 /**\r
   Returns the first instance of a HOB type among the whole HOB list.\r
 \r
-  This function searches the first instance of a HOB type among the whole HOB list. \r
-  If there does not exist such HOB type in the HOB list, it will return NULL. \r
+  This function searches the first instance of a HOB type among the whole HOB list.\r
+  If there does not exist such HOB type in the HOB list, it will return NULL.\r
 \r
   @param  Type          The HOB type to return.\r
 \r
@@ -307,10 +307,10 @@ GetFirstHob (
 \r
 \r
 /**\r
-  This function searches the first instance of a HOB from the starting HOB pointer. \r
-  Such HOB should satisfy two conditions: \r
-  its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid. \r
-  If there does not exist such HOB from the starting HOB pointer, it will return NULL. \r
+  This function searches the first instance of a HOB from the starting HOB pointer.\r
+  Such HOB should satisfy two conditions:\r
+  its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.\r
+  If there does not exist such HOB from the starting HOB pointer, it will return NULL.\r
   Caller is required to apply GET_GUID_HOB_DATA () and GET_GUID_HOB_DATA_SIZE ()\r
   to extract the data section and its size info respectively.\r
   In contrast with macro GET_NEXT_HOB(), this function does not skip the starting HOB pointer\r
@@ -345,7 +345,7 @@ GetNextGuidHob (
 \r
 \r
 /**\r
-  This function searches the first instance of a HOB among the whole HOB list. \r
+  This function searches the first instance of a HOB among the whole HOB list.\r
   Such HOB should satisfy two conditions:\r
   its HOB type is EFI_HOB_TYPE_GUID_EXTENSION and its GUID Name equals to the input Guid.\r
   If there does not exist such HOB from the starting HOB pointer, it will return NULL.\r
@@ -374,7 +374,7 @@ GetFirstGuidHob (
 /**\r
   Get the Boot Mode from the HOB list.\r
 \r
-  This function returns the system boot mode information from the \r
+  This function returns the system boot mode information from the\r
   PHIT HOB in HOB list.\r
 \r
   @param  VOID\r
@@ -398,7 +398,7 @@ GetBootMode (
 /**\r
   Get the Boot Mode from the HOB list.\r
 \r
-  This function returns the system boot mode information from the \r
+  This function returns the system boot mode information from the\r
   PHIT HOB in HOB list.\r
 \r
   @param  VOID\r
@@ -459,7 +459,7 @@ BuildModuleHob (
   // Zero the reserved space to match HOB spec\r
   //\r
   ZeroMem (Hob->MemoryAllocationHeader.Reserved, sizeof (Hob->MemoryAllocationHeader.Reserved));\r
-  \r
+\r
   CopyGuid (&Hob->ModuleName, ModuleName);\r
   Hob->EntryPoint = EntryPoint;\r
 }\r
@@ -467,8 +467,8 @@ BuildModuleHob (
 /**\r
   Builds a GUID HOB with a certain data length.\r
 \r
-  This function builds a customized HOB tagged with a GUID for identification \r
-  and returns the start address of GUID HOB data so that caller can fill the customized data. \r
+  This function builds a customized HOB tagged with a GUID for identification\r
+  and returns the start address of GUID HOB data so that caller can fill the customized data.\r
   The HOB Header and Name field is already stripped.\r
   It can only be invoked during PEI phase;\r
   for DXE phase, it will ASSERT() since PEI HOB is read-only for DXE phase.\r
@@ -580,7 +580,7 @@ BuildFvHob (
   @param  Length        The size of the Firmware Volume in bytes.\r
   @param  FvName       The name of the Firmware Volume.\r
   @param  FileName      The name of the file.\r
-  \r
+\r
 **/\r
 VOID\r
 EFIAPI\r
@@ -655,7 +655,7 @@ BuildCpuHob (
   //\r
   // Zero the reserved space to match HOB spec\r
   //\r
-  ZeroMem (Hob->Reserved, sizeof (Hob->Reserved)); \r
+  ZeroMem (Hob->Reserved, sizeof (Hob->Reserved));\r
 }\r
 \r
 \r
@@ -762,9 +762,9 @@ BuildMemoryAllocationHob (
 \r
   ASSERT (((BaseAddress & (EFI_PAGE_SIZE - 1)) == 0) &&\r
           ((Length & (EFI_PAGE_SIZE - 1)) == 0));\r
-  \r
+\r
   Hob = CreateHob (EFI_HOB_TYPE_MEMORY_ALLOCATION, sizeof (EFI_HOB_MEMORY_ALLOCATION));\r
-  \r
+\r
   ZeroMem (&(Hob->AllocDescriptor.Name), sizeof (EFI_GUID));\r
   Hob->AllocDescriptor.MemoryBaseAddress = BaseAddress;\r
   Hob->AllocDescriptor.MemoryLength      = Length;\r
@@ -786,7 +786,7 @@ BuildExtractSectionHob (
   )\r
 {\r
   EXTRACT_SECTION_DATA Data;\r
-  \r
+\r
   Data.SectionGetInfo    = SectionGetInfo;\r
   Data.SectionExtraction = SectionExtraction;\r
   BuildGuidDataHob (Guid, &Data, sizeof (Data));\r
@@ -809,10 +809,10 @@ BuildPeCoffLoaderHob (
   VOID\r
   )\r
 {\r
-  VOID  *Ptr;      \r
-  \r
+  VOID  *Ptr;\r
+\r
   Ptr = &gPeCoffProtocol;\r
-  BuildGuidDataHob (&gPeCoffLoaderProtocolGuid, &Ptr, sizeof (VOID *));  \r
+  BuildGuidDataHob (&gPeCoffLoaderProtocolGuid, &Ptr, sizeof (VOID *));\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