diff options
author | Steve Glendinning <steve.glendinning@shawell.net> | 2012-04-30 07:56:51 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-04-30 21:52:40 -0400 |
commit | cb8722d30c20386e4d4b4bc3a2ceceacd35f818a (patch) | |
tree | 6626b7661ce460f195e60c69260b84cdc1160c8c /drivers/net/usb/smsc75xx.c | |
parent | 7bdd305e024d78cfb4f32a1badeb5562791ee5b8 (diff) | |
download | linux-stable-cb8722d30c20386e4d4b4bc3a2ceceacd35f818a.tar.gz linux-stable-cb8722d30c20386e4d4b4bc3a2ceceacd35f818a.tar.bz2 linux-stable-cb8722d30c20386e4d4b4bc3a2ceceacd35f818a.zip |
smsc75xx: fix mdio reads and writes
smsc75xx needs MII_ACCESS_BUSY to be set to correctly trigger mdio I/O. Note smsc75xx is different from smsc95xx in this regard.
Signed-off-by: Stephane Fillod <fillods@users.sf.net>
Signed-off-by: Steve Glendinning <steve.glendinning@shawell.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/usb/smsc75xx.c')
-rw-r--r-- | drivers/net/usb/smsc75xx.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/usb/smsc75xx.c b/drivers/net/usb/smsc75xx.c index b1b4649802aa..f97207a709d6 100644 --- a/drivers/net/usb/smsc75xx.c +++ b/drivers/net/usb/smsc75xx.c @@ -171,7 +171,7 @@ static int smsc75xx_mdio_read(struct net_device *netdev, int phy_id, int idx) idx &= dev->mii.reg_num_mask; addr = ((phy_id << MII_ACCESS_PHY_ADDR_SHIFT) & MII_ACCESS_PHY_ADDR) | ((idx << MII_ACCESS_REG_ADDR_SHIFT) & MII_ACCESS_REG_ADDR) - | MII_ACCESS_READ; + | MII_ACCESS_READ | MII_ACCESS_BUSY; ret = smsc75xx_write_reg(dev, MII_ACCESS, addr); check_warn_goto_done(ret, "Error writing MII_ACCESS"); @@ -210,7 +210,7 @@ static void smsc75xx_mdio_write(struct net_device *netdev, int phy_id, int idx, idx &= dev->mii.reg_num_mask; addr = ((phy_id << MII_ACCESS_PHY_ADDR_SHIFT) & MII_ACCESS_PHY_ADDR) | ((idx << MII_ACCESS_REG_ADDR_SHIFT) & MII_ACCESS_REG_ADDR) - | MII_ACCESS_WRITE; + | MII_ACCESS_WRITE | MII_ACCESS_BUSY; ret = smsc75xx_write_reg(dev, MII_ACCESS, addr); check_warn_goto_done(ret, "Error writing MII_ACCESS"); |