net: ethernet: marvell: mvneta: fix fixed-link phydev leaks
authorJohan Hovold <johan@kernel.org>
Mon, 28 Nov 2016 18:25:04 +0000 (19:25 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 30 Nov 2016 04:17:02 +0000 (23:17 -0500)
commit5a57a304315c09f9f93b7b7230a5038555e7fcf9
tree93391cf1b8a62398f445aded01ad002c7e43d97a
parent0807c4ceb8d171a116edc33e34166416876cae5d
net: ethernet: marvell: mvneta: fix fixed-link phydev leaks

Make sure to deregister and free any fixed-link PHY registered using
of_phy_register_fixed_link() on probe errors and on driver unbind.

Fixes: 83895bedeee6 ("net: mvneta: add support for fixed links")
Signed-off-by: Johan Hovold <johan@kernel.org>
Reviewed-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvneta.c