net: xilinx: fix memleak
PATCH 1/1 net: xilinx: fix memleak
decrease device_node refcount np1 in err case.
Signed-off-by Libo Chen <[email protected]>
--- drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c +1 -0
@@ -175,6 +175,7 @@ int axienet_mdio_setup(struct axienet_local *lp, struct device_node *np)printk (KERN_WARNING "Setting MDIO clock divisor to " "default %d\n" ,DEFAULT_CLOCK_DIVISOR ); clk_div =DEFAULT_CLOCK_DIVISOR ; +of_node_put (np1); goto issue; }
Signature · 1 line
1.7.1
From: Libo Chen <[email protected]>
Date: Mon, 26 Aug 2013 11:30:55 +0800
Quoted 4 lines
decrease
device_noderefcount np1 in err case.Signed-off-by Libo Chen <[email protected]>
Applied, thank you.