diff options
-rw-r--r-- | drivers/net/fsl_enetc.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/fsl_enetc.c b/drivers/net/fsl_enetc.c index 9b97a03ccb3..cd4c2c29a65 100644 --- a/drivers/net/fsl_enetc.c +++ b/drivers/net/fsl_enetc.c @@ -361,6 +361,9 @@ static int enetc_remove(struct udevice *dev) { struct enetc_priv *priv = dev_get_priv(dev); + if (miiphy_get_dev_by_name(priv->imdio.name)) + mdio_unregister(&priv->imdio); + free(priv->enetc_txbd); free(priv->enetc_rxbd); |