aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2009-10-30 12:26:17 +0000
committerGabor Juhos <juhosg@openwrt.org>2009-10-30 12:26:17 +0000
commit24d9dfb98ccfe002ee0d3e3c719b852398cce0d3 (patch)
tree2a3337fda88534d059e19092073c178d07cad7e1 /target/linux
parent50e10559870f0f18803f022c28d8934857906770 (diff)
downloadupstream-24d9dfb98ccfe002ee0d3e3c719b852398cce0d3.tar.gz
upstream-24d9dfb98ccfe002ee0d3e3c719b852398cce0d3.tar.bz2
upstream-24d9dfb98ccfe002ee0d3e3c719b852398cce0d3.zip
ar71xx: update mdio_reset code
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@18224 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux')
-rw-r--r--target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx_mdio.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx_mdio.c b/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx_mdio.c
index 72f732d54f..d3cbacedb2 100644
--- a/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx_mdio.c
+++ b/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx_mdio.c
@@ -104,11 +104,14 @@ static void ag71xx_mdio_mii_write(struct ag71xx_mdio *am,
static int ag71xx_mdio_reset(struct mii_bus *bus)
{
struct ag71xx_mdio *am = bus->priv;
+ u32 t;
- ag71xx_mdio_wr(am, AG71XX_REG_MII_CFG, MII_CFG_RESET);
+ t = MII_CFG_CLK_DIV_28;
+
+ ag71xx_mdio_wr(am, AG71XX_REG_MII_CFG, t | MII_CFG_RESET);
udelay(100);
- ag71xx_mdio_wr(am, AG71XX_REG_MII_CFG, MII_CFG_CLK_DIV_28);
+ ag71xx_mdio_wr(am, AG71XX_REG_MII_CFG, t);
udelay(100);
return 0;