netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 net-next 0/6] net: dsa: mv88e6xxx: Add "eth-mac" and "rmon" counter group support
@ 2023-12-05 16:04 Tobias Waldekranz
  2023-12-05 16:04 ` [PATCH v2 net-next 1/6] net: dsa: mv88e6xxx: Push locking into stats snapshotting Tobias Waldekranz
                   ` (5 more replies)
  0 siblings, 6 replies; 20+ messages in thread
From: Tobias Waldekranz @ 2023-12-05 16:04 UTC (permalink / raw)
  To: davem, kuba; +Cc: andrew, f.fainelli, olteanv, netdev

The majority of the changes (2/6) are about refactoring the existing
ethtool statistics support to make it possible to read individual
counters, rather than the whole set.

4/6 tries to collect all information about a stat in a single place
using a mapper macro, which is then used to generate the original list
of stats, along with a matching enum. checkpatch is less than amused
with this construct, but prior art exists (__BPF_FUNC_MAPPER in
include/uapi/linux/bpf.h, for example).

With that in place, adding the actual counter groups is pretty
straight forward (5-6/6).

v1 -> v2:
- Added 1/6
- Added 3/6
- Changed prototype of stats operation to reflect the fact that the
  number of read stats are returned, no errors
- Moved comma into MV88E6XXX_HW_STAT_MAPPER definition
- Avoid the construction of mapping table iteration which relied on
  struct layouts outside of mv88e6xxx's control

Tobias Waldekranz (6):
  net: dsa: mv88e6xxx: Push locking into stats snapshotting
  net: dsa: mv88e6xxx: Create API to read a single stat counter
  net: dsa: mv88e6xxx: Fix mv88e6352_serdes_get_stats error path
  net: dsa: mv88e6xxx: Give each hw stat an ID
  net: dsa: mv88e6xxx: Add "eth-mac" counter group support
  net: dsa: mv88e6xxx: Add "rmon" counter group support

 drivers/net/dsa/mv88e6xxx/chip.c   | 390 +++++++++++++++++++----------
 drivers/net/dsa/mv88e6xxx/chip.h   |  31 +--
 drivers/net/dsa/mv88e6xxx/serdes.c |  10 +-
 drivers/net/dsa/mv88e6xxx/serdes.h |   8 +-
 4 files changed, 278 insertions(+), 161 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2023-12-07  9:47 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-05 16:04 [PATCH v2 net-next 0/6] net: dsa: mv88e6xxx: Add "eth-mac" and "rmon" counter group support Tobias Waldekranz
2023-12-05 16:04 ` [PATCH v2 net-next 1/6] net: dsa: mv88e6xxx: Push locking into stats snapshotting Tobias Waldekranz
2023-12-05 17:13   ` Vladimir Oltean
2023-12-05 16:04 ` [PATCH v2 net-next 2/6] net: dsa: mv88e6xxx: Create API to read a single stat counter Tobias Waldekranz
2023-12-05 17:26   ` Vladimir Oltean
2023-12-05 16:04 ` [PATCH v2 net-next 3/6] net: dsa: mv88e6xxx: Fix mv88e6352_serdes_get_stats error path Tobias Waldekranz
2023-12-05 17:50   ` Vladimir Oltean
2023-12-05 21:13     ` Tobias Waldekranz
2023-12-05 22:38       ` Vladimir Oltean
2023-12-05 16:04 ` [PATCH v2 net-next 4/6] net: dsa: mv88e6xxx: Give each hw stat an ID Tobias Waldekranz
2023-12-05 17:51   ` Vladimir Oltean
2023-12-05 16:04 ` [PATCH v2 net-next 5/6] net: dsa: mv88e6xxx: Add "eth-mac" counter group support Tobias Waldekranz
2023-12-05 18:07   ` Vladimir Oltean
2023-12-05 21:24     ` Tobias Waldekranz
2023-12-05 16:04 ` [PATCH v2 net-next 6/6] net: dsa: mv88e6xxx: Add "rmon" " Tobias Waldekranz
2023-12-05 18:11   ` Vladimir Oltean
2023-12-06  0:22   ` Vladimir Oltean
2023-12-06  8:27     ` Tobias Waldekranz
2023-12-06 19:55       ` Vladimir Oltean
2023-12-07  9:47         ` Tobias Waldekranz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).