net: dsa: mt7530: add missing of_node_put() in mt7530_setup()
authorYang Yingliang <yangyingliang@huawei.com>
Thu, 28 Apr 2022 09:53:17 +0000 (17:53 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 May 2022 10:30:16 +0000 (12:30 +0200)
commit8c703731e7d57cbaef7d33af8b30ab577c2af8f6
tree12a8c0a3bad9cf80b7ea610e65e58135855a9388
parentbd7e519ff79ae8c4def32bd2edc3ddce2884e212
net: dsa: mt7530: add missing of_node_put() in mt7530_setup()

commit a9e9b091a1c14ecd8bd9d3214a62142a1786fe30 upstream.

Add of_node_put() if of_get_phy_mode() fails in mt7530_setup()

Fixes: 0c65b2b90d13 ("net: of_get_phy_mode: Change API to solve int/unit warnings")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Link: https://lore.kernel.org/r/20220428095317.538829-1-yangyingliang@huawei.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/dsa/mt7530.c