/** @file\r
SRAT table parser\r
\r
- Copyright (c) 2016 - 2018, ARM Limited. All rights reserved.\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
+ Copyright (c) 2016 - 2019, ARM Limited. All rights reserved.\r
+ SPDX-License-Identifier: BSD-2-Clause-Patent\r
\r
@par Reference(s):\r
- ACPI 6.2 Specification - Errata A, September 2017\r
ValidateSratReserved (\r
IN UINT8* Ptr,\r
IN VOID* Context\r
- );\r
+ )\r
+{\r
+ if (*(UINT32*)Ptr != 1) {\r
+ IncrementErrorCount ();\r
+ Print (L"\nERROR: Reserved should be 1 for backward compatibility.\n");\r
+ }\r
+}\r
\r
/**\r
This function traces the APIC Proximity Domain field.\r
VOID\r
EFIAPI\r
DumpSratApicProximity (\r
- IN CONST CHAR16* Format,\r
- IN UINT8* Ptr\r
- );\r
+ IN CONST CHAR16* Format,\r
+ IN UINT8* Ptr\r
+ )\r
+{\r
+ UINT32 ProximityDomain;\r
+\r
+ ProximityDomain = Ptr[0] | (Ptr[1] << 8) | (Ptr[2] << 16);\r
+\r
+ Print (Format, ProximityDomain);\r
+}\r
\r
/**\r
An ACPI_PARSER array describing the SRAT Table.\r
{L"Reserved", 4, 20, L"0x%x", NULL, NULL, NULL, NULL}\r
};\r
\r
-/** This function validates the Reserved field in the SRAT 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
-STATIC\r
-VOID\r
-EFIAPI\r
-ValidateSratReserved (\r
- IN UINT8* Ptr,\r
- IN VOID* Context\r
- )\r
-{\r
- if (*(UINT32*)Ptr != 1) {\r
- IncrementErrorCount ();\r
- Print (L"\nERROR: Reserved should be 1 for backward compatibility.\n");\r
- }\r
-}\r
-\r
-/**\r
- This function traces the APIC Proximity Domain field.\r
-\r
- @param [in] Format Format string for tracing the data.\r
- @param [in] Ptr Pointer to the start of the buffer.\r
-**/\r
-STATIC\r
-VOID\r
-EFIAPI\r
-DumpSratApicProximity (\r
- IN CONST CHAR16* Format,\r
- IN UINT8* Ptr\r
- )\r
-{\r
- UINT32 ProximityDomain;\r
-\r
- ProximityDomain = Ptr[0] | (Ptr[1] << 8) | (Ptr[2] << 16);\r
-\r
- Print (Format, ProximityDomain);\r
-}\r
-\r
/**\r
This function parses the ACPI SRAT table.\r
When trace is enabled this function parses the SRAT table and\r