]> git.baikalelectronics.ru Git - kernel.git/commit
ethernet: Fix error handling in xemaclite_of_probe
authorMiaoqian Lin <linmq006@gmail.com>
Tue, 8 Mar 2022 02:47:49 +0000 (02:47 +0000)
committerJakub Kicinski <kuba@kernel.org>
Wed, 9 Mar 2022 06:15:01 +0000 (22:15 -0800)
commit923ceed0e3cdf6b744e4553608f85ce1e84f524e
tree429c090cadaf6c5d2955e921a98d674e3118214f
parentb523b1b24e87fc15be80e07072dc77885d2a7bca
ethernet: Fix error handling in xemaclite_of_probe

This node pointer is returned by of_parse_phandle() with refcount
incremented in this function. Calling of_node_put() to avoid the
refcount leak. As the remove function do.

Fixes: ff0e09f57d7c ("net: emaclite: adding MDIO and phy lib support")
Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20220308024751.2320-1-linmq006@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/xilinx/xilinx_emaclite.c