aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/archs38/base-files
diff options
context:
space:
mode:
authorChuanhong Guo <gch981213@gmail.com>2019-01-11 11:51:54 +0800
committerPetr Štetiar <ynezz@true.cz>2019-03-24 01:44:26 +0100
commit9fc506e9b2e40db8f3a6df5b59556e59351e376f (patch)
tree63078b73cf79bd31afbbb7732931b96c9d78f56f /target/linux/archs38/base-files
parent0598ec0abc3581e162ec62b81ef8f8326467c6c0 (diff)
downloadupstream-9fc506e9b2e40db8f3a6df5b59556e59351e376f.tar.gz
upstream-9fc506e9b2e40db8f3a6df5b59556e59351e376f.tar.bz2
upstream-9fc506e9b2e40db8f3a6df5b59556e59351e376f.zip
generic: ar8216: add support for get_port_stats()
Partially reverts commit eff3549c5883a9abc5dbff00c084cabbcfdf4437. AR7240 and AR9341 have buggy hardware switch LED trigger. The AR7240 one doesn't blink and the blinking of port0/port5 is reversed on AR9341 if we swap PHY0 and PHY4. (Only blinking is reversed, which means LED for PHY0 will lit when PHY0 is link up and will blink when PHY4 has active link and vice versa.) On these two chips a software swconfig LED trigger is required. This commit adds swconfig port stats back but: 1. move checking of mib_t/rxb_id into ar8xxx_chip since we can't distinguish ar7240sw and ar8216 using only chip id. 2. don't update mib counter in get_port_stat. This function is called every 0.01s and this capturing procedure will take up a lot of CPU. We already have a mib_work_func updating mib counters every 2s so return the saved counter instead of fetching new data. The blinking rate will be weird but it should solve the previously mentioned CPU time problem. Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
Diffstat (limited to 'target/linux/archs38/base-files')
0 files changed, 0 insertions, 0 deletions