]> git.proxmox.com Git - mirror_edk2.git/blobdiff - ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Pcct/PcctParser.c
ShellPkg: Apply uncrustify changes
[mirror_edk2.git] / ShellPkg / Library / UefiShellAcpiViewCommandLib / Parsers / Pcct / PcctParser.c
index 6beee70b23a3b32992efa0edac48fe236591b9f5..8cffdaaf07166bbbf479e807f5bdfc22bdadfaed 100644 (file)
 #include "PcctParser.h"\r
 \r
 // Local variables\r
-STATIC ACPI_DESCRIPTION_HEADER_INFO AcpiHdrInfo;\r
+STATIC ACPI_DESCRIPTION_HEADER_INFO  AcpiHdrInfo;\r
 \r
-STATIC UINT32PccGlobalFlags;\r
-STATIC UINT8*  PccSubspaceLength;\r
-STATIC UINT8*  PccSubspaceType;\r
-STATIC UINT8*  ExtendedPccSubspaceInterruptFlags;\r
+STATIC UINT32  *PccGlobalFlags;\r
+STATIC UINT8   *PccSubspaceLength;\r
+STATIC UINT8   *PccSubspaceType;\r
+STATIC UINT8   *ExtendedPccSubspaceInterruptFlags;\r
 \r
 /**\r
   This function validates the length coded on 4 bytes of a shared memory range\r
@@ -35,16 +35,16 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidateRangeLength4 (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
-  if (*(UINT32*)Ptr < MIN_EXT_PCC_SUBSPACE_MEM_RANGE_LEN) {\r
+  if (*(UINT32 *)Ptr < MIN_EXT_PCC_SUBSPACE_MEM_RANGE_LEN) {\r
     IncrementErrorCount ();\r
     Print (\r
       L"\nError: Shared memory range length is too short.\n"\r
       L"Length is %u when it should be greater than or equal to %u",\r
-      *(UINT32*)Ptr,\r
+      *(UINT32 *)Ptr,\r
       MIN_EXT_PCC_SUBSPACE_MEM_RANGE_LEN\r
       );\r
   }\r
@@ -61,16 +61,16 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidateRangeLength8 (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
-  if (*(UINT64*)Ptr <= MIN_MEMORY_RANGE_LENGTH) {\r
+  if (*(UINT64 *)Ptr <= MIN_MEMORY_RANGE_LENGTH) {\r
     IncrementErrorCount ();\r
     Print (\r
       L"\nError: Shared memory range length is too short.\n"\r
       L"Length is %u when it should be greater than %u",\r
-      *(UINT64*)Ptr,\r
+      *(UINT64 *)Ptr,\r
       MIN_MEMORY_RANGE_LENGTH\r
       );\r
   }\r
@@ -87,14 +87,14 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidatePccMemoryIoGas (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
-  switch (*(UINT8*)Ptr) {\r
-#if !(defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
+  switch (*(UINT8 *)Ptr) {\r
+ #if !(defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
     case EFI_ACPI_6_4_SYSTEM_IO:\r
-#endif //if not (defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
+ #endif //if not (defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
     case EFI_ACPI_6_4_SYSTEM_MEMORY:\r
       return;\r
     default:\r
@@ -114,14 +114,14 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidatePccGas (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
-  switch (*(UINT8*)Ptr) {\r
-#if !(defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
+  switch (*(UINT8 *)Ptr) {\r
+ #if !(defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
     case EFI_ACPI_6_4_SYSTEM_IO:\r
-#endif //if not (defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
+ #endif //if not (defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64))\r
     case EFI_ACPI_6_4_FUNCTIONAL_FIXED_HARDWARE:\r
     case EFI_ACPI_6_4_SYSTEM_MEMORY:\r
       return;\r
@@ -142,8 +142,8 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidatePccDoorbellGas (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
   // For slave subspaces this field is optional, if not present the field\r
@@ -152,7 +152,8 @@ ValidatePccDoorbellGas (
     if (IsZeroBuffer (\r
           Ptr,\r
           sizeof (EFI_ACPI_6_4_GENERIC_ADDRESS_STRUCTURE)\r
-          )) {\r
+          ))\r
+    {\r
       return;\r
     }\r
   }\r
@@ -172,8 +173,8 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidatePccIntAckGas (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
   // If the subspace does not support interrupts or the interrupt is\r
@@ -183,12 +184,14 @@ ValidatePccIntAckGas (
   if (((*PccGlobalFlags & EFI_ACPI_6_4_PCCT_FLAGS_PLATFORM_INTERRUPT) !=\r
        EFI_ACPI_6_4_PCCT_FLAGS_PLATFORM_INTERRUPT) ||\r
       ((*ExtendedPccSubspaceInterruptFlags &\r
-       EFI_ACPI_6_4_PCCT_SUBSPACE_PLATFORM_INTERRUPT_FLAGS_MODE) ==\r
-       EFI_ACPI_6_4_PCCT_SUBSPACE_PLATFORM_INTERRUPT_FLAGS_MODE)) {\r
+        EFI_ACPI_6_4_PCCT_SUBSPACE_PLATFORM_INTERRUPT_FLAGS_MODE) ==\r
+       EFI_ACPI_6_4_PCCT_SUBSPACE_PLATFORM_INTERRUPT_FLAGS_MODE))\r
+  {\r
     if (IsZeroBuffer (\r
           Ptr,\r
           sizeof (EFI_ACPI_6_4_GENERIC_ADDRESS_STRUCTURE)\r
-          )) {\r
+          ))\r
+    {\r
       return;\r
     }\r
   }\r
@@ -207,8 +210,8 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidatePccErrStatusGas (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
   // This field is ignored by the OSPM on slave channels.\r
@@ -230,19 +233,20 @@ STATIC
 VOID\r
 EFIAPI\r
 ValidatePlatInterrupt (\r
-  IN UINT8Ptr,\r
-  IN VOID*  Context\r
+  IN UINT8  *Ptr,\r
+  IN VOID   *Context\r
   )\r
 {\r
   // If a slave subspace is present in the PCCT, then the global Platform\r
   // Interrupt flag must be set to 1.\r
   if ((*PccSubspaceType == EFI_ACPI_6_4_PCCT_SUBSPACE_TYPE_4_EXTENDED_PCC) &&\r
       ((*PccGlobalFlags & EFI_ACPI_6_4_PCCT_FLAGS_PLATFORM_INTERRUPT) !=\r
-        EFI_ACPI_6_4_PCCT_FLAGS_PLATFORM_INTERRUPT)) {\r
+       EFI_ACPI_6_4_PCCT_FLAGS_PLATFORM_INTERRUPT))\r
+  {\r
     IncrementErrorCount ();\r
     Print (\r
       L"\nError: Global Platform interrupt flag must be set to 1" \\r
-        L" if a PCC type 4 structure is present in PCCT."\r
+      L" if a PCC type 4 structure is present in PCCT."\r
       );\r
   }\r
 }\r
@@ -250,17 +254,17 @@ ValidatePlatInterrupt (
 /**\r
   An ACPI_PARSER array describing the ACPI PCCT Table.\r
 */\r
