aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic/files/drivers/net/phy/ar8327.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2015-01-24 19:41:51 +0000
committerFelix Fietkau <nbd@openwrt.org>2015-01-24 19:41:51 +0000
commitae7769af49f1e104e701ff96e51b4c3a655ba2b6 (patch)
tree84c0c90745bad8b498f05a9e5e3ce730180986c9 /target/linux/generic/files/drivers/net/phy/ar8327.c
parentf1b7de863d1b26361784b6c0f02bef3900b1239d (diff)
downloadmaster-187ad058-ae7769af49f1e104e701ff96e51b4c3a655ba2b6.tar.gz
master-187ad058-ae7769af49f1e104e701ff96e51b4c3a655ba2b6.tar.bz2
master-187ad058-ae7769af49f1e104e701ff96e51b4c3a655ba2b6.zip
ar8216: fix ATU flushing
The functionality to flush the address translation table contains two bugs which luckily compensate each other. 1. Just setting the operation is not sufficient to perform the flushing. The "active" bit needs to be set to actually trigger an action. For the vtu operations this is implemented correctly. 2. ar8xxx_phy_read_status is called every 2s by the phy state machine to check for link changes. This would have caused an ATU flush every 2s. Fix the chip-specific ATU flush functions and remove the ATU flush call from ar8xxx_phy_read_status. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@44101 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/generic/files/drivers/net/phy/ar8327.c')
-rw-r--r--target/linux/generic/files/drivers/net/phy/ar8327.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/target/linux/generic/files/drivers/net/phy/ar8327.c b/target/linux/generic/files/drivers/net/phy/ar8327.c
index ea880bc927..fd5bcdc19b 100644
--- a/target/linux/generic/files/drivers/net/phy/ar8327.c
+++ b/target/linux/generic/files/drivers/net/phy/ar8327.c
@@ -759,7 +759,8 @@ ar8327_atu_flush(struct ar8xxx_priv *priv)
AR8327_ATU_FUNC_BUSY, 0);
if (!ret)
ar8xxx_write(priv, AR8327_REG_ATU_FUNC,
- AR8327_ATU_FUNC_OP_FLUSH);
+ AR8327_ATU_FUNC_OP_FLUSH |
+ AR8327_ATU_FUNC_BUSY);
return ret;
}