30#define HW_REDUCED_ACPI BIT20
35#define FACS_SIGNATURE_OFFSET 0
40#define FACS_VERSION_OFFSET 32
45#define FACS_LENGTH_OFFSET 4
73 #if defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64)
74 if (*(UINT32 *)Ptr != 0) {
77 L
"\nERROR: Firmware Control must be zero for ARM platforms."
101 #if defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64)
102 if (*(UINT64 *)Ptr != 0) {
105 L
"\nERROR: X Firmware Control must be zero for ARM platforms."
129 #if defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64)
133 L
"\nERROR: HW_REDUCED_ACPI flag must be set for ARM platforms."
160 { L
"FORCE_APIC_PHYSICAL_DESTINATION_MODE", 1, 19, L
"%d",
NULL,
NULL,
NULL,
NULL },
177 IN CONST CHAR16 *Format OPTIONAL,
182 if (Format !=
NULL) {
183 Print (Format, *(UINT32 *)Ptr);
187 Print (L
"0x%X\n", *(UINT32 *)Ptr);
203 { L
"FIRMWARE_CTRL", 4, 36, L
"0x%x",
NULL, (VOID **)&FirmwareCtrl,
205 { L
"DSDT", 4, 40, L
"0x%x",
NULL, (VOID **)&DsdtAddress,
NULL,
NULL },
245 { L
"FADT Minor Version", 1, 131, L
"0x%x",
NULL, (VOID **)&FadtMinorRevision,
247 { L
"X_FIRMWARE_CTRL", 8, 132, L
"0x%lx",
NULL, (VOID **)&X_FirmwareCtrl,
249 { L
"X_DSDT", 8, 140, L
"0x%lx",
NULL, (VOID **)&X_DsdtAddress,
NULL,
NULL },
279 IN UINT32 AcpiTableLength,
280 IN UINT8 AcpiTableRevision
285 UINT8 *FirmwareCtrlPtr;
286 UINT32 FacsSignature;
301 if (FadtMinorRevision !=
NULL) {
302 Print (L
"\nSummary:\n");
304 Print (L
"%d.%d\n", *AcpiHdrInfo.
Revision, *FadtMinorRevision);
309 Print (L
"ERROR: OEM Table Id does not match with RSDT/XSDT.\n");
315 if ((X_FirmwareCtrl !=
NULL) && (*X_FirmwareCtrl != 0)) {
316 FirmwareCtrlPtr = (UINT8 *)(
UINTN)(*X_FirmwareCtrl);
317 }
else if ((FirmwareCtrl !=
NULL) && (*FirmwareCtrl != 0)) {
318 FirmwareCtrlPtr = (UINT8 *)(
UINTN)(*FirmwareCtrl);
320 FirmwareCtrlPtr =
NULL;
326 ((*Flags & EFI_ACPI_6_3_HW_REDUCED_ACPI) != EFI_ACPI_6_3_HW_REDUCED_ACPI))
330 L
"ERROR: No FACS table found, "
331 L
"both X_FIRMWARE_CTRL and FIRMWARE_CTRL are zero.\n"
336 if (FirmwareCtrlPtr !=
NULL) {
354 Status =
GetParser (FacsSignature, &FacsParserProc);
355 if (EFI_ERROR (Status)) {
357 L
"ERROR: No registered parser found for FACS.\n"
371 if ((X_DsdtAddress !=
NULL) && (*X_DsdtAddress != 0)) {
372 DsdtPtr = (UINT8 *)(
UINTN)(*X_DsdtAddress);
373 }
else if ((DsdtAddress !=
NULL) && (*DsdtAddress != 0)) {
374 DsdtPtr = (UINT8 *)(
UINTN)(*DsdtAddress);
377 #if defined (MDE_CPU_ARM) || defined (MDE_CPU_AARCH64)
383 Print (L
"ERROR: Both X_DSDT and DSDT are invalid.\n");
VOID EFIAPI DumpGas(IN CONST CHAR16 *Format OPTIONAL, IN UINT8 *Ptr, IN UINT32 Length)
VOID EFIAPI PrintFieldName(IN UINT32 Indent, IN CONST CHAR16 *FieldName)
VOID EFIAPI IncrementErrorCount(VOID)
UINT32 EFIAPI ParseAcpi(IN BOOLEAN Trace, IN UINT32 Indent, IN CONST CHAR8 *AsciiName OPTIONAL, IN UINT8 *Ptr, IN UINT32 Length, IN CONST ACPI_PARSER *Parser, IN UINT32 ParserItems)
UINT32 EFIAPI ParseAcpiBitFields(IN BOOLEAN Trace, IN UINT32 Indent, IN CONST CHAR8 *AsciiName OPTIONAL, IN UINT8 *Ptr, IN UINT32 Length, IN CONST ACPI_PARSER *Parser, IN UINT32 ParserItems)
#define PARSER_PARAMS(Parser)
#define PARSE_ACPI_HEADER(Info)
EFI_STATUS EFIAPI GetParser(IN UINT32 Signature, OUT PARSE_ACPI_TABLE_PROC *ParserProc)
VOID EFIAPI ProcessAcpiTable(IN UINT8 *Ptr)
VOID(EFIAPI * PARSE_ACPI_TABLE_PROC)(IN BOOLEAN Trace, IN UINT8 *Ptr, IN UINT32 AcpiTableLength, IN UINT8 AcpiTableRevision)
BOOLEAN ProcessTableReportOptions(IN CONST UINT32 Signature, IN CONST UINT8 *TablePtr, IN CONST UINT32 Length)
#define FACS_VERSION_OFFSET
VOID EFIAPI DumpFadtFlags(IN CONST CHAR16 *Format OPTIONAL, IN UINT8 *Ptr, IN UINT32 Length)
STATIC VOID EFIAPI ValidateXFirmwareCtrl(IN UINT8 *Ptr, IN UINT32 Length, IN VOID *Context)
CONST ACPI_DESCRIPTION_HEADER_INFO *EFIAPI GetAcpiXsdtHeaderInfo(VOID)
STATIC VOID EFIAPI ValidateFlags(IN UINT8 *Ptr, IN UINT32 Length, IN VOID *Context)
#define FACS_SIGNATURE_OFFSET
STATIC VOID EFIAPI ValidateFirmwareCtrl(IN UINT8 *Ptr, IN UINT32 Length, IN VOID *Context)
VOID EFIAPI ParseAcpiFadt(IN BOOLEAN Trace, IN UINT8 *Ptr, IN UINT32 AcpiTableLength, IN UINT8 AcpiTableRevision)
STATIC CONST ACPI_PARSER FadtParser[]
#define FACS_LENGTH_OFFSET
UINTN EFIAPI Print(IN CONST CHAR16 *Format,...)