-STATIC CONST ACPI_PARSER PcctParser[] = {\r
+STATIC CONST ACPI_PARSER  PcctParser[] = {\r
   PARSE_ACPI_HEADER (&AcpiHdrInfo),\r
-  {L"Flags", 4, 36, NULL, NULL, (VOID**)&PccGlobalFlags, NULL, NULL},\r
-  {L"Reserved", 8, 40, NULL, NULL, NULL, NULL, NULL}\r
+  { L"Flags",                      4,  36, NULL, NULL, (VOID **)&PccGlobalFlags, NULL, NULL },\r
+  { L"Reserved",                   8,  40, NULL, NULL, NULL,                     NULL, NULL }\r
 };\r
 \r
 /**\r
   An ACPI_PARSER array describing the platform communications channel subspace\r
   structure header.\r
 */\r
-STATIC CONST ACPI_PARSER PccSubspaceHeaderParser[] = {\r
+STATIC CONST ACPI_PARSER  PccSubspaceHeaderParser[] = {\r
   PCC_SUBSPACE_HEADER ()\r
   // ... Type Specific Fields ...\r
 };\r
@@ -268,126 +272,126 @@ STATIC CONST ACPI_PARSER PccSubspaceHeaderParser[] = {
 /**\r
   An ACPI_PARSER array describing the Generic Communications Subspace - Type 0\r
 */\r
-STATIC CONST ACPI_PARSER PccSubspaceType0Parser[] = {\r
+STATIC CONST ACPI_PARSER  PccSubspaceType0Parser[] = {\r
   PCC_SUBSPACE_HEADER (),\r
-  {L"Reserved", 6, 2, L"%x %x %x %x %x %x", Dump6Chars, NULL, NULL, NULL},\r
-  {L"Base Address", 8, 8, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Memory Range Length", 8, 16, L"0x%lx", NULL, NULL, ValidateRangeLength8,\r
-    NULL},\r
-  {L"Doorbell Register", 12, 24, NULL, DumpGas, NULL, ValidatePccMemoryIoGas,\r
-    NULL},\r
-  {L"Doorbell Preserve", 8, 36, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Doorbell Write", 8, 44, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Nominal Latency", 4, 52, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Maximum Periodic Access Rate", 4, 56, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Minimum Request Turnaround Time", 2, 60, L"%u", NULL, NULL, NULL, NULL}\r
+  { L"Reserved",         6,   2,  L"%x %x %x %x %x %x", Dump6Chars, NULL, NULL,                   NULL },\r
+  { L"Base Address",     8,   8,  L"0x%lx",             NULL,       NULL, NULL,                   NULL },\r
+  { L"Memory Range Length",8,   16, L"0x%lx",             NULL,       NULL, ValidateRangeLength8,\r
+    NULL },\r
+  { L"Doorbell Register",12,  24, NULL,                 DumpGas,    NULL, ValidatePccMemoryIoGas,\r
+    NULL },\r
+  { L"Doorbell Preserve",8,   36, L"0x%lx",             NULL,       NULL, NULL,                   NULL },\r
+  { L"Doorbell Write",   8,   44, L"0x%lx",             NULL,       NULL, NULL,                   NULL },\r
+  { L"Nominal Latency",  4,   52, L"%u",                NULL,       NULL, NULL,                   NULL },\r
+  { L"Maximum Periodic Access Rate",4,   56, L"%u",                NULL,       NULL, NULL,                   NULL },\r
+  { L"Minimum Request Turnaround Time",2,   60, L"%u",                NULL,       NULL, NULL,                   NULL }\r
 };\r
 \r
 /**\r
   An ACPI_PARSER array describing the HW-Reduced Communications Subspace\r
   - Type 1\r
 */\r
-STATIC CONST ACPI_PARSER PccSubspaceType1Parser[] = {\r
+STATIC CONST ACPI_PARSER  PccSubspaceType1Parser[] = {\r
   PCC_SUBSPACE_HEADER (),\r
-  {L"Platform Interrupt", 4, 2, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Platform Interrupt Flags", 1, 6, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Reserved", 1, 7, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Base Address", 8, 8, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Memory Range Length", 8, 16, L"0x%lx", NULL, NULL, ValidateRangeLength8,\r
-    NULL},\r
-  {L"Doorbell Register", 12, 24, NULL, DumpGas, NULL,\r
-    ValidatePccGas, NULL},\r
-  {L"Doorbell Preserve", 8, 36, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Doorbell Write", 8, 44, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Nominal Latency", 4, 52, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Maximum Periodic Access Rate", 4, 56, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Minimum Request Turnaround Time", 2, 60, L"%u", NULL, NULL, NULL, NULL}\r
+  { L"Platform Interrupt",4,   2,  L"0x%x",  NULL,    NULL, NULL,                 NULL },\r
+  { L"Platform Interrupt Flags",1,   6,  L"0x%x",  NULL,    NULL, NULL,                 NULL },\r
+  { L"Reserved",         1,   7,  L"0x%x",  NULL,    NULL, NULL,                 NULL },\r
+  { L"Base Address",     8,   8,  L"0x%lx", NULL,    NULL, NULL,                 NULL },\r
+  { L"Memory Range Length",8,   16, L"0x%lx", NULL,    NULL, ValidateRangeLength8,\r
+    NULL },\r
+  { L"Doorbell Register",12,  24, NULL,     DumpGas, NULL,\r
+    ValidatePccGas,      NULL },\r
+  { L"Doorbell Preserve",8,   36, L"0x%lx", NULL,    NULL, NULL,                 NULL },\r
+  { L"Doorbell Write",   8,   44, L"0x%lx", NULL,    NULL, NULL,                 NULL },\r
+  { L"Nominal Latency",  4,   52, L"%u",    NULL,    NULL, NULL,                 NULL },\r
+  { L"Maximum Periodic Access Rate",4,   56, L"%u",    NULL,    NULL, NULL,                 NULL },\r
+  { L"Minimum Request Turnaround Time",2,   60, L"%u",    NULL,    NULL, NULL,                 NULL }\r
 };\r
 \r
 /**\r
   An ACPI_PARSER array describing the HW-Reduced Communications Subspace\r
   - Type 2\r
 */\r
-STATIC CONST ACPI_PARSER PccSubspaceType2Parser[] = {\r
+STATIC CONST ACPI_PARSER  PccSubspaceType2Parser[] = {\r
   PCC_SUBSPACE_HEADER (),\r
-  {L"Platform Interrupt", 4, 2, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Platform Interrupt Flags", 1, 6, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Reserved", 1, 7, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Base Address", 8, 8, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Memory Range Length", 8, 16, L"0x%lx", NULL, NULL, ValidateRangeLength8,\r
-    NULL},\r
-  {L"Doorbell Register", 12, 24, NULL, DumpGas, NULL,\r
-    ValidatePccGas, NULL},\r
-  {L"Doorbell Preserve", 8, 36, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Doorbell Write", 8, 44, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Nominal Latency", 4, 52, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Maximum Periodic Access Rate", 4, 56, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Minimum Request Turnaround Time", 2, 60, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Platform Interrupt Ack Register", 12, 62, NULL, DumpGas, NULL,\r
-    ValidatePccGas, NULL},\r
-  {L"Platform Interrupt Ack Preserve", 8, 74, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Platform Interrupt Ack Write", 8, 82, L"0x%lx", NULL, NULL,\r
-    NULL, NULL},\r
+  { L"Platform Interrupt",4,   2,  L"0x%x",  NULL,    NULL, NULL,                 NULL },\r
+  { L"Platform Interrupt Flags",1,   6,  L"0x%x",  NULL,    NULL, NULL,                 NULL },\r
+  { L"Reserved",         1,   7,  L"0x%x",  NULL,    NULL, NULL,                 NULL },\r
+  { L"Base Address",     8,   8,  L"0x%lx", NULL,    NULL, NULL,                 NULL },\r
+  { L"Memory Range Length",8,   16, L"0x%lx", NULL,    NULL, ValidateRangeLength8,\r
+    NULL },\r
+  { L"Doorbell Register",12,  24, NULL,     DumpGas, NULL,\r
+    ValidatePccGas,      NULL },\r
+  { L"Doorbell Preserve",8,   36, L"0x%lx", NULL,    NULL, NULL,                 NULL },\r
+  { L"Doorbell Write",   8,   44, L"0x%lx", NULL,    NULL, NULL,                 NULL },\r
+  { L"Nominal Latency",  4,   52, L"%u",    NULL,    NULL, NULL,                 NULL },\r
+  { L"Maximum Periodic Access Rate",4,   56, L"%u",    NULL,    NULL, NULL,                 NULL },\r
+  { L"Minimum Request Turnaround Time",2,   60, L"%u",    NULL,    NULL, NULL,                 NULL },\r
+  { L"Platform Interrupt Ack Register",12,  62, NULL,     DumpGas, NULL,\r
+    ValidatePccGas,      NULL },\r
+  { L"Platform Interrupt Ack Preserve",8,   74, L"0x%lx", NULL,    NULL, NULL,                 NULL },\r
+  { L"Platform Interrupt Ack Write",8,   82, L"0x%lx", NULL,    NULL,\r
+    NULL,                NULL },\r
 };\r
 \r
 /**\r
   An ACPI_PARSER array describing the Extended PCC Subspaces - Type 3/4\r
 */\r
-STATIC CONST ACPI_PARSER PccSubspaceType3Parser[] = {\r
+STATIC CONST ACPI_PARSER  PccSubspaceType3Parser[] = {\r
   PCC_SUBSPACE_HEADER (),\r
-  {L"Platform Interrupt", 4, 2, L"0x%x", NULL, NULL,\r
-    ValidatePlatInterrupt, NULL},\r
-  {L"Platform Interrupt Flags", 1, 6, L"0x%x", NULL,\r
-    (VOID**)&ExtendedPccSubspaceInterruptFlags, NULL, NULL},\r
-  {L"Reserved", 1, 7, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Base Address", 8, 8, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Memory Range Length", 4, 16, L"0x%x", NULL, NULL, ValidateRangeLength4,\r
-    NULL},\r
-  {L"Doorbell Register", 12, 20, NULL, DumpGas, NULL,\r
-    ValidatePccDoorbellGas, NULL},\r
-  {L"Doorbell Preserve", 8, 32, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Doorbell Write", 8, 40, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Nominal Latency", 4, 48, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Maximum Periodic Access Rate", 4, 52, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Minimum Request Turnaround Time", 4, 56, L"%u", NULL, NULL, NULL, NULL},\r
-  {L"Platform Interrupt Ack Register", 12, 60, NULL, DumpGas, NULL,\r
-    ValidatePccIntAckGas, NULL},\r
-  {L"Platform Interrupt Ack Preserve", 8, 72, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Platform Interrupt Ack Set", 8, 80, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Reserved", 8, 88, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Cmd Complete Check Reg Addr", 12, 96, NULL, DumpGas, NULL,\r
-    ValidatePccGas, NULL},\r
-  {L"Cmd Complete Check Mask", 8, 108, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Cmd Update Reg Addr", 12, 116, NULL, DumpGas, NULL,\r
-    ValidatePccGas, NULL},\r
-  {L"Cmd Update Preserve mask", 8, 128, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Cmd Update Set mask", 8, 136, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Error Status Register", 12, 144, NULL, DumpGas, NULL,\r
-    ValidatePccErrStatusGas, NULL},\r
-  {L"Error Status Mask", 8, 156, L"0x%lx", NULL, NULL, NULL, NULL},\r
+  { L"Platform Interrupt",                      4,     2,   L"0x%x",  NULL,    NULL,\r
+    ValidatePlatInterrupt,                      NULL },\r
+  { L"Platform Interrupt Flags",                1,     6,   L"0x%x",  NULL,\r
+    (VOID **)&ExtendedPccSubspaceInterruptFlags,NULL,  NULL },\r
+  { L"Reserved",                                1,     7,   L"0x%x",  NULL,    NULL,NULL,                  NULL },\r
+  { L"Base Address",                            8,     8,   L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Memory Range Length",                     4,     16,  L"0x%x",  NULL,    NULL,ValidateRangeLength4,\r
+    NULL },\r
+  { L"Doorbell Register",                       12,    20,  NULL,     DumpGas, NULL,\r
+    ValidatePccDoorbellGas,                     NULL },\r
+  { L"Doorbell Preserve",                       8,     32,  L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Doorbell Write",                          8,     40,  L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Nominal Latency",                         4,     48,  L"%u",    NULL,    NULL,NULL,                  NULL },\r
+  { L"Maximum Periodic Access Rate",            4,     52,  L"%u",    NULL,    NULL,NULL,                  NULL },\r
+  { L"Minimum Request Turnaround Time",         4,     56,  L"%u",    NULL,    NULL,NULL,                  NULL },\r
+  { L"Platform Interrupt Ack Register",         12,    60,  NULL,     DumpGas, NULL,\r
+    ValidatePccIntAckGas,                       NULL },\r
+  { L"Platform Interrupt Ack Preserve",         8,     72,  L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Platform Interrupt Ack Set",              8,     80,  L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Reserved",                                8,     88,  L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Cmd Complete Check Reg Addr",             12,    96,  NULL,     DumpGas, NULL,\r
+    ValidatePccGas,                             NULL },\r
+  { L"Cmd Complete Check Mask",                 8,     108, L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Cmd Update Reg Addr",                     12,    116, NULL,     DumpGas, NULL,\r
+    ValidatePccGas,                             NULL },\r
+  { L"Cmd Update Preserve mask",                8,     128, L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Cmd Update Set mask",                     8,     136, L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
+  { L"Error Status Register",                   12,    144, NULL,     DumpGas, NULL,\r
+    ValidatePccErrStatusGas,                    NULL },\r
+  { L"Error Status Mask",                       8,     156, L"0x%lx", NULL,    NULL,NULL,                  NULL },\r
 };\r
 \r
 /**\r
   An ACPI_PARSER array describing the HW Registers based Communications\r
   Subspace Structure - Type 5\r
 */\r
-STATIC CONST ACPI_PARSER PccSubspaceType5Parser[] = {\r
+STATIC CONST ACPI_PARSER  PccSubspaceType5Parser[] = {\r
   PCC_SUBSPACE_HEADER (),\r
-  {L"Version", 2, 2, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Base Address", 8, 4, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Shared Memory Range Length", 8, 12, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Doorbell Register", 12, 20, NULL, DumpGas, NULL,\r
-    ValidatePccMemoryIoGas, NULL},\r
-  {L"Doorbell Preserve", 8, 32, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Doorbell Write", 8, 40, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Command Complete Check Register", 12, 48, NULL, DumpGas, NULL,\r
-    ValidatePccMemoryIoGas, NULL},\r
-  {L"Command Complete Check Mask", 8, 60, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Error Status Register", 12, 68, NULL, DumpGas, NULL,\r
-    ValidatePccMemoryIoGas, NULL},\r
-  {L"Error Status Mask", 8, 80, L"0x%lx", NULL, NULL, NULL, NULL},\r
-  {L"Nominal Latency", 4, 88, L"0x%x", NULL, NULL, NULL, NULL},\r
-  {L"Minimum Request Turnaround Time", 4, 92, L"0x%x", NULL, NULL, NULL, NULL}\r
+  { L"Version",            2,   2,  L"0x%x",  NULL,    NULL, NULL, NULL },\r
+  { L"Base Address",       8,   4,  L"0x%lx", NULL,    NULL, NULL, NULL },\r
+  { L"Shared Memory Range Length",8,   12, L"0x%lx", NULL,    NULL, NULL, NULL },\r
+  { L"Doorbell Register",  12,  20, NULL,     DumpGas, NULL,\r
+    ValidatePccMemoryIoGas,NULL },\r
+  { L"Doorbell Preserve",  8,   32, L"0x%lx", NULL,    NULL, NULL, NULL },\r
+  { L"Doorbell Write",     8,   40, L"0x%lx", NULL,    NULL, NULL, NULL },\r
+  { L"Command Complete Check Register",12,  48, NULL,     DumpGas, NULL,\r
+    ValidatePccMemoryIoGas,NULL },\r
+  { L"Command Complete Check Mask",8,   60, L"0x%lx", NULL,    NULL, NULL, NULL },\r
+  { L"Error Status Register",12,  68, NULL,     DumpGas, NULL,\r
+    ValidatePccMemoryIoGas,NULL },\r
+  { L"Error Status Mask",  8,   80, L"0x%lx", NULL,    NULL, NULL, NULL },\r
+  { L"Nominal Latency",    4,   88, L"0x%x",  NULL,    NULL, NULL, NULL },\r
+  { L"Minimum Request Turnaround Time",4,   92, L"0x%x",  NULL,    NULL, NULL, NULL }\r
 };\r
 \r
 /**\r
@@ -399,7 +403,7 @@ STATIC CONST ACPI_PARSER PccSubspaceType5Parser[] = {
 STATIC\r
 VOID\r
 DumpPccSubspaceType0 (\r
-  IN UINT8Ptr,\r
+  IN UINT8  *Ptr,\r
   IN UINT8  Length\r
   )\r
 {\r
@@ -422,7 +426,7 @@ DumpPccSubspaceType0 (
 STATIC\r
 VOID\r
 DumpPccSubspaceType1 (\r
-  IN UINT8Ptr,\r
+  IN UINT8  *Ptr,\r
   IN UINT8  Length\r
   )\r
 {\r
@@ -445,7 +449,7 @@ DumpPccSubspaceType1 (
 STATIC\r
 VOID\r
 DumpPccSubspaceType2 (\r
-  IN UINT8Ptr,\r
+  IN UINT8  *Ptr,\r
   IN UINT8  Length\r
   )\r
 {\r
@@ -468,7 +472,7 @@ DumpPccSubspaceType2 (
 STATIC\r
 VOID\r
 DumpPccSubspaceType3 (\r
-  IN UINT8Ptr,\r
+  IN UINT8  *Ptr,\r
   IN UINT8  Length\r
   )\r
 {\r
@@ -491,7 +495,7 @@ DumpPccSubspaceType3 (
 STATIC\r
 VOID\r
 DumpPccSubspaceType4 (\r
-  IN UINT8Ptr,\r
+  IN UINT8  *Ptr,\r
   IN UINT8  Length\r
   )\r
 {\r
@@ -514,7 +518,7 @@ DumpPccSubspaceType4 (
 STATIC\r
 VOID\r
 DumpPccSubspaceType5 (\r
-  IN UINT8Ptr,\r
+  IN UINT8  *Ptr,\r
   IN UINT8  Length\r
   )\r
 {\r
@@ -544,15 +548,15 @@ DumpPccSubspaceType5 (
 VOID\r
 EFIAPI\r
 ParseAcpiPcct (\r
-  IN BOOLEAN Trace,\r
-  IN UINT8*  Ptr,\r
-  IN UINT32  AcpiTableLength,\r
-  IN UINT8   AcpiTableRevision\r
+  IN BOOLEAN  Trace,\r
+  IN UINT8    *Ptr,\r
+  IN UINT32   AcpiTableLength,\r
+  IN UINT8    AcpiTableRevision\r
   )\r
 {\r
-  UINT32 Offset;\r
-  UINT8PccSubspacePtr;\r
-  UINTN  SubspaceCount;\r
+  UINT32  Offset;\r
+  UINT8   *PccSubspacePtr;\r
+  UINTN   SubspaceCount;\r
 \r
   if (!Trace) {\r
     return;\r
@@ -584,11 +588,12 @@ ParseAcpiPcct (
     // Check if the values used to control the parsing logic have been\r
     // successfully read.\r
     if ((PccSubspaceType == NULL) ||\r
-        (PccSubspaceLength == NULL)) {\r
+        (PccSubspaceLength == NULL))\r
+    {\r
       IncrementErrorCount ();\r
       Print (\r
         L"ERROR: Insufficient remaining table buffer length to read the " \\r
-          L"structure header. Length = %u.\n",\r
+        L"structure header. Length = %u.\n",\r
         AcpiTableLength - Offset\r
         );\r
       return;\r
@@ -596,11 +601,12 @@ ParseAcpiPcct (
 \r
     // Validate Structure length\r
     if ((*PccSubspaceLength == 0) ||\r
-        ((Offset + (*PccSubspaceLength)) > AcpiTableLength)) {\r
+        ((Offset + (*PccSubspaceLength)) > AcpiTableLength))\r
+    {\r
       IncrementErrorCount ();\r
       Print (\r
         L"ERROR: Invalid Structure length. " \\r
-          L"Length = %u. Offset = %u. AcpiTableLength = %u.\n",\r
+        L"Length = %u. Offset = %u. AcpiTableLength = %u.\n",\r
         *PccSubspaceLength,\r
         Offset,\r
         AcpiTableLength\r
@@ -649,14 +655,14 @@ ParseAcpiPcct (
         IncrementErrorCount ();\r
         Print (\r
           L"ERROR: Unknown PCC subspace structure:"\r
-            L" Type = %u, Length = %u\n",\r
+          L" Type = %u, Length = %u\n",\r
           PccSubspaceType,\r
           *PccSubspaceLength\r
           );\r
     }\r
 \r
     PccSubspacePtr += *PccSubspaceLength;\r
-    Offset += *PccSubspaceLength;\r
+    Offset         += *PccSubspaceLength;\r
     SubspaceCount++;\r
   } // while\r
 \r