diff options
| author | Bernardo Soares <bsoares.it@gmail.com> | 2026-09-18 10:59:31 +0100 |
|---|---|---|
| committer | Jakub Kicinski <kuba@kernel.org> | 2026-09-22 18:09:18 -0700 |
| commit | 2e51097c982b7b22382fda3202ba29f0ea33e8c0 (patch) | |
| tree | 60499a3d9c612313e8a73e4f7af5cbb1b8c9cdb8 /tools/perf/scripts/python | |
| parent | 35e6f970f553954d92ba20afa885139a8e7dd0d7 (diff) | |
| download | linux-2e51097c982b7b22382fda3202ba29f0ea33e8c0.tar.gz linux-2e51097c982b7b22382fda3202ba29f0ea33e8c0.zip | |
net/mlx5: Bridge, don't fail unlink of untracked/unsupported peer ports
mlx5_esw_bridge_vport_unlink() returns -EINVAL when the port isn't
tracked by this instance's br_offloads. This is reachable on a sibling
instance that registered its notifier after the port was already
enslaved: it never saw the NETDEV_CHANGEUPPER link event, so
peer_link() never created a peer port for it, but it does see the
later unlink event and fails. Return 0 instead, and give
mlx5_esw_bridge_vport_peer_unlink() the same merged_eswitch capability
guard peer_link() already has, since without it peer_link() likewise
never creates a port to unlink.
This also matters beyond the -EINVAL itself:
mlx5_esw_bridge_switchdev_port_event() runs on the per-netns
netdev_chain, and notifier_from_errno(-EINVAL) sets NOTIFY_STOP_MASK,
which call_netdevice_notifiers_info() checks to stop calling further
listeners on that chain - so the old -EINVAL silently dropped the
event for any listener registered later on the same chain, even
though none of it was visible to user space since
__netdev_upper_dev_unlink() discards the return value.
Fixes: c358ea1741bc ("net/mlx5: Bridge, allow merged eswitch connectivity")
Signed-off-by: Bernardo Soares <bsoares.it@gmail.com>
Reviewed-by: Mark Bloch <mbloch@nvidia.com>
Link: https://patch.msgid.link/20260918095931.29792-3-bsoares.it@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
