[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20211029065423.493801d4@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date: Fri, 29 Oct 2021 06:54:23 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Prasanna Vengateshan <prasanna.vengateshan@...rochip.com>
Cc: <andrew@...n.ch>, <netdev@...r.kernel.org>, <olteanv@...il.com>,
<robh+dt@...nel.org>, <UNGLinuxDriver@...rochip.com>,
<Woojung.Huh@...rochip.com>, <hkallweit1@...il.com>,
<linux@...linux.org.uk>, <davem@...emloft.net>,
<linux-kernel@...r.kernel.org>, <vivien.didelot@...il.com>,
<f.fainelli@...il.com>, <devicetree@...r.kernel.org>
Subject: Re: [PATCH v6 net-next 07/10] net: dsa: microchip: add support for
ethtool port counters
On Fri, 29 Oct 2021 10:52:53 +0530 Prasanna Vengateshan wrote:
> Reused the KSZ common APIs for get_ethtool_stats() & get_sset_count()
> along with relevant lan937x hooks for KSZ common layer and added
> support for get_strings()
>
> Signed-off-by: Prasanna Vengateshan <prasanna.vengateshan@...rochip.com>
> static void lan937x_port_stp_state_set(struct dsa_switch *ds, int port,
> u8 state)
> {
> @@ -426,6 +441,9 @@ const struct dsa_switch_ops lan937x_switch_ops = {
> .phy_read = lan937x_phy_read16,
> .phy_write = lan937x_phy_write16,
> .port_enable = ksz_enable_port,
> + .get_strings = lan937x_get_strings,
> + .get_ethtool_stats = ksz_get_ethtool_stats,
> + .get_sset_count = ksz_sset_count,
> .port_bridge_join = ksz_port_bridge_join,
> .port_bridge_leave = ksz_port_bridge_leave,
> .port_stp_state_set = lan937x_port_stp_state_set,
Recent commit 487d3855b641 ("net: dsa: allow reporting of standard
ethtool stats for slave devices") plumbed thru all the standard stats ops.
You must report standard stats (get_eth_*_stats and get_stats64) before
implementing get_ethtool_stats.
Powered by blists - more mailing lists