Skip to content

Commit

Permalink
Revert "ACPICA: Update table load object initialization"
Browse files Browse the repository at this point in the history
Revert commit c522ad0 ("ACPICA: Update table load object
initialization") as it causes systems to hang on attempts to load
OEM ACPI tables.

Reported-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Rafael J. Wysocki committed Jul 10, 2019
1 parent 4b47045 commit 6cf7fb5
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 9 deletions.
16 changes: 10 additions & 6 deletions drivers/acpi/acpica/exconfig.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,12 @@ acpi_ex_load_table_op(struct acpi_walk_state *walk_state,
return_ACPI_STATUS(status);
}

/* Complete the initialization/resolution of new objects */
/* Complete the initialization/resolution of package objects */

acpi_ns_initialize_objects();
status = acpi_ns_walk_namespace(ACPI_TYPE_PACKAGE, ACPI_ROOT_OBJECT,
ACPI_UINT32_MAX, 0,
acpi_ns_init_one_package, NULL, NULL,
NULL);

/* Parameter Data (optional) */

Expand Down Expand Up @@ -434,11 +437,12 @@ acpi_ex_load_op(union acpi_operand_object *obj_desc,
return_ACPI_STATUS(status);
}

/* Complete the initialization/resolution of new objects */
/* Complete the initialization/resolution of package objects */

acpi_ex_exit_interpreter();
acpi_ns_initialize_objects();
acpi_ex_enter_interpreter();
status = acpi_ns_walk_namespace(ACPI_TYPE_PACKAGE, ACPI_ROOT_OBJECT,
ACPI_UINT32_MAX, 0,
acpi_ns_init_one_package, NULL, NULL,
NULL);

/* Store the ddb_handle into the Target operand */

Expand Down
10 changes: 7 additions & 3 deletions drivers/acpi/acpica/tbxfload.c
Original file line number Diff line number Diff line change
Expand Up @@ -297,11 +297,15 @@ acpi_status acpi_load_table(struct acpi_table_header *table)
status = acpi_tb_install_and_load_table(ACPI_PTR_TO_PHYSADDR(table),
ACPI_TABLE_ORIGIN_EXTERNAL_VIRTUAL,
FALSE, &table_index);
if (ACPI_SUCCESS(status)) {

/* Complete the initialization/resolution of new objects */
if (ACPI_SUCCESS(status)) {
/* Complete the initialization/resolution of package objects */

acpi_ns_initialize_objects();
status = acpi_ns_walk_namespace(ACPI_TYPE_PACKAGE,
ACPI_ROOT_OBJECT,
ACPI_UINT32_MAX, 0,
acpi_ns_init_one_package,
NULL, NULL, NULL);
}

return_ACPI_STATUS(status);
Expand Down

0 comments on commit 6cf7fb5

Please sign in to comment.