Instead of doing another lookup, trivially access the struct mii_dev
embedded in struct bb_miiphy_bus . No functional change.

Signed-off-by: Marek Vasut <[email protected]>
---
Cc: Christian Marangi <[email protected]>
Cc: Ilias Apalodimas <[email protected]>
Cc: Jerome Forissier <[email protected]>
Cc: Jim Liu <[email protected]>
Cc: Joe Hershberger <[email protected]>
Cc: Mario Six <[email protected]>
Cc: Michal Simek <[email protected]>
Cc: Nobuhiro Iwamatsu <[email protected]>
Cc: Paul Barker <[email protected]>
Cc: Ramon Fried <[email protected]>
Cc: Simon Glass <[email protected]>
Cc: Sughosh Ganu <[email protected]>
Cc: Tom Rini <[email protected]>
Cc: [email protected]
---
V2: No change
V3: No change
---
 drivers/net/sh_eth.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/sh_eth.c b/drivers/net/sh_eth.c
index 49065ebe717..b1e35aaf291 100644
--- a/drivers/net/sh_eth.c
+++ b/drivers/net/sh_eth.c
@@ -753,7 +753,7 @@ static int sh_ether_probe(struct udevice *udev)
        if (ret < 0)
                goto err_mdio_register;
 
-       priv->bus = miiphy_get_dev_by_name(udev->name);
+       priv->bus = &bb_miiphy->mii;
 
        eth->port = CFG_SH_ETHER_USE_PORT;
        eth->port_info[eth->port].phy_addr = CFG_SH_ETHER_PHY_ADDR;
-- 
2.47.2

Reply via email to