net: dsa: rtl8366rb: add missing of_node_put after calling of_get_child_by_name
authorWen Yang <wenyang@linux.alibaba.com>
Sun, 29 Sep 2019 07:00:47 +0000 (15:00 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 1 Oct 2019 17:02:56 +0000 (10:02 -0700)
commitf32eb9d80470dab05df26b6efd02d653c72e6a11
tree927f0b87f68a79203ed23ff93c47c67ddc8688d2
parentd2c50b1cd94528aea8c8e9abb4cce81590f32cc4
net: dsa: rtl8366rb: add missing of_node_put after calling of_get_child_by_name

of_node_put needs to be called when the device node which is got
from of_get_child_by_name finished using.
irq_domain_add_linear() also calls of_node_get() to increase refcount,
so irq_domain will not be affected when it is released.

Fixes: d8652956cf37 ("net: dsa: realtek-smi: Add Realtek SMI driver")
Signed-off-by: Wen Yang <wenyang@linux.alibaba.com>
Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Andrew Lunn <andrew@lunn.ch>
Cc: Vivien Didelot <vivien.didelot@gmail.com>
Cc: Florian Fainelli <f.fainelli@gmail.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: netdev@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/rtl8366rb.c