diff options
author | Len Brown <len.brown@intel.com> | 2005-09-03 04:09:12 (GMT) |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2005-09-03 04:10:05 (GMT) |
commit | a94f18810f52d3a6de0a09bee0c7258b62eca262 (patch) | |
tree | a1bee534fe254106cec916642ae90ebf15cec201 /drivers/acpi/parser | |
parent | 8813dfbfc56b3f7c369b3115c2f70bcacd77ec51 (diff) | |
download | linux-fsl-qoriq-a94f18810f52d3a6de0a09bee0c7258b62eca262.tar.xz |
[ACPI] revert owner-id-3.patch
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/parser')
-rw-r--r-- | drivers/acpi/parser/psparse.c | 21 | ||||
-rw-r--r-- | drivers/acpi/parser/psxface.c | 13 |
2 files changed, 28 insertions, 6 deletions
diff --git a/drivers/acpi/parser/psparse.c b/drivers/acpi/parser/psparse.c index 3677130..3248051 100644 --- a/drivers/acpi/parser/psparse.c +++ b/drivers/acpi/parser/psparse.c @@ -438,6 +438,7 @@ acpi_ps_next_parse_state(struct acpi_walk_state *walk_state, acpi_status acpi_ps_parse_aml(struct acpi_walk_state *walk_state) { acpi_status status; + acpi_status terminate_status; struct acpi_thread_state *thread; struct acpi_thread_state *prev_walk_list = acpi_gbl_current_walk_list; struct acpi_walk_state *previous_walk_state; @@ -507,9 +508,6 @@ acpi_status acpi_ps_parse_aml(struct acpi_walk_state *walk_state) walk_state->method_node, NULL, status); - /* Make sure that failed method will be cleaned as if it was executed */ - walk_state->parse_flags |= ACPI_PARSE_EXECUTE; - /* Check for possible multi-thread reentrancy problem */ if ((status == AE_ALREADY_EXISTS) && @@ -526,6 +524,14 @@ acpi_status acpi_ps_parse_aml(struct acpi_walk_state *walk_state) } } + if (walk_state->method_desc) { + /* Decrement the thread count on the method parse tree */ + + if (walk_state->method_desc->method.thread_count) { + walk_state->method_desc->method.thread_count--; + } + } + /* We are done with this walk, move on to the parent if any */ walk_state = acpi_ds_pop_walk_state(thread); @@ -540,10 +546,13 @@ acpi_status acpi_ps_parse_aml(struct acpi_walk_state *walk_state) */ if ((walk_state->parse_flags & ACPI_PARSE_MODE_MASK) == ACPI_PARSE_EXECUTE) { - if (walk_state->method_desc) { - walk_state->method_desc->method.thread_count--; + terminate_status = + acpi_ds_terminate_control_method(walk_state); + if (ACPI_FAILURE(terminate_status)) { + ACPI_REPORT_ERROR(("Could not terminate control method properly\n")); + + /* Ignore error and continue */ } - acpi_ds_terminate_control_method (walk_state); } /* Delete this walk state and all linked control states */ diff --git a/drivers/acpi/parser/psxface.c b/drivers/acpi/parser/psxface.c index f6904bd..80c67f2 100644 --- a/drivers/acpi/parser/psxface.c +++ b/drivers/acpi/parser/psxface.c @@ -99,6 +99,16 @@ acpi_status acpi_ps_execute_method(struct acpi_parameter_info *info) } /* + * Get a new owner_id for objects created by this method. Namespace + * objects (such as Operation Regions) can be created during the + * first pass parse. + */ + status = acpi_ut_allocate_owner_id(&info->obj_desc->method.owner_id); + if (ACPI_FAILURE(status)) { + return_ACPI_STATUS(status); + } + + /* * The caller "owns" the parameters, so give each one an extra * reference */ @@ -129,6 +139,9 @@ acpi_status acpi_ps_execute_method(struct acpi_parameter_info *info) status = acpi_ps_execute_pass(info); cleanup: + if (info->obj_desc->method.owner_id) { + acpi_ut_release_owner_id(&info->obj_desc->method.owner_id); + } /* Take away the extra reference that we gave the parameters above */ |