net: xilinx: fix memleak
decrease device_node refcount np1 in err case. Signed-off-by: Libo Chen <libo.chen@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
03803a59e3
commit
282a1dffc1
@ -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;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user