mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tariq Toukan <tariqt@nvidia.com>
To: Andrew Lunn <andrew+netdev@lunn.ch>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@kernel.org>,
	Jakub Kicinski <kuba@kernel.org>, <netdev@vger.kernel.org>,
	Paolo Abeni <pabeni@redhat.com>
Cc: Andrea Parri <parri.andrea@gmail.com>,
	Boris Pismenny <borisp@nvidia.com>,
	Cosmin Ratiu <cratiu@nvidia.com>,
	Dragos Tatulea <dtatulea@nvidia.com>,
	"Gal Pressman" <gal@nvidia.com>,
	Jeroen Massar <jmassar@nvidia.com>,
	Jianbo Liu <jianbol@nvidia.com>,
	Kuniyuki Iwashima <kuniyu@google.com>,
	Leon Romanovsky <leon@kernel.org>,
	open list <linux-kernel@vger.kernel.org>,
	<linux-rdma@vger.kernel.org>, Mark Bloch <mbloch@nvidia.com>,
	"Patrisious Haddad" <phaddad@nvidia.com>,
	Prathamesh Deshpande <prathameshdeshpande7@gmail.com>,
	Raed Salem <raeds@nvidia.com>, Roi Dayan <roid@nvidia.com>,
	Saeed Mahameed <saeedm@nvidia.com>, Shay Drory <shayd@nvidia.com>,
	Simon Horman <horms@kernel.org>,
	Steffen Klassert <steffen.klassert@secunet.com>,
	Tariq Toukan <tariqt@nvidia.com>
Subject: [PATCH net V3 0/8] net/mlx5e: Fix offload lifetime and exclusion bugs
Date: Thu, 5 Nov 2026 23:16:28 +0200	[thread overview]
Message-ID: <20261105211637.1083978-1-tariqt@nvidia.com> (raw)

Hi,

This series by Cosmin fixes several mlx5e offload issues.

1.   Fix fs root table cleanup bug.
2.   Fix IPsec encap serialization bugs.
3.   Fix a deadlock between HCA devcom lock and mode_lock.
4.   Fix uplink unbind deadlocks by not holding mode_lock across
     removal. All eswitch operation initiators wait for ongoing ones to
     finish first. Unblocked by 3.
5.   Fix races between profile cleanup/init and IPsec policy/state add.
     Unblocked by 4.
6+7. Block eswitch mode changes before accessing the IPsec context
     during policy and SA creation. Unblocked by 5.
8.   Serialize TC/IPsec exclusion counters with a per-device spinlock.
     Unblocked by 6+7.

Regards,
Tariq

V3:
- Added several new fixes, all found by internal Sashiko.
- Addressed a few Sashiko comments from V2.
- Renamed V2 patches 1-2 to "Block E-Switch mode changes during IPsec
  policy creation" and "... during IPsec state creation".
- Dropped V2 patch 4, "net/mlx5e: tc: Tie esw & accel blocking refs
  to the flow's lifetime", to be submitted separately.
- Exclusion counters: use a spinlock instead of a mutex, as some
  callers run in atomic context.

V2:
https://lore.kernel.org/netdev/20260930121119.141953-1-tariqt@nvidia.com/
- Use mlx5_esw_lock() in mlx5_eswitch_block_mode() (Sashiko)
- Clarified the fix split across first two patches (Sashiko)
- More careful dereferencing priv->mdev in mlx5e_xfrm_add_state() (Sashiko)
- Avoided spurious error message during IPsec SW fallback (Sashiko)
- Harmonized check_users arg for policy & state add (Sashiko)
- Clarified the scope of the "tc: tie..." fix (Sashiko)
- Moved macsec patches into a separate series.

V1:
https://lore.kernel.org/netdev/20260917175433.4090878-1-tariqt@nvidia.com/

