aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeter Chen <peter.chen@nxp.com>2016-08-01 03:02:29 -0400
committerDavid S. Miller <davem@davemloft.net>2016-08-02 00:42:57 -0400
commit5d97222ae0f578a91166804cb62dbf4a5c9202db (patch)
tree6443e62f7e914db2d06132654d1445f5bba6c66f
parent0a2f0d2de4ed9bd73e2c8d604863399ed6a20527 (diff)
ethernet: altera: add missing of_node_put
of_node_put needs to be called when the device node which is got from of_parse_phandle (or of_node_get) has finished using. Signed-off-by: Peter Chen <peter.chen@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/altera/altera_tse_main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/altera/altera_tse_main.c b/drivers/net/ethernet/altera/altera_tse_main.c
index 49025e99fb0e..bda31f308cc2 100644
--- a/drivers/net/ethernet/altera/altera_tse_main.c
+++ b/drivers/net/ethernet/altera/altera_tse_main.c
@@ -815,6 +815,7 @@ static int init_phy(struct net_device *dev)
815 phydev = of_phy_connect(dev, phynode, 815 phydev = of_phy_connect(dev, phynode,
816 &altera_tse_adjust_link, 0, priv->phy_iface); 816 &altera_tse_adjust_link, 0, priv->phy_iface);
817 } 817 }
818 of_node_put(phynode);
818 819
819 if (!phydev) { 820 if (!phydev) {
820 netdev_err(dev, "Could not find the PHY\n"); 821 netdev_err(dev, "Could not find the PHY\n");