]> www.infradead.org Git - linux.git/commitdiff
RDMA/mlx5: Fix link status down event for MPV
authorPatrisious Haddad <phaddad@nvidia.com>
Mon, 30 Dec 2024 14:14:04 +0000 (16:14 +0200)
committerLeon Romanovsky <leon@kernel.org>
Thu, 2 Jan 2025 09:48:17 +0000 (04:48 -0500)
The commit below prevented MPV from unloading correctly due to blocking
the netdev down event, allow sending the event for MPV mode to maintain
proper unload flow.

Fixes: 379013776222 ("RDMA/mlx5: Handle link status event only for LAG device")
Signed-off-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Maor Gottlieb <maorg@nvidia.com>
Link: https://patch.msgid.link/d7731478e456f61255af798a7fd4e64b006ddebb.1735567976.git.leonro@nvidia.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
drivers/infiniband/hw/mlx5/main.c

index e4010f871865bdaf41aa3ae3d4e77d3fc4f6aec7..89597a88c75df1b09e0184b382b0bd5a05204e06 100644 (file)
@@ -242,7 +242,8 @@ static int mlx5_netdev_event(struct notifier_block *this,
        case NETDEV_DOWN: {
                struct net_device *upper = NULL;
 
-               if (!netif_is_lag_master(ndev) && !netif_is_lag_port(ndev))
+               if (!netif_is_lag_master(ndev) && !netif_is_lag_port(ndev) &&
+                   !mlx5_core_mp_enabled(mdev))
                        return NOTIFY_DONE;
 
                if (mlx5_lag_is_roce(mdev) || mlx5_lag_is_sriov(mdev)) {