diff options
author | Wei Yongjun <weiyj.lk@gmail.com> | 2016-08-12 18:43:54 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-08-15 07:23:42 +0300 |
commit | b22ae0b4d9669495158a7fa0fd027bd0fcd8896e (patch) | |
tree | 90388a04cfc7b09170afd823a7912c0c0dc22111 /drivers/net/ethernet | |
parent | 02ee9b18dedf1d72afa0fbfb0d7c15f6b4904a07 (diff) | |
download | linux-b22ae0b4d9669495158a7fa0fd027bd0fcd8896e.tar.xz |
net: macb: add missing free_netdev() on error in macb_probe()
Add the missing free_netdev() before return from function macb_probe()
in the platform_get_irq() error handling case.
Fixes: c69618b3e4f2 ("net/macb: fix probe sequence to setup clocks earlier")
Signed-off-by: Wei Yongjun <weiyj.lk@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r-- | drivers/net/ethernet/cadence/macb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/ethernet/cadence/macb.c index 6b797e301e3f..dbce938e7d0c 100644 --- a/drivers/net/ethernet/cadence/macb.c +++ b/drivers/net/ethernet/cadence/macb.c @@ -2985,7 +2985,7 @@ static int macb_probe(struct platform_device *pdev) dev->irq = platform_get_irq(pdev, 0); if (dev->irq < 0) { err = dev->irq; - goto err_disable_clocks; + goto err_out_free_netdev; } mac = of_get_mac_address(np); |