]> git.proxmox.com Git - mirror_edk2.git/blobdiff - ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Fadt/FadtParser.c
ShellPkg/UefiShellAcpiViewCommandLib: Fix ECC issues
[mirror_edk2.git] / ShellPkg / Library / UefiShellAcpiViewCommandLib / Parsers / Fadt / FadtParser.c
index fdccb2ac3bd7698bbe1ce067964be53519813db1..cca25fcce9084c27a8444ac6a6554e7ae43e69ec 100644 (file)
@@ -1,4 +1,4 @@
-/**\r
+/** @file\r
   FADT table parser\r
 \r
   Copyright (c) 2016 - 2018, ARM Limited. All rights reserved.\r
   FADT table parser\r
 \r
   Copyright (c) 2016 - 2018, ARM Limited. All rights reserved.\r
@@ -25,43 +25,68 @@ STATIC CONST UINT64* X_DsdtAddress;
 STATIC CONST UINT8*  FadtMinorRevision;\r
 STATIC ACPI_DESCRIPTION_HEADER_INFO AcpiHdrInfo;\r
 \r
 STATIC CONST UINT8*  FadtMinorRevision;\r
 STATIC ACPI_DESCRIPTION_HEADER_INFO AcpiHdrInfo;\r
 \r
-/** A macro defining the Hardware reduced ACPI flag\r
-*/\r
+/**\r
+  A macro defining the Hardware reduced ACPI flag\r
+**/\r
 #define HW_REDUCED_ACPI   BIT20\r
 \r
 #define HW_REDUCED_ACPI   BIT20\r
 \r
-// Forward declarations\r
+/**\r
+  Get the ACPI XSDT header info.\r
+**/\r
 CONST ACPI_DESCRIPTION_HEADER_INFO* CONST\r
 EFIAPI\r
 GetAcpiXsdtHeaderInfo (\r
   VOID\r
 CONST ACPI_DESCRIPTION_HEADER_INFO* CONST\r
 EFIAPI\r
 GetAcpiXsdtHeaderInfo (\r
   VOID\r
-);\r
+  );\r
 \r
 \r
+/**\r
+  This function validates the Firmware Control Field.\r
+\r
+  @param [in] Ptr     Pointer to the start of the field data.\r
+  @param [in] Context Pointer to context specific information e.g. this\r
+                      could be a pointer to the ACPI table header.\r
+**/\r
 STATIC\r
 VOID\r
 EFIAPI\r
 ValidateFirmwareCtrl (\r
   IN UINT8* Ptr,\r
   IN VOID*  Context\r
 STATIC\r
 VOID\r
 EFIAPI\r
 ValidateFirmwareCtrl (\r
   IN UINT8* Ptr,\r
   IN VOID*  Context\r
-);\r
+  );\r
+\r
+/**\r
+  This function validates the X_Firmware Control Field.\r
 \r
 \r
+  @param [in] Ptr     Pointer to the start of the field data.\r
+  @param [in] Context Pointer to context specific information e.g. this\r
+                      could be a pointer to the ACPI table header.\r
+**/\r
 STATIC\r
 VOID\r
 EFIAPI\r
 ValidateXFirmwareCtrl (\r
   IN UINT8* Ptr,\r
   IN VOID*  Context\r
 STATIC\r
 VOID\r
 EFIAPI\r
 ValidateXFirmwareCtrl (\r
   IN UINT8* Ptr,\r
   IN VOID*  Context\r
-);\r
+  );\r
 \r
 \r
+/**\r
+  This function validates the flags.\r
+\r
+  @param [in] Ptr     Pointer to the start of the field data.\r
+  @param [in] Context Pointer to context specific information e.g. this\r
+                      could be a pointer to the ACPI table header.\r
+**/\r
 STATIC\r
 VOID\r
 EFIAPI\r
 ValidateFlags (\r
   IN UINT8* Ptr,\r
   IN VOID*  Context\r
 STATIC\r
 VOID\r
 EFIAPI\r
 ValidateFlags (\r
   IN UINT8* Ptr,\r
   IN VOID*  Context\r
-);\r
+  );\r
 \r
 \r
