diff options
| author | Sakari Ailus <sakari.ailus@linux.intel.com> | 2025-12-19 10:36:38 +0200 |
|---|---|---|
| committer | Danilo Krummrich <dakr@kernel.org> | 2025-12-22 13:32:22 +0100 |
| commit | 87e7f6019097746d1d06f98874a9f179b7a68f3e (patch) | |
| tree | c501f3cea9aeb870d33c5115e57a309e6658df6a /include/linux | |
| parent | d412ff9e26ebf433672ba0ff649c308b1fea2a12 (diff) | |
software node: Also support referencing non-constant software nodes
Fwnode references are be implemented differently if referenced node is a
software node. _Generic() is used to differentiate between the two cases
but only const software nodes were present in the selection. Also add
non-const software nodes.
Reported-by: Kenneth Crudup <kenny@panix.com>
Closes: https://lore.kernel.org/all/af773b82-bef2-4209-baaf-526d4661b7fc@panix.com/
Fixes: d7cdbbc93c56 ("software node: allow referencing firmware nodes")
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Tested-By: Kenneth R. Crudup <kenny@panix.com>
Tested-by: Mehdi Djait <mehdi.djait@linux.intel.com> # Dell XPS 9315
Reviewed-by: Mehdi Djait <mehdi.djait@linux.intel.com>
Link: https://patch.msgid.link/20251219083638.2454138-1-sakari.ailus@linux.intel.com
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/property.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/property.h b/include/linux/property.h index 272bfbdea7bf..e30ef23a9af3 100644 --- a/include/linux/property.h +++ b/include/linux/property.h @@ -371,6 +371,7 @@ struct software_node_ref_args { (const struct software_node_ref_args) { \ .swnode = _Generic(_ref_, \ const struct software_node *: _ref_, \ + struct software_node *: _ref_, \ default: NULL), \ .fwnode = _Generic(_ref_, \ struct fwnode_handle *: _ref_, \ |
