mirror of
https://github.com/torvalds/linux.git
synced 2024-11-18 10:01:43 +00:00
ethernet: apm: xgene: add missing of_node_put after calling of_parse_phandle
of_node_put needs to be called when the device node which is got from of_parse_phandle has finished using. Signed-off-by: Peter Chen <peter.chen@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
5d97222ae0
commit
9c52de036b
@ -772,6 +772,7 @@ int xgene_enet_phy_connect(struct net_device *ndev)
|
||||
|
||||
phy_dev = of_phy_connect(ndev, np, &xgene_enet_adjust_link,
|
||||
0, pdata->phy_mode);
|
||||
of_node_put(np);
|
||||
if (!phy_dev) {
|
||||
netdev_err(ndev, "Could not connect to PHY\n");
|
||||
return -ENODEV;
|
||||
|
Loading…
Reference in New Issue
Block a user