aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/of.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/of.h')
-rw-r--r--include/linux/of.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/of.h b/include/linux/of.h
index 9180dc5cb00b..8b6383d876ca 100644
--- a/include/linux/of.h
+++ b/include/linux/of.h
@@ -68,6 +68,7 @@ struct device_node {
68/* Pointer for first entry in chain of all nodes. */ 68/* Pointer for first entry in chain of all nodes. */
69extern struct device_node *allnodes; 69extern struct device_node *allnodes;
70extern struct device_node *of_chosen; 70extern struct device_node *of_chosen;
71extern struct device_node *of_aliases;
71extern rwlock_t devtree_lock; 72extern rwlock_t devtree_lock;
72 73
73static inline bool of_have_populated_dt(void) 74static inline bool of_have_populated_dt(void)
@@ -209,6 +210,9 @@ extern int of_device_is_available(const struct device_node *device);
209extern const void *of_get_property(const struct device_node *node, 210extern const void *of_get_property(const struct device_node *node,
210 const char *name, 211 const char *name,
211 int *lenp); 212 int *lenp);
213#define for_each_property(pp, properties) \
214 for (pp = properties; pp != NULL; pp = pp->next)
215
212extern int of_n_addr_cells(struct device_node *np); 216extern int of_n_addr_cells(struct device_node *np);
213extern int of_n_size_cells(struct device_node *np); 217extern int of_n_size_cells(struct device_node *np);
214extern const struct of_device_id *of_match_node( 218extern const struct of_device_id *of_match_node(
@@ -221,6 +225,9 @@ extern int of_parse_phandles_with_args(struct device_node *np,
221 const char *list_name, const char *cells_name, int index, 225 const char *list_name, const char *cells_name, int index,
222 struct device_node **out_node, const void **out_args); 226 struct device_node **out_node, const void **out_args);
223 227
228extern void of_alias_scan(void * (*dt_alloc)(u64 size, u64 align));
229extern int of_alias_get_id(struct device_node *np, const char *stem);
230
224extern int of_machine_is_compatible(const char *compat); 231extern int of_machine_is_compatible(const char *compat);
225 232
226extern int prom_add_property(struct device_node* np, struct property* prop); 233extern int prom_add_property(struct device_node* np, struct property* prop);