* [PATCH v2 2/5] net: dsa: add missing dsa_switch mdiobus remove
@ 2015-10-03 14:26 Neil Armstrong
2015-10-03 20:25 ` Florian Fainelli
0 siblings, 1 reply; 2+ messages in thread
From: Neil Armstrong @ 2015-10-03 14:26 UTC (permalink / raw)
To: David S. Miller, Florian Fainelli, Guenter Roeck, vivien.didelot,
Andrew Lunn, Fabian Frederick, Pavel Nakonechny, Joe Perches,
netdev, linux-kernel, nbd, sergei.shtylyov
To prevent memory leakage on unbinding, add missing mdiobus unregister
and free calls.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
---
net/dsa/dsa.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/net/dsa/dsa.c b/net/dsa/dsa.c
index 12cec40..91918a3 100644
--- a/net/dsa/dsa.c
+++ b/net/dsa/dsa.c
@@ -424,6 +424,8 @@ static void dsa_switch_destroy(struct dsa_switch *ds)
if (ds->hwmon_dev)
hwmon_device_unregister(ds->hwmon_dev);
#endif
+ mdiobus_unregister(ds->slave_mii_bus);
+ mdiobus_free(ds->slave_mii_bus);
}
#ifdef CONFIG_PM_SLEEP
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v2 2/5] net: dsa: add missing dsa_switch mdiobus remove
2015-10-03 14:26 [PATCH v2 2/5] net: dsa: add missing dsa_switch mdiobus remove Neil Armstrong
@ 2015-10-03 20:25 ` Florian Fainelli
0 siblings, 0 replies; 2+ messages in thread
From: Florian Fainelli @ 2015-10-03 20:25 UTC (permalink / raw)
To: Neil Armstrong, David S. Miller, Guenter Roeck, vivien.didelot,
Andrew Lunn, Fabian Frederick, Pavel Nakonechny, Joe Perches,
netdev, linux-kernel, nbd, sergei.shtylyov
Le 03/10/2015 07:26, Neil Armstrong a écrit :
> To prevent memory leakage on unbinding, add missing mdiobus unregister
> and free calls.
>
> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
--
Florian
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-10-03 20:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-03 14:26 [PATCH v2 2/5] net: dsa: add missing dsa_switch mdiobus remove Neil Armstrong
2015-10-03 20:25 ` Florian Fainelli
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).