EFI/acpidump: Remove Gbl_DumpCustomizedTables awareness

EFI environment doesn't support any table customization mechanism, and
acpidump defaults to use "-c on", it then is a problem that in UEFI
environment, user can obtain nothing by just type "acpidump.efi". This
patch removes Gbl_DumpCustomizedTables awaness to fix this issue. Lv Zheng.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
This commit is contained in:
Lv Zheng 2016-05-26 08:44:31 +08:00
parent 3a81e13d16
commit 9fcf90766f
1 changed files with 33 additions and 53 deletions

View File

@ -305,18 +305,7 @@ AcpiOsGetTableByName (
/* Not a main ACPI table, attempt to extract it from the RSDT/XSDT */ /* Not a main ACPI table, attempt to extract it from the RSDT/XSDT */
if (!Gbl_DumpCustomizedTables) Status = OslGetTable (Signature, Instance, Table, Address);
{
/* Attempt to get the table from the memory */
Status = OslGetTable (Signature, Instance, Table, Address);
}
else
{
/* Attempt to get the table from the static directory */
Status = AE_SUPPORT;
}
return (Status); return (Status);
} }
@ -650,56 +639,47 @@ OslTableInitialize (
return (Status); return (Status);
} }
if (!Gbl_DumpCustomizedTables) /* Add mandatory tables to global table list first */
Status = OslAddTableToList (ACPI_RSDP_NAME, 0);
if (ACPI_FAILURE (Status))
{ {
/* Add mandatory tables to global table list first */ return (Status);
}
Status = OslAddTableToList (ACPI_RSDP_NAME, 0); Status = OslAddTableToList (ACPI_SIG_RSDT, 0);
if (ACPI_FAILURE (Status)) if (ACPI_FAILURE (Status))
{ {
return (Status); return (Status);
} }
Status = OslAddTableToList (ACPI_SIG_RSDT, 0); if (Gbl_Revision == 2)
if (ACPI_FAILURE (Status)) {
{ Status = OslAddTableToList (ACPI_SIG_XSDT, 0);
return (Status);
}
if (Gbl_Revision == 2)
{
Status = OslAddTableToList (ACPI_SIG_XSDT, 0);
if (ACPI_FAILURE (Status))
{
return (Status);
}
}
Status = OslAddTableToList (ACPI_SIG_DSDT, 0);
if (ACPI_FAILURE (Status))
{
return (Status);
}
Status = OslAddTableToList (ACPI_SIG_FACS, 0);
if (ACPI_FAILURE (Status))
{
return (Status);
}
/* Add all tables found in the memory */
Status = OslListTables ();
if (ACPI_FAILURE (Status)) if (ACPI_FAILURE (Status))
{ {
return (Status); return (Status);
} }
} }
else
{
/* Add all tables found in the static directory */
Status = AE_SUPPORT; Status = OslAddTableToList (ACPI_SIG_DSDT, 0);
if (ACPI_FAILURE (Status))
{
return (Status);
}
Status = OslAddTableToList (ACPI_SIG_FACS, 0);
if (ACPI_FAILURE (Status))
{
return (Status);
}
/* Add all tables found in the memory */
Status = OslListTables ();
if (ACPI_FAILURE (Status))
{
return (Status);
} }
Gbl_TableListInitialized = TRUE; Gbl_TableListInitialized = TRUE;