diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2019-10-17 08:10:24 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2019-10-17 08:10:24 +0200 |
commit | 854cdfbe265ebd99619bc6edc594d59b07c156fe (patch) | |
tree | 072c0cab0db0e2b703db22add9608d16e8712140 /include/of.h | |
parent | 54709a8e5ed1e1d6c07bc24321aede08f27a1d58 (diff) | |
parent | 27112f5b5541d736a560dbc9f059d879d4b354a3 (diff) | |
download | barebox-854cdfbe265ebd99619bc6edc594d59b07c156fe.tar.gz |
Merge branch 'for-next/of-overlay'
Diffstat (limited to 'include/of.h')
-rw-r--r-- | include/of.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/include/of.h b/include/of.h index c8275e169b..98ddf795cb 100644 --- a/include/of.h +++ b/include/of.h @@ -871,4 +871,51 @@ static inline struct device_node *of_find_root_node(struct device_node *node) return node; } + +#ifdef CONFIG_OF_OVERLAY +struct device_node *of_resolve_phandles(struct device_node *root, + const struct device_node *overlay); +int of_overlay_apply_tree(struct device_node *root, + struct device_node *overlay); +int of_register_overlay(struct device_node *overlay); +int of_process_overlay(struct device_node *root, + struct device_node *overlay, + int (*process)(struct device_node *target, + struct device_node *overlay, void *data), + void *data); + +int of_firmware_load_overlay(struct device_node *overlay, const char *path); +#else +static inline struct device_node *of_resolve_phandles(struct device_node *root, + const struct device_node *overlay) +{ + return NULL; +} + +static inline int of_overlay_apply_tree(struct device_node *root, + struct device_node *overlay) +{ + return -ENOSYS; +} + +static inline int of_register_overlay(struct device_node *overlay) +{ + return -ENOSYS; +} + +static inline int of_process_overlay(struct device_node *root, + struct device_node *overlay, + int (*process)(struct device_node *target, + struct device_node *overlay, void *data), + void *data) +{ + return -ENOSYS; +} + +static inline int of_firmware_load_overlay(struct device_node *overlay, const char *path) +{ + return -ENOSYS; +} +#endif + #endif /* __OF_H */ |