net-next: mediatek: use mdiobus_free() in favour of kfree()
authorJohn Crispin <john@phrozen.org>
Fri, 3 Jun 2016 08:17:06 +0000 (10:17 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 3 Jun 2016 23:54:16 +0000 (19:54 -0400)
commit207bdf1844286d2ba94523d30528f82aaf33d52b
tree179f5a55053ae8b092339cf39b69fb8aa66d109e
parent8478b6cdc10e8a7735deeb9d9e46ad5b157c84d0
net-next: mediatek: use mdiobus_free() in favour of kfree()

The driver currently uses kfree() to clear the mii_bus. This is not the
correct way to clear the memory and mdiobus_free() should be used instead.
This patch fixes the two instances where this happens in the driver.

Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: John Crispin <john@phrozen.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mediatek/mtk_eth_soc.c