Cosmin Ratiu (8):
  net/mlx5e: Release IPsec root table reference on RX setup failure
  net/mlx5e: Serialize ipsec encap reservations with eswitch operations
  net/mlx5e: Take HCA devcom lock before esw->mode_lock
  net/mlx5e: Fix E-Switch races in uplink unbind
  net/mlx5e: Fix ipsec core device access during profile changes
  net/mlx5e: Block E-Switch mode changes during IPsec policy creation
  net/mlx5e: Block E-Switch mode changes during IPsec state creation
  net/mlx5e: Serialize TC and IPsec offload exclusion counters

 .../mellanox/mlx5/core/en_accel/ipsec.c       | 95 +++++++++++++------
 .../mellanox/mlx5/core/en_accel/ipsec.h       |  2 +-
 .../mellanox/mlx5/core/en_accel/ipsec_fs.c    | 88 ++++++++---------
 .../net/ethernet/mellanox/mlx5/core/en_main.c |  4 +-
 .../net/ethernet/mellanox/mlx5/core/en_tc.c   | 18 ++--
 .../mellanox/mlx5/core/esw/ipsec_fs.c         | 15 ++-
 .../mellanox/mlx5/core/esw/ipsec_fs.h         |  6 ++
 .../net/ethernet/mellanox/mlx5/core/eswitch.c | 24 +++++
 .../net/ethernet/mellanox/mlx5/core/eswitch.h | 15 ++-
 .../mellanox/mlx5/core/eswitch_offloads.c     | 88 +++++++++--------
 .../net/ethernet/mellanox/mlx5/core/main.c    |  1 +
 include/linux/mlx5/driver.h                   |  8 +-
 12 files changed, 231 insertions(+), 133 deletions(-)


base-commit: fafbc4051123d5459ea6950899cec08ed946e278
-- 
2.44.0


             reply	other threads:[~2026-11-05 21:17 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-05 21:16 Tariq Toukan [this message]
2026-11-05 21:16 ` [PATCH net V3 1/8] net/mlx5e: Release IPsec root table reference on RX setup failure Tariq Toukan
2026-11-05 21:16 ` [PATCH net V3 2/8] net/mlx5e: Serialize ipsec encap reservations with eswitch operations Tariq Toukan
2026-11-05 21:16 ` [PATCH net V3 3/8] net/mlx5e: Take HCA devcom lock before esw->mode_lock Tariq Toukan
2026-11-05 21:16 ` [PATCH net V3 4/8] net/mlx5e: Fix E-Switch races in uplink unbind Tariq Toukan
2026-11-05 21:16 ` [PATCH net V3 5/8] net/mlx5e: Fix ipsec core device access during profile changes Tariq Toukan
2026-11-05 21:16 ` [PATCH net V3 6/8] net/mlx5e: Block E-Switch mode changes during IPsec policy creation Tariq Toukan
2026-11-05 21:16 ` [PATCH net V3 7/8] net/mlx5e: Block E-Switch mode changes during IPsec state creation Tariq Toukan
2026-11-05 21:16 ` [PATCH net V3 8/8] net/mlx5e: Serialize TC and IPsec offload exclusion counters Tariq Toukan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261105211637.1083978-1-tariqt@nvidia.com \
    --to=tariqt@nvidia.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=borisp@nvidia.com \
    --cc=cratiu@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=dtatulea@nvidia.com \
    --cc=edumazet@kernel.org \
    --cc=gal@nvidia.com \
    --cc=horms@kernel.org \
    --cc=jianbol@nvidia.com \
    --cc=jmassar@nvidia.com \
    --cc=kuba@kernel.org \
    --cc=kuniyu@google.com \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=mbloch@nvidia.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=parri.andrea@gmail.com \
    --cc=phaddad@nvidia.com \
    --cc=prathameshdeshpande7@gmail.com \
    --cc=raeds@nvidia.com \
    --cc=roid@nvidia.com \
    --cc=saeedm@nvidia.com \
    --cc=shayd@nvidia.com \
    --cc=steffen.klassert@secunet.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®