Commit 56c9aa07 authored by Sakari Ailus's avatar Sakari Ailus Committed by Rafael J. Wysocki

software node: Make argument to to_software_node const

to_software_node() does not need to modify the fwnode_handle it operates
on; therefore make it const. This allows passing a const fwnode_handle to
to_software_node().
Signed-off-by: default avatarSakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: default avatarHeikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent 51c100a6
......@@ -71,9 +71,9 @@ software_node_to_swnode(const struct software_node *node)
return swnode;
}
const struct software_node *to_software_node(struct fwnode_handle *fwnode)
const struct software_node *to_software_node(const struct fwnode_handle *fwnode)
{
struct swnode *swnode = to_swnode(fwnode);
const struct swnode *swnode = to_swnode(fwnode);
return swnode ? swnode->node : NULL;
}
......
......@@ -418,7 +418,8 @@ struct software_node {
};
bool is_software_node(const struct fwnode_handle *fwnode);
const struct software_node *to_software_node(struct fwnode_handle *fwnode);
const struct software_node *
to_software_node(const struct fwnode_handle *fwnode);
struct fwnode_handle *software_node_fwnode(const struct software_node *node);
const struct software_node *
......
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