forked from Ivasoft/openwrt
generic: provide get_port_stats() on ar8xxx switches
This patch provides a generic switch_dev_ops 'get_port_stats()' callback by taping into the relevant port MIB counters. The implementation uses a generic callback that select the correct MIB counter index based on chip version. This callback is used by swconfig_leds led trigger to blink LEDs with port network traffic. Signed-off-by: Thibaut VARENE <hacks@slashdirt.org>
This commit is contained in:
committed by
John Crispin
parent
2b3ab0208e
commit
4d8a66d934
@@ -566,6 +566,9 @@ ar8xxx_sw_set_flush_port_arl_table(struct switch_dev *dev,
|
||||
const struct switch_attr *attr,
|
||||
struct switch_val *val);
|
||||
int
|
||||
ar8xxx_sw_get_port_stats(struct switch_dev *dev, int port,
|
||||
struct switch_port_stats *stats);
|
||||
int
|
||||
ar8216_wait_bit(struct ar8xxx_priv *priv, int reg, u32 mask, u32 val);
|
||||
|
||||
static inline struct ar8xxx_priv *
|
||||
|
||||
Reference in New Issue
Block a user