Commit c5fc5ba8 authored by Clément Léger's avatar Clément Léger Committed by Rafael J. Wysocki

software node: fix wrong node passed to find nargs_prop

nargs_prop refers to a property located in the reference that is found
within the nargs property. Use the correct reference node in call to
property_entry_read_int_array() to retrieve the correct nargs value.

Fixes: b06184ac ("software node: Add software_node_get_reference_args()")
Signed-off-by: default avatarClément Léger <clement.leger@bootlin.com>
Reviewed-by: default avatarSakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: default avatarDaniel Scally <djrscally@gmail.com>
Acked-by: default avatarHeikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent c49eea6f
......@@ -529,7 +529,7 @@ software_node_get_reference_args(const struct fwnode_handle *fwnode,
return -ENOENT;
if (nargs_prop) {
error = property_entry_read_int_array(swnode->node->properties,
error = property_entry_read_int_array(ref->node->properties,
nargs_prop, sizeof(u32),
&nargs_prop_val, 1);
if (error)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment