summaryrefslogtreecommitdiffstats
path: root/commands/miitool.c
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2020-03-11 14:19:07 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2020-03-31 12:34:40 +0200
commit13815aa7abd26269ba8031f8b62ad8e4d450d469 (patch)
treeff9ce2e5d76375aeb92687cc95ced429846492a8 /commands/miitool.c
parentaf591784b21eec496a843239700c45a41b914571 (diff)
downloadbarebox-13815aa7abd26269ba8031f8b62ad8e4d450d469.tar.gz
barebox-13815aa7abd26269ba8031f8b62ad8e4d450d469.tar.xz
miitool: Use mdiobus_read()
We have mdiobus_read(), so use it rather than accessing the read hook directly. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'commands/miitool.c')
-rw-r--r--commands/miitool.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/commands/miitool.c b/commands/miitool.c
index a87d567ace..07437d28a8 100644
--- a/commands/miitool.c
+++ b/commands/miitool.c
@@ -110,10 +110,10 @@ static int show_basic_mii(struct mii_bus *mii, struct phy_device *phydev,
/* Some bits in the BMSR are latched, but we can't rely on being
the only reader, so only the current values are meaningful */
- mii->read(mii, phydev->addr, MII_BMSR);
+ mdiobus_read(mii, phydev->addr, MII_BMSR);
for (i = 0; i < 32; i++)
- mii_val[i] = mii->read(mii, phydev->addr, i);
+ mii_val[i] = mdiobus_read(mii, phydev->addr, i);
printf((mii->parent->id) < 0 ? "%s: %s: " : "%s: %s%d: ",
phydev->cdev.name, mii->parent->name, mii->parent->id);