diff options
author | Shaohui Xie <Shaohui.Xie@freescale.com> | 2015-01-12 21:30:31 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-01-13 16:43:29 -0500 |
commit | e54bfe9d7e5823f8b460e8de371f695ada41a0c1 (patch) | |
tree | f963714f6d5c83bd845c2fd016e21c1c342a1759 /drivers/net/ethernet/freescale | |
parent | 0fe6de490320bfbf1b82a33d7ee49b62af5f29db (diff) |
net/fsl: fix a bug in xgmac_mdio
There is a bug in xgmac_mdio_read when clear the bit MDIO_STAT_ENC,
which '&' is missed in 'mdio_stat &= ~MDIO_STAT_ENC'.
Signed-off-by: Shaohui Xie <Shaohui.Xie@freescale.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/freescale')
-rw-r--r-- | drivers/net/ethernet/freescale/xgmac_mdio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/xgmac_mdio.c b/drivers/net/ethernet/freescale/xgmac_mdio.c index e0fc3d1115ea..a492e5006756 100644 --- a/drivers/net/ethernet/freescale/xgmac_mdio.c +++ b/drivers/net/ethernet/freescale/xgmac_mdio.c | |||
@@ -156,7 +156,7 @@ static int xgmac_mdio_read(struct mii_bus *bus, int phy_id, int regnum) | |||
156 | mdio_stat |= MDIO_STAT_ENC; | 156 | mdio_stat |= MDIO_STAT_ENC; |
157 | } else { | 157 | } else { |
158 | dev_addr = regnum & 0x1f; | 158 | dev_addr = regnum & 0x1f; |
159 | mdio_stat = ~MDIO_STAT_ENC; | 159 | mdio_stat &= ~MDIO_STAT_ENC; |
160 | } | 160 | } |
161 | 161 | ||
162 | out_be32(®s->mdio_stat, mdio_stat); | 162 | out_be32(®s->mdio_stat, mdio_stat); |