netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next v2 0/5] net: sparx5: add support for port mirroring
@ 2024-04-18 16:56 Daniel Machon
  2024-04-18 16:56 ` [PATCH net-next v2 1/5] net: sparx5: add new register definitions Daniel Machon
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Daniel Machon @ 2024-04-18 16:56 UTC (permalink / raw)
  To: David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Lars Povlsen, Steen Hegelund, UNGLinuxDriver, Russell King
  Cc: netdev, linux-arm-kernel, linux-kernel, Horatiu Vultur,
	Russell King (Oracle), Uwe Kleine-König, Vladimir Oltean,
	Yue Haibing, Daniel Machon

This series adds support for port mirroring, and port mirroring stats,
through tc matchall action FLOW_ACTION_MIRRED.

The hardware has three independent mirroring probes. Each probe can be
configured with a separate set of filtering conditions that must be
fulfilled before traffic is mirrored.

A mirror probe can have up to 64 source ports and a single monitor port.
The direction of a mirror probe determines if rx or tx traffic is
mirrored from the source port to the monitor port.

To: David S. Miller <davem@davemloft.net>
To: Eric Dumazet <edumazet@google.com>
To: Jakub Kicinski <kuba@kernel.org>
To: Paolo Abeni <pabeni@redhat.com>
To: Lars Povlsen <lars.povlsen@microchip.com>
To: Steen Hegelund <Steen.Hegelund@microchip.com>
To: UNGLinuxDriver@microchip.com
To: Russell King <linux@armlinux.org.uk>
Cc: netdev@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Cc: Horatiu Vultur <horatiu.vultur@microchip.com>
Cc: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Cc: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Cc: Vladimir Oltean <vladimir.oltean@nxp.com>
Cc: Yue Haibing <yuehaibing@huawei.com>

Signed-off-by: Daniel Machon <daniel.machon@microchip.com>
---
Changes in v2:
- Fix clang build warning about uninitialized variable 'err'
- Link to v1: https://lore.kernel.org/r/20240418-port-mirroring-v1-0-e05c35007c55@microchip.com

---
Daniel Machon (5):
      net: sparx5: add new register definitions
      net: sparx5: add bookkeeping code for matchall rules
      net: sparx5: add port mirroring implementation
      net: sparx5: add the tc glue to support port mirroring
      net: sparx5: add support for matchall mirror stats

 drivers/net/ethernet/microchip/sparx5/Makefile     |   3 +-
 .../net/ethernet/microchip/sparx5/sparx5_main.c    |   3 +
 .../net/ethernet/microchip/sparx5/sparx5_main.h    |  25 +++
 .../ethernet/microchip/sparx5/sparx5_main_regs.h   |  68 ++++++
 .../net/ethernet/microchip/sparx5/sparx5_mirror.c  | 233 +++++++++++++++++++++
 .../ethernet/microchip/sparx5/sparx5_tc_matchall.c | 125 ++++++++++-
 6 files changed, 447 insertions(+), 10 deletions(-)
---
base-commit: 1c25fe9a044d5334153a3585754b26553f8287b9
change-id: 20240402-port-mirroring-81735171ecfa

Best regards,
-- 
Daniel Machon <daniel.machon@microchip.com>


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

end of thread, other threads:[~2024-04-18 19:02 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-18 16:56 [PATCH net-next v2 0/5] net: sparx5: add support for port mirroring Daniel Machon
2024-04-18 16:56 ` [PATCH net-next v2 1/5] net: sparx5: add new register definitions Daniel Machon
2024-04-18 16:56 ` [PATCH net-next v2 2/5] net: sparx5: add bookkeeping code for matchall rules Daniel Machon
2024-04-18 16:56 ` [PATCH net-next v2 3/5] net: sparx5: add port mirroring implementation Daniel Machon
2024-04-18 16:56 ` [PATCH net-next v2 4/5] net: sparx5: add the tc glue to support port mirroring Daniel Machon
2024-04-18 16:56 ` [PATCH net-next v2 5/5] net: sparx5: add support for matchall mirror stats Daniel Machon
2024-04-18 19:02 ` [PATCH net-next v2 0/5] net: sparx5: add support for port mirroring Jakub Kicinski

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).