net: ethernet: aurora: nb8800: fix fixed-link phydev leaks
authorJohan Hovold <johan@kernel.org>
Mon, 28 Nov 2016 18:24:57 +0000 (19:24 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 30 Nov 2016 04:17:02 +0000 (23:17 -0500)
commit9e081031303834bf86d8cfeccd44df09b2c21377
tree4203d82ccc1b5c619c8ed4082343d4f3fd5e61da
parent5a89394ad2a5b94885bdbbb611518b0cc70bf354
net: ethernet: aurora: nb8800: 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: c7dfe3abf40e ("net: ethernet: nb8800: support fixed-link DT
node")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/aurora/nb8800.c