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)
commit7fdeb318e639101d96537fc0ad0b8fb9faa59790
tree534f963c51647d9f1a22abb2c69f6a587430e25a
parentaf59ae81dd9bc4b7f6eec19157dfbcf37d83cf4e
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