Skip to content

Commit

Permalink
ACPICA: Fix a regression for deletion of Alias() objects.
Browse files Browse the repository at this point in the history
Fixes a regression introduced by commit e23d9b8 (ACPICA:
Namespace: Properly null terminate objects detached from a namespace
node)

In the case of Alias namespace nodes, the node simply points to the aliased
node via the Object field; thus we cannot assume that the object is an
operand object.

Fixes: e23d9b8 (ACPICA: Namespace: Properly null terminate objects detached from a namespace node)
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>
  • Loading branch information
Bob Moore authored and Rafael J. Wysocki committed Jul 9, 2014
1 parent 587fc72 commit 7817e26
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions drivers/acpi/acpica/nsobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -237,17 +237,16 @@ void acpi_ns_detach_object(struct acpi_namespace_node *node)
(node->object->common.type != ACPI_TYPE_LOCAL_DATA)) {
node->object = node->object->common.next_object;
}
}

/*
* Detach the object from any data objects (which are still held by
* the namespace node)
*/

if (obj_desc->common.next_object &&
((obj_desc->common.next_object)->common.type ==
ACPI_TYPE_LOCAL_DATA)) {
obj_desc->common.next_object = NULL;
/*
* Detach the object from any data objects (which are still held by
* the namespace node)
*/
if (obj_desc->common.next_object &&
((obj_desc->common.next_object)->common.type ==
ACPI_TYPE_LOCAL_DATA)) {
obj_desc->common.next_object = NULL;
}
}

/* Reset the node type to untyped */
Expand Down

0 comments on commit 7817e26

Please sign in to comment.