ar8216: display flow control info in swconfig get_link in case of autonegatiation too
authorFelix Fietkau <nbd@openwrt.org>
Sun, 18 Jan 2015 00:54:06 +0000 (00:54 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Sun, 18 Jan 2015 00:54:06 +0000 (00:54 +0000)
commit6dfea16ab9df0ff272e0d75a21cb441bbf781ce0
tree64f45f6a7a391a217711cba6f199e8d92487ee40
parent53c0c6054f5bed0cd38b3d4e0ee41b06955ed429
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
target/linux/generic/files/drivers/net/phy/ar8327.c
target/linux/generic/files/drivers/net/phy/ar8327.h