===================================================================
@@ -106,6 +106,7 @@ struct acpi_namespace_node *acpi_ns_crea
void acpi_ns_delete_node(struct acpi_namespace_node *node)
{
union acpi_operand_object *obj_desc;
+ union acpi_operand_object *next_obj_desc;
ACPI_FUNCTION_NAME(ns_delete_node);
@@ -119,7 +120,8 @@ void acpi_ns_delete_node(struct acpi_nam
* detached above, the only possible remaining object is a data object.
*/
obj_desc = node->object;
- if (obj_desc && (obj_desc->common.type == ACPI_TYPE_LOCAL_DATA)) {
+ while (obj_desc && obj_desc->common.type == ACPI_TYPE_LOCAL_DATA) {
+ next_obj_desc = obj_desc->common.next_object;
/* Invoke the attached data deletion handler if present */
@@ -128,6 +130,8 @@ void acpi_ns_delete_node(struct acpi_nam
}
acpi_ut_remove_reference(obj_desc);
+
+ obj_desc = next_obj_desc;
}
/* Now we can delete the node */