void AcpiDmDumpFadt ( ACPI_TABLE_HEADER *Table) { /* Common ACPI 1.0 portion of FADT */ AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoFadt1); /* Check for ACPI 1.0B MS extensions (FADT revision 2) */ if (Table->Revision == 2) { AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoFadt2); } /* Check for ACPI 2.0+ extended data (FADT revision 3+) */ else if (Table->Length >= sizeof (ACPI_TABLE_FADT)) { AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoFadt3); } /* Validate various fields in the FADT, including length */ AcpiTbCreateLocalFadt (Table, Table->Length); }
void AcpiTbParseFadt ( void) { UINT32 Length; ACPI_TABLE_HEADER *Table; /* * The FADT has multiple versions with different lengths, * and it contains pointers to both the DSDT and FACS tables. * * Get a local copy of the FADT and convert it to a common format * Map entire FADT, assumed to be smaller than one page. */ Length = AcpiGbl_RootTableList.Tables[AcpiGbl_FadtIndex].Length; Table = AcpiOsMapMemory ( AcpiGbl_RootTableList.Tables[AcpiGbl_FadtIndex].Address, Length); if (!Table) { return; } /* * Validate the FADT checksum before we copy the table. Ignore * checksum error as we want to try to get the DSDT and FACS. */ (void) AcpiTbVerifyChecksum (Table, Length); /* Create a local copy of the FADT in common ACPI 2.0+ format */ AcpiTbCreateLocalFadt (Table, Length); /* All done with the real FADT, unmap it */ AcpiOsUnmapMemory (Table, Length); /* Obtain the DSDT and FACS tables via their addresses within the FADT */ AcpiTbInstallFixedTable ((ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.XDsdt, ACPI_SIG_DSDT, &AcpiGbl_DsdtIndex); /* If Hardware Reduced flag is set, there is no FACS */ if (!AcpiGbl_ReducedHardware) { if (AcpiGbl_FADT.Facs) { AcpiTbInstallFixedTable ((ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.Facs, ACPI_SIG_FACS, &AcpiGbl_FacsIndex); } if (AcpiGbl_FADT.XFacs) { AcpiTbInstallFixedTable ((ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.XFacs, ACPI_SIG_FACS, &AcpiGbl_XFacsIndex); } } }
void AcpiTbParseFadt ( ACPI_NATIVE_UINT TableIndex, UINT8 Flags) { UINT32 Length; ACPI_TABLE_HEADER *Table; /* * The FADT has multiple versions with different lengths, * and it contains pointers to both the DSDT and FACS tables. * * Get a local copy of the FADT and convert it to a common format * Map entire FADT, assumed to be smaller than one page. */ Length = AcpiGbl_RootTableList.Tables[TableIndex].Length; Table = AcpiOsMapMemory ( AcpiGbl_RootTableList.Tables[TableIndex].Address, Length); if (!Table) { return; } /* * Validate the FADT checksum before we copy the table. Ignore * checksum error as we want to try to get the DSDT and FACS. */ (void) AcpiTbVerifyChecksum (Table, Length); /* Obtain a local copy of the FADT in common ACPI 2.0+ format */ AcpiTbCreateLocalFadt (Table, Length); /* All done with the real FADT, unmap it */ AcpiOsUnmapMemory (Table, Length); /* Obtain the DSDT and FACS tables via their addresses within the FADT */ AcpiTbInstallTable ((ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.XDsdt, Flags, ACPI_SIG_DSDT, ACPI_TABLE_INDEX_DSDT); AcpiTbInstallTable ((ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.XFacs, Flags, ACPI_SIG_FACS, ACPI_TABLE_INDEX_FACS); }
void AcpiTbParseFadt ( void) { UINT32 Length; ACPI_TABLE_HEADER *Table; ACPI_TABLE_DESC *FadtDesc; ACPI_STATUS Status; /* * The FADT has multiple versions with different lengths, * and it contains pointers to both the DSDT and FACS tables. * * Get a local copy of the FADT and convert it to a common format * Map entire FADT, assumed to be smaller than one page. */ FadtDesc = &AcpiGbl_RootTableList.Tables[AcpiGbl_FadtIndex]; Status = AcpiTbGetTable (FadtDesc, &Table); if (ACPI_FAILURE (Status)) { return; } Length = FadtDesc->Length; /* * Validate the FADT checksum before we copy the table. Ignore * checksum error as we want to try to get the DSDT and FACS. */ (void) AcpiTbVerifyChecksum (Table, Length); /* Create a local copy of the FADT in common ACPI 2.0+ format */ AcpiTbCreateLocalFadt (Table, Length); /* All done with the real FADT, unmap it */ AcpiTbPutTable (FadtDesc); /* Obtain the DSDT and FACS tables via their addresses within the FADT */ AcpiTbInstallStandardTable ( (ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.XDsdt, ACPI_TABLE_ORIGIN_INTERNAL_PHYSICAL, FALSE, TRUE, &AcpiGbl_DsdtIndex); /* If Hardware Reduced flag is set, there is no FACS */ if (!AcpiGbl_ReducedHardware) { if (AcpiGbl_FADT.Facs) { AcpiTbInstallStandardTable ( (ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.Facs, ACPI_TABLE_ORIGIN_INTERNAL_PHYSICAL, FALSE, TRUE, &AcpiGbl_FacsIndex); } if (AcpiGbl_FADT.XFacs) { AcpiTbInstallStandardTable ( (ACPI_PHYSICAL_ADDRESS) AcpiGbl_FADT.XFacs, ACPI_TABLE_ORIGIN_INTERNAL_PHYSICAL, FALSE, TRUE, &AcpiGbl_XFacsIndex); } } }