diff options
Diffstat (limited to 'include/linux/of.h')
| -rw-r--r-- | include/linux/of.h | 29 |
1 files changed, 21 insertions, 8 deletions
diff --git a/include/linux/of.h b/include/linux/of.h index 72843b72a2b2..a093b2fe5dfb 100644 --- a/include/linux/of.h +++ b/include/linux/of.h | |||
| @@ -22,6 +22,7 @@ | |||
| 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> |
| 25 | #include <linux/notifier.h> | ||
| 25 | 26 | ||
| 26 | #include <asm/byteorder.h> | 27 | #include <asm/byteorder.h> |
| 27 | #include <asm/errno.h> | 28 | #include <asm/errno.h> |
| @@ -267,16 +268,28 @@ extern int of_alias_get_id(struct device_node *np, const char *stem); | |||
| 267 | 268 | ||
| 268 | extern int of_machine_is_compatible(const char *compat); | 269 | extern int of_machine_is_compatible(const char *compat); |
| 269 | 270 | ||
| 270 | extern int prom_add_property(struct device_node* np, struct property* prop); | 271 | extern int of_add_property(struct device_node *np, struct property *prop); |
| 271 | extern int prom_remove_property(struct device_node *np, struct property *prop); | 272 | extern int of_remove_property(struct device_node *np, struct property *prop); |
| 272 | extern int prom_update_property(struct device_node *np, | 273 | extern int of_update_property(struct device_node *np, struct property *newprop); |
| 273 | struct property *newprop); | ||
| 274 | 274 | ||
| 275 | #if defined(CONFIG_OF_DYNAMIC) | ||
| 276 | /* For updating the device tree at runtime */ | 275 | /* For updating the device tree at runtime */ |
| 277 | extern void of_attach_node(struct device_node *); | 276 | #define OF_RECONFIG_ATTACH_NODE 0x0001 |
| 278 | extern void of_detach_node(struct device_node *); | 277 | #define OF_RECONFIG_DETACH_NODE 0x0002 |
| 279 | #endif | 278 | #define OF_RECONFIG_ADD_PROPERTY 0x0003 |
| 279 | #define OF_RECONFIG_REMOVE_PROPERTY 0x0004 | ||
| 280 | #define OF_RECONFIG_UPDATE_PROPERTY 0x0005 | ||
| 281 | |||
| 282 | struct of_prop_reconfig { | ||
| 283 | struct device_node *dn; | ||
| 284 | struct property *prop; | ||
| 285 | }; | ||
| 286 | |||
| 287 | extern int of_reconfig_notifier_register(struct notifier_block *); | ||
| 288 | extern int of_reconfig_notifier_unregister(struct notifier_block *); | ||
| 289 | extern int of_reconfig_notify(unsigned long, void *); | ||
| 290 | |||
| 291 | extern int of_attach_node(struct device_node *); | ||
| 292 | extern int of_detach_node(struct device_node *); | ||
| 280 | 293 | ||
| 281 | #define of_match_ptr(_ptr) (_ptr) | 294 | #define of_match_ptr(_ptr) (_ptr) |
| 282 | 295 | ||
