Commit d9a2fcf5 authored by Aya Levin's avatar Aya Levin Committed by Saeed Mahameed

net/mlx5e: Fix false negative indication on tx reporter CQE recovery

Remove wrong error return value when SQ is not in error state.
CQE recovery on TX reporter queries the sq state. If the sq is not in
error state, the sq is either in ready or reset state. Ready state is
good state which doesn't require recovery and reset state is a temporal
state which ends in ready state. With this patch, CQE recovery in this
scenario is successful.

Fixes: de8650a8 ("net/mlx5e: Add tx reporter support")
Signed-off-by: default avatarAya Levin <ayal@mellanox.com>
Reviewed-by: default avatarTariq Toukan <tariqt@mellanox.com>
Signed-off-by: default avatarSaeed Mahameed <saeedm@mellanox.com>
parent b86f1abe
...@@ -86,10 +86,8 @@ static int mlx5e_tx_reporter_err_cqe_recover(struct mlx5e_txqsq *sq) ...@@ -86,10 +86,8 @@ static int mlx5e_tx_reporter_err_cqe_recover(struct mlx5e_txqsq *sq)
return err; return err;
} }
if (state != MLX5_SQC_STATE_ERR) { if (state != MLX5_SQC_STATE_ERR)
netdev_err(dev, "SQ 0x%x not in ERROR state\n", sq->sqn); return 0;
return -EINVAL;
}
mlx5e_tx_disable_queue(sq->txq); mlx5e_tx_disable_queue(sq->txq);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment