diff options
author | John Crispin <john@openwrt.org> | 2014-11-11 11:46:09 +0000 |
---|---|---|
committer | John Crispin <john@openwrt.org> | 2014-11-11 11:46:09 +0000 |
commit | e39993137628e2ea53be7822fb106d3a89db69b5 (patch) | |
tree | 07cd95955eb97055d7857c62babd072447fb77cc /target/linux/ramips/files/drivers | |
parent | 6623feb572f6f29a17fed94b8dcb0e9512aeec4d (diff) | |
download | upstream-e39993137628e2ea53be7822fb106d3a89db69b5.tar.gz upstream-e39993137628e2ea53be7822fb106d3a89db69b5.tar.bz2 upstream-e39993137628e2ea53be7822fb106d3a89db69b5.zip |
ralink: fix mdio polling of external phys if only 1 phy exists
Signed-off-by: John Crispin <blogic@openwrt.org>
SVN-Revision: 43235
Diffstat (limited to 'target/linux/ramips/files/drivers')
-rw-r--r-- | target/linux/ramips/files/drivers/net/ethernet/ralink/gsw_mt7620a.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/target/linux/ramips/files/drivers/net/ethernet/ralink/gsw_mt7620a.c b/target/linux/ramips/files/drivers/net/ethernet/ralink/gsw_mt7620a.c index e31dd29b42..c0ec939263 100644 --- a/target/linux/ramips/files/drivers/net/ethernet/ralink/gsw_mt7620a.c +++ b/target/linux/ramips/files/drivers/net/ethernet/ralink/gsw_mt7620a.c @@ -299,6 +299,9 @@ static void gsw_auto_poll(struct mt7620_gsw *gsw) msb = phy; } + if (lsb) + lsb--; + gsw_w32(gsw, PHY_AN_EN | PHY_PRE_EN | PMY_MDC_CONF(5) | (msb << 8) | lsb, ESW_PHY_POLLING); } |