All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sakari Ailus <sakari.ailus@linux.intel.com>
To: linux-acpi@vger.kernel.org
Cc: "Rafael J. Wysocki" <rafael@kernel.org>,
	Len Brown <lenb@kernel.org>,
	Mika Westerberg <mika.westerberg@linux.intel.com>,
	Rob Herring <robh@kernel.org>,
	andriy.shevchenko@linux.intel.com
Subject: [PATCH 1/1] ACPI: property: Consider data nodes as being available
Date: Wed, 18 Dec 2024 11:16:22 +0200	[thread overview]
Message-ID: <20241218091622.914266-1-sakari.ailus@linux.intel.com> (raw)

Years after fwnode_device_is_available() was introduced, new functions
making use of the function on data nodes have been added, such as
fwnode_for_each_available_child_node(), it becomes apparent that returning
"false" for all child nodes on ACPI wasn't a workable option.

On DT side most access functions, even those without "_available" part,
did only operate on available nodes. That wasn't the case on ACPI where
only device node availability is known explicitly.

Thus from now on, return true from fwnode_device_is_available() on all
ACPI data nodes.

Fixes: 2294b3af05e9 ("device property: Introduce fwnode_device_is_available()")
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
 drivers/acpi/property.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

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));
 }

base-commit: 7fa366f1b6e376c38966faa42da7f0f2e013fdab
-- 
2.39.5


             reply	other threads:[~2024-12-18  9:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-18  9:16 Sakari Ailus [this message]
2024-12-18 11:07 ` [PATCH 1/1] ACPI: property: Consider data nodes as being available Rafael J. Wysocki
2024-12-19 10:32   ` Sakari Ailus
2024-12-19 11:25     ` Rafael J. Wysocki
2024-12-19 13:37       ` Sakari Ailus
2024-12-19 14:09         ` Rafael J. Wysocki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241218091622.914266-1-sakari.ailus@linux.intel.com \
    --to=sakari.ailus@linux.intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    --cc=rafael@kernel.org \
    --cc=robh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.