forked from Minki/linux
net: fsl/fman: fix fixed-link-phydev reference leak
Make sure to drop the reference taken by of_phy_find_device() when
looking up a fixed-link phydev during probe.
Fixes: 57ba4c9b56
("fsl/fman: Add FMan MAC support")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
9668303403
commit
cb1f3410ff
@ -892,6 +892,8 @@ static int mac_probe(struct platform_device *_of_dev)
|
||||
priv->fixed_link->duplex = phy->duplex;
|
||||
priv->fixed_link->pause = phy->pause;
|
||||
priv->fixed_link->asym_pause = phy->asym_pause;
|
||||
|
||||
put_device(&phy->mdio.dev);
|
||||
}
|
||||
|
||||
err = mac_dev->init(mac_dev);
|
||||
|
Loading…
Reference in New Issue
Block a user