leds: 88pm860x: Fix missing refcount decrement for parent of_node
authorKrzysztof Kozlowski <k.kozlowski@samsung.com>
Fri, 4 Apr 2014 07:51:20 +0000 (00:51 -0700)
committerBryan Wu <cooloney@gmail.com>
Thu, 8 May 2014 06:28:08 +0000 (14:28 +0800)
commit1175d5bc7b490a5175c955b4e656f42577a43ecf
treefcc5dbd67343493161014d9aaa57a5afe30c357c
parent77dfa771677f0af57b4093c81c5fdbd1946e8bc9
leds: 88pm860x: Fix missing refcount decrement for parent of_node

The driver obtained the reference to parent->of_node but immediately it
was overwritten by reference to child node 'leds'. The of_node_put at
the end of DT parsing function decremented only the child 'leds' so
effectively the reference to parent of_node leaked.

Getting reference to parent->of_node is not needed at all so get rid of
it to fix the reference count.

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Bryan Wu <cooloney@gmail.com>
drivers/leds/leds-88pm860x.c