[PATCH] clk: Convert to using %pOFn instead of device_node.name

From
Rob Herring <robh@kernel.org>
Date
2018-09-07 15:08:32
Also in
linux-clk, linux-omap, linux-renesas-soc, lkml
Reply to
Rob Herring, 2018-08-28
On Mon, Aug 27, 2018 at 8:53 PM Rob Herring [off-list ref] wrote:
In preparation to remove the node name pointer from struct device_node,
convert printf users to use the %pOFn format specifier.
quoted hunk ↗ jump to hunk
@@ -492,8 +492,7 @@ static void __init _ti_omap4_clkctrl_setup(struct device_node *node)

        provider->base = of_iomap(node, 0);

-       provider->clkdm_name = kmalloc(strlen(node->parent->name) + 3,
-                                      GFP_KERNEL);
+       provider->clkdm_name = kasprintf(GFP_KERNEL, "%pOFnxxx", node->parent);
Turns out xxx was a bad choice as the %p handler eats all alphanumeric
characters. Looks like this has already been applied, so I will send a
fix.

Rob
Thread (60 messages) 60 messages, 30 authors, last reply 2018-10-01
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help