Skip to content

Commit e70b74b

Browse files
committed
net/mlx5: fw_reset: Don't try to load device in case PCI isn't working
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2131117 Upstream commit(s): commit 7d167b4 Author: Shay Drory <shayd@nvidia.com> Date: Wed Nov 2 23:55:40 2022 -0700 net/mlx5: fw_reset: Don't try to load device in case PCI isn't working In case PCI reads fail after unload, there is no use in trying to load the device. Fixes: 5ec6974 ("net/mlx5: Add support for devlink reload action fw activate") Signed-off-by: Shay Drory <shayd@nvidia.com> Reviewed-by: Moshe Shemesh <moshe@nvidia.com> Signed-off-by: Saeed Mahameed <saeedm@nvidia.com> Signed-off-by: Petr Oros <poros@redhat.com>
1 parent b67ff41 commit e70b74b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/net/ethernet/mellanox/mlx5/core/fw_reset.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,8 @@ static void mlx5_fw_reset_complete_reload(struct mlx5_core_dev *dev)
153153
mlx5_unload_one(dev);
154154
if (mlx5_health_wait_pci_up(dev))
155155
mlx5_core_err(dev, "reset reload flow aborted, PCI reads still not working\n");
156-
mlx5_load_one(dev, false);
156+
else
157+
mlx5_load_one(dev, false);
157158
devlink_remote_reload_actions_performed(priv_to_devlink(dev), 0,
158159
BIT(DEVLINK_RELOAD_ACTION_DRIVER_REINIT) |
159160
BIT(DEVLINK_RELOAD_ACTION_FW_ACTIVATE));

0 commit comments

Comments
 (0)