[dpdk-stable] [PATCH] net/mlx5: fix updating total length of multi-packet send

Yongseok Koh yskoh at mellanox.com
Fri Jan 13 20:55:36 CET 2017


Hi

It was my mistake to send it to only stable at dpdk.org. I should've included
dev at dpdk.org and the maintainer. I will send it again appropriately, please
ignore this email.

Thanks,
Yongseok

> On Jan 13, 2017, at 11:45 AM, Yongseok Koh <yskoh at mellanox.com> wrote:
> 
> The total length field in descriptor of inlined multi-packet send must be
> updated before closing a seesion. There's possibility of updating it
> afterward. This bug might cause one packet out of MLX5_MPW_DSEG_MAX gets
> silently dropped by HW and impact performance, escpecially lossless test..
> 
> Fixes: 230189d9ff22 ("net/mlx5: support multi-packet send")
> 
> CC: stable at dpdk.org
> Signed-off-by: Yongseok Koh <yskoh at mellanox.com>
> ---
> drivers/net/mlx5/mlx5_rxtx.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/mlx5/mlx5_rxtx.c b/drivers/net/mlx5/mlx5_rxtx.c
> index 89b1300e6..a5b492dcc 100644
> --- a/drivers/net/mlx5/mlx5_rxtx.c
> +++ b/drivers/net/mlx5/mlx5_rxtx.c
> @@ -1179,6 +1179,7 @@ mlx5_tx_burst_mpw_inline(void *dpdk_txq, struct rte_mbuf **pkts,
> 					mpw.data.raw += length;
> 			}
> 			++mpw.pkts_n;
> +			mpw.total_len += length;
> 			++j;
> 			if (mpw.pkts_n == MLX5_MPW_DSEG_MAX) {
> 				mlx5_mpw_inline_close(txq, &mpw);
> @@ -1188,7 +1189,6 @@ mlx5_tx_burst_mpw_inline(void *dpdk_txq, struct rte_mbuf **pkts,
> 				inline_room -= length;
> 			}
> 		}
> -		mpw.total_len += length;
> 		elts_head = elts_head_next;
> #ifdef MLX5_PMD_SOFT_COUNTERS
> 		/* Increment sent bytes counter. */
> -- 
> 2.11.0
> 



More information about the stable mailing list