[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100520140059.GA8968@hera.kernel.org>
Date: Thu, 20 May 2010 14:00:59 +0000
From: Denis Kirjanov <dkirjanov@...a.kernel.org>
To: davem@...emloft.net
Cc: shimoda.yoshihiro@...esas.com, iwamatsu@...auri.org,
morimoto.kuninori@...esas.com, netdev@...r.kernel.org
Subject: [PATCH] sh_eth: Fix memleak in sh_mdio_release
Allocated memory for IRQs should be freed when releasing the mii_bus
Signed-off-by: Denis Kirjanov <dkirjanov@...nel.org>
---
drivers/net/sh_eth.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/net/sh_eth.c b/drivers/net/sh_eth.c
index 586ed09..501a55f 100644
--- a/drivers/net/sh_eth.c
+++ b/drivers/net/sh_eth.c
@@ -1294,6 +1294,9 @@ static int sh_mdio_release(struct net_device *ndev)
/* remove mdio bus info from net_device */
dev_set_drvdata(&ndev->dev, NULL);
+ /* free interrupts memory */
+ kfree(bus->irq);
+
/* free bitbang info */
free_mdio_bitbang(bus);
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists