Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 376684
b: refs/heads/master
c: 5efe535
h: refs/heads/master
v: v3
  • Loading branch information
Jack Morgenstein authored and David S. Miller committed Jun 4, 2013
1 parent 591b6c0 commit 2bc9580
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 17 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a1c6693a50391683e7f5787bb027b1aae1afbedb
refs/heads/master: 5efe5355f22fb9b7bb64d19809c0a75805e0ccb8
2 changes: 0 additions & 2 deletions trunk/drivers/net/ethernet/mellanox/mlx4/cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,6 @@ static int mlx4_comm_cmd_poll(struct mlx4_dev *dev, u8 cmd, u16 param,
* FLR process. The only non-zero result in the RESET command
* is MLX4_DELAY_RESET_SLAVE*/
if ((MLX4_COMM_CMD_RESET == cmd)) {
mlx4_warn(dev, "Got slave FLRed from Communication"
" channel (ret:0x%x)\n", ret_from_pending);
err = MLX4_DELAY_RESET_SLAVE;
} else {
mlx4_warn(dev, "Communication channel timed out\n");
Expand Down
20 changes: 6 additions & 14 deletions trunk/drivers/net/ethernet/mellanox/mlx4/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1290,7 +1290,6 @@ static int mlx4_init_slave(struct mlx4_dev *dev)
{
struct mlx4_priv *priv = mlx4_priv(dev);
u64 dma = (u64) priv->mfunc.vhcr_dma;
int num_of_reset_retries = NUM_OF_RESET_RETRIES;
int ret_from_reset = 0;
u32 slave_read;
u32 cmd_channel_ver;
Expand All @@ -1304,18 +1303,10 @@ static int mlx4_init_slave(struct mlx4_dev *dev)
* NUM_OF_RESET_RETRIES times before leaving.*/
if (ret_from_reset) {
if (MLX4_DELAY_RESET_SLAVE == ret_from_reset) {
msleep(SLEEP_TIME_IN_RESET);
while (ret_from_reset && num_of_reset_retries) {
mlx4_warn(dev, "slave is currently in the"
"middle of FLR. retrying..."
"(try num:%d)\n",
(NUM_OF_RESET_RETRIES -
num_of_reset_retries + 1));
ret_from_reset =
mlx4_comm_cmd(dev, MLX4_COMM_CMD_RESET,
0, MLX4_COMM_TIME);
num_of_reset_retries = num_of_reset_retries - 1;
}
mlx4_warn(dev, "slave is currently in the "
"middle of FLR. Deferring probe.\n");
mutex_unlock(&priv->cmd.slave_cmd_mutex);
return -EPROBE_DEFER;
} else
goto err;
}
Expand Down Expand Up @@ -1526,7 +1517,8 @@ static int mlx4_init_hca(struct mlx4_dev *dev)
} else {
err = mlx4_init_slave(dev);
if (err) {
mlx4_err(dev, "Failed to initialize slave\n");
if (err != -EPROBE_DEFER)
mlx4_err(dev, "Failed to initialize slave\n");
return err;
}

Expand Down

0 comments on commit 2bc9580

Please sign in to comment.