Commit 93c667ca2598bd84f1bd3f2fa176af69707699fe

Authored by Guennadi Liakhovetski
Committed by Grant Likely
1 parent 1daa8a0b20

of: *node argument to of_parse_phandle_with_args should be const

The "struct device_node *" argument of of_parse_phandle_with_args() can
be const. Making this change makes it explicit that the function will
not modify a node.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
[grant.likely: Resolved conflict with previous patch modifying of_parse_phandle()]
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>

Showing 2 changed files with 2 additions and 2 deletions Side-by-side Diff

... ... @@ -1025,7 +1025,7 @@
1025 1025 * To get a device_node of the `node2' node you may call this:
1026 1026 * of_parse_phandle_with_args(node3, "list", "#list-cells", 1, &args);
1027 1027 */
1028   -int of_parse_phandle_with_args(struct device_node *np, const char *list_name,
  1028 +int of_parse_phandle_with_args(const struct device_node *np, const char *list_name,
1029 1029 const char *cells_name, int index,
1030 1030 struct of_phandle_args *out_args)
1031 1031 {
... ... @@ -273,7 +273,7 @@
273 273 extern struct device_node *of_parse_phandle(const struct device_node *np,
274 274 const char *phandle_name,
275 275 int index);
276   -extern int of_parse_phandle_with_args(struct device_node *np,
  276 +extern int of_parse_phandle_with_args(const struct device_node *np,
277 277 const char *list_name, const char *cells_name, int index,
278 278 struct of_phandle_args *out_args);
279 279