]> git.itanic.dy.fi Git - linux-stable/commitdiff
powerpc/embedded6xx/ls_uart: Add missing of_node_put()
authorLiang He <windhl@126.com>
Mon, 20 Jun 2022 06:59:04 +0000 (14:59 +0800)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 5 Sep 2022 07:28:26 +0000 (17:28 +1000)
In ls_uarts_init(), add an of_node_put() to keep refcount balance.

Signed-off-by: Liang He <windhl@126.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220620065904.4071787-1-windhl@126.com
arch/powerpc/platforms/embedded6xx/ls_uart.c

index 0133e175a0fcd26c81afee1ff3b316a91eef9129..4ecbc55b37c0b96fba8fde89f39093015b45981f 100644 (file)
@@ -124,6 +124,8 @@ static int __init ls_uarts_init(void)
        avr_clock = *(u32*)of_get_property(avr, "clock-frequency", &len);
        phys_addr = ((u32*)of_get_property(avr, "reg", &len))[0];
 
+       of_node_put(avr);
+
        if (!avr_clock || !phys_addr)
                return -EINVAL;