]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
software node: allow referencing firmware nodes
authorBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Thu, 20 Nov 2025 13:23:58 +0000 (14:23 +0100)
committerPhilipp Zabel <p.zabel@pengutronix.de>
Thu, 20 Nov 2025 15:51:48 +0000 (16:51 +0100)
commitd7cdbbc93c564902169e854e78716a7b5e6cb241
tree4fe23b68b8d668f70354db115bac51c315fe93f2
parent0651933c117e778e6f71183a52a57f4216c56efb
software node: allow referencing firmware nodes

At the moment software nodes can only reference other software nodes.
This is a limitation for devices created, for instance, on the auxiliary
bus with a dynamic software node attached which cannot reference devices
the firmware node of which is "real" (as an OF node or otherwise).

Make it possible for a software node to reference all firmware nodes in
addition to static software nodes. To that end: add a second pointer to
struct software_node_ref_args of type struct fwnode_handle. The core
swnode code will first check the swnode pointer and if it's NULL, it
will assume the fwnode pointer should be set.

Software node graphs remain the same, as in: the remote endpoints still
have to be software nodes.

Acked-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Tested-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
drivers/base/swnode.c
include/linux/property.h