powerpc/pmac: Fix DT refcount imbalance in pmac_pic_probe_oldstyle
authorGeert Uytterhoeven <geert+renesas@glider.be>
Tue, 3 Mar 2015 10:02:15 +0000 (11:02 +0100)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 25 Mar 2015 05:53:27 +0000 (16:53 +1100)
commit8f910fd0d9d234764e89cb770940df2ece851e71
tree12484df45b71c4cea3d623e5fdaa510a5faf4cce
parent4b7d8358819da84b1272cdae29ace4680254a104
powerpc/pmac: Fix DT refcount imbalance in pmac_pic_probe_oldstyle

Internally, of_find_node_by_name() calls of_node_put() on its "from"
parameter, which must not be done on "master", as it's still in use, and
will be released manually later.  This may cause a zero kref refcount.

Call of_node_get() before to compensate for this.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/platforms/powermac/pic.c