diff options
author | Bob Moore <robert.moore@intel.com> | 2013-08-08 15:30:05 +0800 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-08-13 13:14:16 +0200 |
commit | 4ef17507834d19ba4fc24c4c1c61e8f68df356a6 (patch) | |
tree | 979deb29c661ebabecd34d3f3fecabc9ed3c9cba /drivers/acpi/acpica/nswalk.c | |
parent | a50abf4842dd7d603a2ad6dcc7f1467fd2a66f03 (diff) | |
download | linux-4ef17507834d19ba4fc24c4c1c61e8f68df356a6.tar.gz linux-4ef17507834d19ba4fc24c4c1c61e8f68df356a6.tar.bz2 linux-4ef17507834d19ba4fc24c4c1c61e8f68df356a6.zip |
ACPICA: Update names for walk_namespace callbacks to clarify usage.
Use of "preorder" and "postorder" was incorrect. The callbacks are
simply invoked during tree ascent and descent during the
depth-first walk.
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/acpica/nswalk.c')
-rw-r--r-- | drivers/acpi/acpica/nswalk.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/drivers/acpi/acpica/nswalk.c b/drivers/acpi/acpica/nswalk.c index e70911a9e441..e81f15ef659a 100644 --- a/drivers/acpi/acpica/nswalk.c +++ b/drivers/acpi/acpica/nswalk.c @@ -156,9 +156,9 @@ struct acpi_namespace_node *acpi_ns_get_next_node_typed(acpi_object_type type, * max_depth - Depth to which search is to reach * flags - Whether to unlock the NS before invoking * the callback routine - * pre_order_visit - Called during tree pre-order visit + * descending_callback - Called during tree descent * when an object of "Type" is found - * post_order_visit - Called during tree post-order visit + * ascending_callback - Called during tree ascent * when an object of "Type" is found * context - Passed to user function(s) above * return_value - from the user_function if terminated @@ -185,8 +185,8 @@ acpi_ns_walk_namespace(acpi_object_type type, acpi_handle start_node, u32 max_depth, u32 flags, - acpi_walk_callback pre_order_visit, - acpi_walk_callback post_order_visit, + acpi_walk_callback descending_callback, + acpi_walk_callback ascending_callback, void *context, void **return_value) { acpi_status status; @@ -255,22 +255,22 @@ acpi_ns_walk_namespace(acpi_object_type type, } /* - * Invoke the user function, either pre-order or post-order + * Invoke the user function, either descending, ascending, * or both. */ if (!node_previously_visited) { - if (pre_order_visit) { + if (descending_callback) { status = - pre_order_visit(child_node, level, - context, - return_value); + descending_callback(child_node, + level, context, + return_value); } } else { - if (post_order_visit) { + if (ascending_callback) { status = - post_order_visit(child_node, level, - context, - return_value); + ascending_callback(child_node, + level, context, + return_value); } } |