aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic/files/drivers/net/phy/ar8327.h
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2015-01-18 00:54:06 +0000
committerFelix Fietkau <nbd@openwrt.org>2015-01-18 00:54:06 +0000
commit6dfea16ab9df0ff272e0d75a21cb441bbf781ce0 (patch)
tree64f45f6a7a391a217711cba6f199e8d92487ee40 /target/linux/generic/files/drivers/net/phy/ar8327.h
parent53c0c6054f5bed0cd38b3d4e0ee41b06955ed429 (diff)
downloadupstream-6dfea16ab9df0ff272e0d75a21cb441bbf781ce0.tar.gz
upstream-6dfea16ab9df0ff272e0d75a21cb441bbf781ce0.tar.bz2
upstream-6dfea16ab9df0ff272e0d75a21cb441bbf781ce0.zip
ar8216: display flow control info in swconfig get_link in case of autonegatiation too
The swconfig get_link attribute (at least) on AR8327/AR8337 doesn't consider the autonegotiated flow control. AR8327/AR8337 provide the info about autonegotiated rx/tx flow control in bits 10 and 11 of the port status register. Use these values to display info about autonegotiated rx/tx flow control as part of the get_link attribute. Successfully tested on TL-WDR4900 (AR8327 rev.4) and TL-WDR4300 (AR8327 rev.2). Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> SVN-Revision: 44023
Diffstat (limited to 'target/linux/generic/files/drivers/net/phy/ar8327.h')
-rw-r--r--target/linux/generic/files/drivers/net/phy/ar8327.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/target/linux/generic/files/drivers/net/phy/ar8327.h b/target/linux/generic/files/drivers/net/phy/ar8327.h
index 1877f00c97..f0ef013cb6 100644
--- a/target/linux/generic/files/drivers/net/phy/ar8327.h
+++ b/target/linux/generic/files/drivers/net/phy/ar8327.h
@@ -84,6 +84,8 @@
#define AR8327_MAX_FRAME_SIZE_MTU BITS(0, 14)
#define AR8327_REG_PORT_STATUS(_i) (0x07c + (_i) * 4)
+#define AR8327_PORT_STATUS_TXFLOW_AUTO BIT(10)
+#define AR8327_PORT_STATUS_RXFLOW_AUTO BIT(11)
#define AR8327_REG_HEADER_CTRL 0x098
#define AR8327_REG_PORT_HEADER(_i) (0x09c + (_i) * 4)