-/** An ACPI_PARSER array describing the ACPI FADT Table.\r
-*/\r
+/**\r
+  An ACPI_PARSER array describing the ACPI FADT Table.\r
+**/\r
 STATIC CONST ACPI_PARSER FadtParser[] = {\r
   PARSE_ACPI_HEADER (&AcpiHdrInfo),\r
   {L"FIRMWARE_CTRL", 4, 36, L"0x%x", NULL, NULL, ValidateFirmwareCtrl, NULL},\r
 STATIC CONST ACPI_PARSER FadtParser[] = {\r
   PARSE_ACPI_HEADER (&AcpiHdrInfo),\r
   {L"FIRMWARE_CTRL", 4, 36, L"0x%x", NULL, NULL, ValidateFirmwareCtrl, NULL},\r
@@ -123,12 +148,13 @@ STATIC CONST ACPI_PARSER FadtParser[] = {
   {L"Hypervisor VendorIdentity", 8, 268, L"%lx", NULL, NULL, NULL, NULL}\r
 };\r
 \r
   {L"Hypervisor VendorIdentity", 8, 268, L"%lx", NULL, NULL, NULL, NULL}\r
 };\r
 \r
-/** This function validates the Firmware Control Field.\r
+/**\r
+  This function validates the Firmware Control Field.\r
 \r
   @param [in] Ptr     Pointer to the start of the field data.\r
   @param [in] Context Pointer to context specific information e.g. this\r
                       could be a pointer to the ACPI table header.\r
 \r
   @param [in] Ptr     Pointer to the start of the field data.\r
   @param [in] Context Pointer to context specific information e.g. this\r
                       could be a pointer to the ACPI table header.\r
-*/\r
+**/\r
 STATIC\r
 VOID\r
 EFIAPI\r
 STATIC\r
 VOID\r
 EFIAPI\r
@@ -147,12 +173,13 @@ ValidateFirmwareCtrl (
 #endif\r
 }\r
 \r
 #endif\r
 }\r
 \r
-/** This function validates the X_Firmware Control Field.\r
+/**\r
+  This function validates the X_Firmware Control Field.\r
 \r
   @param [in] Ptr     Pointer to the start of the field data.\r
   @param [in] Context Pointer to context specific information e.g. this\r
                       could be a pointer to the ACPI table header.\r
 \r
   @param [in] Ptr     Pointer to the start of the field data.\r
   @param [in] Context Pointer to context specific information e.g. this\r
                       could be a pointer to the ACPI table header.\r
-*/\r
+**/\r
 STATIC\r
 VOID\r
 EFIAPI\r
 STATIC\r
 VOID\r
 EFIAPI\r
@@ -171,12 +198,13 @@ ValidateXFirmwareCtrl (
 #endif\r
 }\r
 \r
 #endif\r
 }\r
 \r
-/** This function validates the flags.\r
+/**\r
+  This function validates the flags.\r
 \r
   @param [in] Ptr     Pointer to the start of the field data.\r
   @param [in] Context Pointer to context specific information e.g. this\r
                       could be a pointer to the ACPI table header.\r
 \r
   @param [in] Ptr     Pointer to the start of the field data.\r
   @param [in] Context Pointer to context specific information e.g. this\r
                       could be a pointer to the ACPI table header.\r
-*/\r
+**/\r
 STATIC\r
 VOID\r
 EFIAPI\r
 STATIC\r
 VOID\r
 EFIAPI\r
@@ -195,9 +223,9 @@ ValidateFlags (
 #endif\r
 }\r
 \r
 #endif\r
 }\r
 \r
-/** This function parses the ACPI FADT table.\r
-  This function parses the FADT table and optionally traces the ACPI\r
-  table fields.\r
+/**\r
+  This function parses the ACPI FADT table.\r
+  This function parses the FADT table and optionally traces the ACPI table fields.\r
 \r
   This function also performs validation of the ACPI table fields.\r
 \r
 \r
   This function also performs validation of the ACPI table fields.\r
 \r
@@ -205,7 +233,7 @@ ValidateFlags (
   @param [in] Ptr                Pointer to the start of the buffer.\r
   @param [in] AcpiTableLength    Length of the ACPI table.\r
   @param [in] AcpiTableRevision  Revision of the ACPI table.\r
   @param [in] Ptr                Pointer to the start of the buffer.\r
   @param [in] AcpiTableLength    Length of the ACPI table.\r
   @param [in] AcpiTableRevision  Revision of the ACPI table.\r
-*/\r
+**/\r
 VOID\r
 EFIAPI\r
 ParseAcpiFadt (\r
 VOID\r
 EFIAPI\r
 ParseAcpiFadt (\r