From: Segher Boessenkool Date: Fri, 20 Jul 2007 05:58:38 +0000 (+1000) Subject: [POWERPC] of_detach_node()'s device node argument cannot be const X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=34f329db54e8154cf7faf0e7c45e7c16facfbbfe;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git [POWERPC] of_detach_node()'s device node argument cannot be const ...since it modifies it (when it sets the OF_DETACHED flag). Signed-off-by: Segher Boessenkool Signed-off-by: Paul Mackerras --- diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c index bdcd23d8d8b..a38197b12d3 100644 --- a/arch/powerpc/kernel/prom.c +++ b/arch/powerpc/kernel/prom.c @@ -1218,7 +1218,7 @@ void of_attach_node(struct device_node *np) * a reference to the node. The memory associated with the node * is not freed until its refcount goes to zero. */ -void of_detach_node(const struct device_node *np) +void of_detach_node(struct device_node *np) { struct device_node *parent; diff --git a/include/asm-powerpc/prom.h b/include/asm-powerpc/prom.h index 6e391c9894c..672083787a1 100644 --- a/include/asm-powerpc/prom.h +++ b/include/asm-powerpc/prom.h @@ -139,7 +139,7 @@ extern unsigned long __init of_get_flat_dt_root(void); /* For updating the device tree at runtime */ extern void of_attach_node(struct device_node *); -extern void of_detach_node(const struct device_node *); +extern void of_detach_node(struct device_node *); /* Other Prototypes */ extern void finish_device_tree(void);