summaryrefslogtreecommitdiff
path: root/drivers/acpi
diff options
context:
space:
mode:
authorSakari Ailus <sakari.ailus@linux.intel.com>2024-12-19 17:21:48 +0200
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2024-12-19 21:04:42 +0100
commit17159601d2ec40b849d3f12713eb6f92093b6748 (patch)
treef030a9803c5f06e74edbe733957d2a3312958941 /drivers/acpi
parent78d4f34e2115b517bcbfe7ec0d018bbbb6f9b0b8 (diff)
downloadlinux-17159601d2ec40b849d3f12713eb6f92093b6748.tar.gz
linux-17159601d2ec40b849d3f12713eb6f92093b6748.tar.bz2
linux-17159601d2ec40b849d3f12713eb6f92093b6748.zip
ACPI: property: Consider data nodes as being available
New functions making use of the data node availability information, like fwnode_for_each_available_child_node(), have been added years after fwnode_device_is_available() was introduced. To enumerate the data nodes in various ways specific to those functions, the node availability test needs to pass. On ACPI, there is no explicit data node availbility information in the first place and the original fwnode_device_is_available() implementation simply returns false. This causes new functions that only enumerate available nodes to never return any nodes on ACPI for leaf devices that have child data nodes. However, on the DT side, fwnode_device_is_available() returns true for all nodes without the "status" property which are analogous to the ACPI data nodes, so there is a difference in behavior between DT and ACPI in that respect. Thus from now on, return true from fwnode_device_is_available() on all ACPI data nodes. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Link: https://patch.msgid.link/20241219152148.975622-1-sakari.ailus@linux.intel.com Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r--drivers/acpi/property.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/acpi/property.c b/drivers/acpi/property.c
index 80a52a4e66dd..1ee81e771ae6 100644
--- a/drivers/acpi/property.c
+++ b/drivers/acpi/property.c
@@ -1492,7 +1492,7 @@ acpi_graph_get_remote_endpoint(const struct fwnode_handle *__fwnode)
static bool acpi_fwnode_device_is_available(const struct fwnode_handle *fwnode)
{
if (!is_acpi_device_node(fwnode))
- return false;
+ return true;
return acpi_device_is_present(to_acpi_device_node(fwnode));
}