lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250924100654.GO28073@pendragon.ideasonboard.com>
Date: Wed, 24 Sep 2025 13:06:54 +0300
From: Laurent Pinchart <laurent.pinchart@...asonboard.com>
To: Sakari Ailus <sakari.ailus@...ux.intel.com>
Cc: linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org,
	linux-input@...r.kernel.org, linux-leds@...r.kernel.org,
	linux-media@...r.kernel.org, netdev@...r.kernel.org,
	linux-spi@...r.kernel.org, "Rafael J. Wysocki" <rafael@...nel.org>,
	Len Brown <lenb@...nel.org>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Danilo Krummrich <dakr@...nel.org>,
	Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
	Daniel Scally <djrscally@...il.com>,
	Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
	Javier Carrasco <javier.carrasco@...fvision.net>,
	Dmitry Torokhov <dmitry.torokhov@...il.com>,
	Lee Jones <lee@...nel.org>, Pavel Machek <pavel@...nel.org>,
	Matthias Fend <matthias.fend@...end.at>,
	Chanwoo Choi <cw00.choi@...sung.com>,
	Krzysztof Kozlowski <krzk@...nel.org>,
	Paul Elder <paul.elder@...asonboard.com>,
	Mauro Carvalho Chehab <mchehab@...nel.org>,
	Horatiu Vultur <horatiu.vultur@...rochip.com>,
	UNGLinuxDriver@...rochip.com, Andrew Lunn <andrew+netdev@...n.ch>,
	"David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	Mark Brown <broonie@...nel.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	Ingo Molnar <mingo@...nel.org>,
	Jonathan Cameron <Jonathan.Cameron@...wei.com>
Subject: Re: [PATCH v2 08/16] property: Document that fwnode API returns
 available nodes

Hi Sakari,

On Wed, Sep 24, 2025 at 10:45:54AM +0300, Sakari Ailus wrote:
> The fwnode API has historically provided two functions to iterate over a
> fwnode's child nodes, fwnode_get_next_child_node() and
> fwnode_get_next_available_child_node() whereas all of the fwnode API has
> always worked on available nodes, apart unavailable ACPI child device
> nodes could have been returned by fwnode_get_next_child_node().
> 
> Now that the availability check has been added to ACPI side as well,
> document that the functions in the fwnode API return available nodes.
> 
> Signed-off-by: Sakari Ailus <sakari.ailus@...ux.intel.com>
> Reviewed-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> ---
>  drivers/base/property.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/base/property.c b/drivers/base/property.c
> index 4bd64e729431..ff440456af7b 100644
> --- a/drivers/base/property.c
> +++ b/drivers/base/property.c
> @@ -785,7 +785,7 @@ struct fwnode_handle *fwnode_get_nth_parent(struct fwnode_handle *fwnode,
>  EXPORT_SYMBOL_GPL(fwnode_get_nth_parent);
>  
>  /**
> - * fwnode_get_next_child_node - Return the next child node handle for a node
> + * fwnode_get_next_child_node - Return the next available child node handle
>   * @fwnode: Firmware node to find the next child node for.
>   * @child: Handle to one of the node's child nodes or a %NULL handle.
>   *
> @@ -830,7 +830,7 @@ fwnode_get_next_available_child_node(const struct fwnode_handle *fwnode,
>  EXPORT_SYMBOL_GPL(fwnode_get_next_available_child_node);
>  
>  /**
> - * device_get_next_child_node - Return the next child node handle for a device
> + * device_get_next_child_node - Return the next available child node handle for a device

You may want to drop "for a device" at the end of the line, it seems
you've made that change in 15/16 instead of here.

Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@...asonboard.com>

>   * @dev: Device to find the next child node for.
>   * @child: Handle to one of the device's child nodes or a %NULL handle.
>   *
> @@ -858,7 +858,7 @@ struct fwnode_handle *device_get_next_child_node(const struct device *dev,
>  EXPORT_SYMBOL_GPL(device_get_next_child_node);
>  
>  /**
> - * fwnode_get_named_child_node - Return first matching named child node handle
> + * fwnode_get_named_child_node - Return first available matching named child node handle
>   * @fwnode: Firmware node to find the named child node for.
>   * @childname: String to match child node name against.
>   *
> @@ -874,7 +874,7 @@ fwnode_get_named_child_node(const struct fwnode_handle *fwnode,
>  EXPORT_SYMBOL_GPL(fwnode_get_named_child_node);
>  
>  /**
> - * device_get_named_child_node - Return first matching named child node handle
> + * device_get_named_child_node - Return first available matching named child node handle for a device
>   * @dev: Device to find the named child node for.
>   * @childname: String to match child node name against.
>   *
> @@ -928,7 +928,7 @@ bool fwnode_device_is_available(const struct fwnode_handle *fwnode)
>  EXPORT_SYMBOL_GPL(fwnode_device_is_available);
>  
>  /**
> - * fwnode_get_child_node_count - return the number of child nodes for a given firmware node
> + * fwnode_get_child_node_count - Return the number of available child nodes for a given firmware node
>   * @fwnode: Pointer to the parent firmware node
>   *
>   * Return: the number of child nodes for a given firmware node.
> @@ -946,7 +946,7 @@ unsigned int fwnode_get_child_node_count(const struct fwnode_handle *fwnode)
>  EXPORT_SYMBOL_GPL(fwnode_get_child_node_count);
>  
>  /**
> - * fwnode_get_named_child_node_count - number of child nodes with given name
> + * fwnode_get_named_child_node_count - Return the number of available child nodes with given name
>   * @fwnode: Node which child nodes are counted.
>   * @name: String to match child node name against.
>   *

-- 
Regards,

Laurent Pinchart

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