Skip to content

Commit 2ea3b19

Browse files
Sakari Ailusrafaeljw
authored andcommitted
ACPI: property: Ignore already existing data node tags
ACPI node pointers are attached to data node handles, in order to resolve string references to them. _DSD guide allows the same node to be reached from multiple parent nodes, leading the node enumeration algorithm to each such nodes more than once. As attached data already already exists, attaching data with the same tag will fail. Address this problem by ignoring nodes that have been already tagged. Fixes: 1d52f10 ("ACPI: property: Tie data nodes to acpi handles") Reported-by: Pierre-Louis Bossart <[email protected]> Signed-off-by: Sakari Ailus <[email protected]> Tested-by: Pierre-Louis Bossart <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent 0686507 commit 2ea3b19

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/acpi/property.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ static bool acpi_tie_nondev_subnodes(struct acpi_device_data *data)
370370
bool ret;
371371

372372
status = acpi_attach_data(dn->handle, acpi_nondev_subnode_tag, dn);
373-
if (ACPI_FAILURE(status)) {
373+
if (ACPI_FAILURE(status) && status != AE_ALREADY_EXISTS) {
374374
acpi_handle_err(dn->handle, "Can't tag data node\n");
375375
return false;
376376
}

0 commit comments

Comments
 (0)