lkml.org 
[lkml]   [2016]   [Mar]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 1/1] ACPI / property: fix data node parsing in acpi_get_next_subnode
Date
When an ACPI node has both ACPI device nodes and ACPI data nodes,
acpi_get_next_subnode will return the ACPI data nodes of its last
parsed child.

Make sure that the acpi device that is parsed is the original acpi
node and not any of its children.

Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>
---
drivers/acpi/property.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/acpi/property.c b/drivers/acpi/property.c
index 2aee416..f2fd3fe 100644
--- a/drivers/acpi/property.c
+++ b/drivers/acpi/property.c
@@ -816,6 +816,7 @@ struct fwnode_handle *acpi_get_next_subnode(struct device *dev,
next = adev->node.next;
if (next == head) {
child = NULL;
+ adev = ACPI_COMPANION(dev);
goto nondev;
}
adev = list_entry(next, struct acpi_device, node);
--
1.9.1
\
 
 \ /
  Last update: 2016-03-13 02:21    [W:2.612 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site