diff options
Diffstat (limited to 'include/linux/of.h')
-rw-r--r-- | include/linux/of.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/linux/of.h b/include/linux/of.h index b3d0f6d86e3b..bd45be5bd565 100644 --- a/include/linux/of.h +++ b/include/linux/of.h | |||
@@ -18,7 +18,7 @@ | |||
18 | #include <linux/types.h> | 18 | #include <linux/types.h> |
19 | #include <linux/bitops.h> | 19 | #include <linux/bitops.h> |
20 | #include <linux/errno.h> | 20 | #include <linux/errno.h> |
21 | #include <linux/kref.h> | 21 | #include <linux/kobject.h> |
22 | #include <linux/mod_devicetable.h> | 22 | #include <linux/mod_devicetable.h> |
23 | #include <linux/spinlock.h> | 23 | #include <linux/spinlock.h> |
24 | #include <linux/topology.h> | 24 | #include <linux/topology.h> |
@@ -37,6 +37,7 @@ struct property { | |||
37 | struct property *next; | 37 | struct property *next; |
38 | unsigned long _flags; | 38 | unsigned long _flags; |
39 | unsigned int unique_id; | 39 | unsigned int unique_id; |
40 | struct bin_attribute attr; | ||
40 | }; | 41 | }; |
41 | 42 | ||
42 | #if defined(CONFIG_SPARC) | 43 | #if defined(CONFIG_SPARC) |
@@ -57,7 +58,7 @@ struct device_node { | |||
57 | struct device_node *next; /* next device of same type */ | 58 | struct device_node *next; /* next device of same type */ |
58 | struct device_node *allnext; /* next in list of all nodes */ | 59 | struct device_node *allnext; /* next in list of all nodes */ |
59 | struct proc_dir_entry *pde; /* this node's proc directory */ | 60 | struct proc_dir_entry *pde; /* this node's proc directory */ |
60 | struct kref kref; | 61 | struct kobject kobj; |
61 | unsigned long _flags; | 62 | unsigned long _flags; |
62 | void *data; | 63 | void *data; |
63 | #if defined(CONFIG_SPARC) | 64 | #if defined(CONFIG_SPARC) |
@@ -74,6 +75,8 @@ struct of_phandle_args { | |||
74 | uint32_t args[MAX_PHANDLE_ARGS]; | 75 | uint32_t args[MAX_PHANDLE_ARGS]; |
75 | }; | 76 | }; |
76 | 77 | ||
78 | extern int of_node_add(struct device_node *node); | ||
79 | |||
77 | #ifdef CONFIG_OF_DYNAMIC | 80 | #ifdef CONFIG_OF_DYNAMIC |
78 | extern struct device_node *of_node_get(struct device_node *node); | 81 | extern struct device_node *of_node_get(struct device_node *node); |
79 | extern void of_node_put(struct device_node *node); | 82 | extern void of_node_put(struct device_node *node); |
@@ -187,6 +190,8 @@ static inline const char *of_node_full_name(const struct device_node *np) | |||
187 | return np ? np->full_name : "<no-node>"; | 190 | return np ? np->full_name : "<no-node>"; |
188 | } | 191 | } |
189 | 192 | ||
193 | #define for_each_of_allnodes(dn) \ | ||
194 | for (dn = of_allnodes; dn; dn = dn->allnext) | ||
190 | extern struct device_node *of_find_node_by_name(struct device_node *from, | 195 | extern struct device_node *of_find_node_by_name(struct device_node *from, |
191 | const char *name); | 196 | const char *name); |
192 | extern struct device_node *of_find_node_by_type(struct device_node *from, | 197 | extern struct device_node *of_find_node_by_type(struct device_node *from, |