Skip to content

Commit 39369fd

Browse files
ayalevin123Saeed Mahameed
authored andcommitted
net/mlx5e: Fix missing reset of SW metadata in Striding RQ reset
When resetting the RQ (moving RQ state from RST to RDY), the driver resets the WQ's SW metadata. In striding RQ mode, we maintain a field that reflects the actual expected WQ head (including in progress WQEs posted to the ICOSQ). It was mistakenly not reset together with the WQ. Fix this here. Fixes: 8276ea1 ("net/mlx5e: Report and recover from CQE with error on RQ") Signed-off-by: Aya Levin <[email protected]> Reviewed-by: Tariq Toukan <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]>
1 parent 1de0306 commit 39369fd

File tree

1 file changed

+4
-2
lines changed
  • drivers/net/ethernet/mellanox/mlx5/core/en

1 file changed

+4
-2
lines changed

drivers/net/ethernet/mellanox/mlx5/core/en/txrx.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,10 +181,12 @@ mlx5e_tx_dma_unmap(struct device *pdev, struct mlx5e_sq_dma *dma)
181181

182182
static inline void mlx5e_rqwq_reset(struct mlx5e_rq *rq)
183183
{
184-
if (rq->wq_type == MLX5_WQ_TYPE_LINKED_LIST_STRIDING_RQ)
184+
if (rq->wq_type == MLX5_WQ_TYPE_LINKED_LIST_STRIDING_RQ) {
185185
mlx5_wq_ll_reset(&rq->mpwqe.wq);
186-
else
186+
rq->mpwqe.actual_wq_head = 0;
187+
} else {
187188
mlx5_wq_cyc_reset(&rq->wqe.wq);
189+
}
188190
}
189191

190192
/* SW parser related functions */

0 commit comments

Comments
 (0)