aboutsummaryrefslogtreecommitdiff
path: root/drivers/of/of_private.h
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@linaro.org>2014-11-17 22:31:32 +0000
committerMark Brown <broonie@kernel.org>2015-02-20 23:41:28 +0900
commit70d66c2202486ba7ab43d47867e248834902bbc1 (patch)
tree681d6ba8712c52af25ff34a226a8bd4b30c3a155 /drivers/of/of_private.h
parent8e13f7dacf243610e4478d82479f85b97d5c923f (diff)
of: Refactor __of_node_alloc() into __of_node_dup()
Add a node argument to __of_node_alloc() and rename it to __of_node_dup() so that it can also be used to duplicate a node with its properties. This is important for the overlay code so that it can create new nodes without using separate changeset items for every single property. At the same time rework the overlay code to use the new function and drop the extra changeset items. Signed-off-by: Grant Likely <grant.likely@linaro.org> (cherry picked from commit e51795815ef1a7adc018cbaf05aac46e3d24eda8) Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/of/of_private.h')
-rw-r--r--drivers/of/of_private.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/of/of_private.h b/drivers/of/of_private.h
index 618abcad307e..8e882e706cd8 100644
--- a/drivers/of/of_private.h
+++ b/drivers/of/of_private.h
@@ -61,7 +61,7 @@ static inline int of_property_notify(int action, struct device_node *np,
* own the devtree lock or work on detached trees only.
*/
struct property *__of_prop_dup(const struct property *prop, gfp_t allocflags);
-__printf(1, 2) struct device_node *__of_node_alloc(const char *fmt, ...);
+__printf(2, 3) struct device_node *__of_node_dup(const struct device_node *np, const char *fmt, ...);
extern const void *__of_get_property(const struct device_node *np,
const char *name, int *lenp);