static BOOLEAN AcpiTbCompareTables ( ACPI_TABLE_DESC *TableDesc, UINT32 TableIndex) { ACPI_STATUS Status = AE_OK; BOOLEAN IsIdentical; ACPI_TABLE_HEADER *Table; UINT32 TableLength; UINT8 TableFlags; Status = AcpiTbAcquireTable (&AcpiGbl_RootTableList.Tables[TableIndex], &Table, &TableLength, &TableFlags); if (ACPI_FAILURE (Status)) { return (FALSE); } /* * Check for a table match on the entire table length, * not just the header. */ IsIdentical = (BOOLEAN)((TableDesc->Length != TableLength || memcmp (TableDesc->Pointer, Table, TableLength)) ? FALSE : TRUE); /* Release the acquired table */ AcpiTbReleaseTable (Table, TableLength, TableFlags); return (IsIdentical); }
void AcpiTbInvalidateTable ( ACPI_TABLE_DESC *TableDesc) { ACPI_FUNCTION_TRACE (TbInvalidateTable); /* Table must be validated */ if (!TableDesc->Pointer) { return_VOID; } AcpiTbReleaseTable (TableDesc->Pointer, TableDesc->Length, TableDesc->Flags); TableDesc->Pointer = NULL; return_VOID; }