lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20231205181156.y5p57cb2rgukyjwz@skbuf>
Date: Tue, 5 Dec 2023 20:11:56 +0200
From: Vladimir Oltean <vladimir.oltean@....com>
To: Tobias Waldekranz <tobias@...dekranz.com>
Cc: davem@...emloft.net, kuba@...nel.org, andrew@...n.ch,
	f.fainelli@...il.com, netdev@...r.kernel.org
Subject: Re: [PATCH v2 net-next 6/6] net: dsa: mv88e6xxx: Add "rmon" counter
 group support

On Tue, Dec 05, 2023 at 05:04:18PM +0100, Tobias Waldekranz wrote:
> Report the applicable subset of an mv88e6xxx port's counters using
> ethtool's standardized "rmon" counter group.
> 
> Signed-off-by: Tobias Waldekranz <tobias@...dekranz.com>
> ---
>  drivers/net/dsa/mv88e6xxx/chip.c | 42 ++++++++++++++++++++++++++++++++
>  1 file changed, 42 insertions(+)
> 
> diff --git a/drivers/net/dsa/mv88e6xxx/chip.c b/drivers/net/dsa/mv88e6xxx/chip.c
> index 1a16698181fb..2e74109196f4 100644
> --- a/drivers/net/dsa/mv88e6xxx/chip.c
> +++ b/drivers/net/dsa/mv88e6xxx/chip.c
> @@ -1357,6 +1357,47 @@ static void mv88e6xxx_get_eth_mac_stats(struct dsa_switch *ds, int port,
> +	MV88E6XXX_RMON_STAT_MAP(in_undersize, undersize_pkts);
> +	MV88E6XXX_RMON_STAT_MAP(in_oversize, oversize_pkts);
> +	MV88E6XXX_RMON_STAT_MAP(in_fragments, fragments);
> +	MV88E6XXX_RMON_STAT_MAP(in_jabber, jabbers);
> +	MV88E6XXX_RMON_STAT_MAP(hist_64bytes, hist[0]);
> +	MV88E6XXX_RMON_STAT_MAP(hist_65_127bytes, hist[1]);
> +	MV88E6XXX_RMON_STAT_MAP(hist_128_255bytes, hist[2]);
> +	MV88E6XXX_RMON_STAT_MAP(hist_256_511bytes, hist[3]);
> +	MV88E6XXX_RMON_STAT_MAP(hist_512_1023bytes, hist[4]);
> +	MV88E6XXX_RMON_STAT_MAP(hist_1024_max_bytes, hist[5]);

I see that these are in STATS_TYPE_BANK0 and that every switch provides
that. Good.

Reviewed-by: Vladimir Oltean <vladimir.oltean@....com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