X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Facpi%2Fnamespace%2Fnswalk.c;h=c8f6bef16ed05a1fcc3e1128162624a69041107e;hb=97bf2856c6014879bd04983a3e9dfcdac1e7fe85;hp=fcab1e784b8173072ae496e55203a92db9969b43;hpb=76828883507a47dae78837ab5dec5a5b4513c667;p=linux-2.6.git diff --git a/drivers/acpi/namespace/nswalk.c b/drivers/acpi/namespace/nswalk.c index fcab1e784..c8f6bef16 100644 --- a/drivers/acpi/namespace/nswalk.c +++ b/drivers/acpi/namespace/nswalk.c @@ -76,6 +76,7 @@ struct acpi_namespace_node *acpi_ns_get_next_node(acpi_object_type type, ACPI_FUNCTION_ENTRY(); if (!child_node) { + /* It's really the parent's _scope_ that we want */ if (parent_node->child) { @@ -92,6 +93,7 @@ struct acpi_namespace_node *acpi_ns_get_next_node(acpi_object_type type, /* If any type is OK, we are done */ if (type == ACPI_TYPE_ANY) { + /* next_node is NULL if we are at the end-of-list */ return (next_node); @@ -100,6 +102,7 @@ struct acpi_namespace_node *acpi_ns_get_next_node(acpi_object_type type, /* Must search for the node -- but within this scope only */ while (next_node) { + /* If type matches, we are done */ if (next_node->type == type) { @@ -161,7 +164,7 @@ acpi_ns_walk_namespace(acpi_object_type type, acpi_object_type child_type; u32 level; - ACPI_FUNCTION_TRACE("ns_walk_namespace"); + ACPI_FUNCTION_TRACE(ns_walk_namespace); /* Special case for the namespace Root Node */ @@ -182,6 +185,7 @@ acpi_ns_walk_namespace(acpi_object_type type, * bubbled up to (and passed) the original parent handle (start_entry) */ while (level > 0) { + /* Get the next node in this scope. Null if not found */ status = AE_OK;