]> git.droids-corp.org - dpdk.git/commit
net/qede: fix Tx completion
authorDevendra Singh Rawat <dsinghrawat@marvell.com>
Fri, 4 Mar 2022 12:08:31 +0000 (17:38 +0530)
committerJerin Jacob <jerinj@marvell.com>
Thu, 10 Mar 2022 07:38:07 +0000 (08:38 +0100)
commitbc3045626517c26bd1cca4342d8df8f852407726
tree6002d569b00c0e8cdefdca954fd31b6a5513066e
parentb60d006cd14743907d75a6944ed24a692e4f79ae
net/qede: fix Tx completion

Tx completion routine was first incrementing the number of free
slots in Tx ring and then freeing corresponding mbufs in bulk.
In some situations, the number of mbufs freed were less than
number of Tx ring slots freed. This caused Tx ring to get into an
inconsistent state and ultimately application fails to transmit
further traffic.

The fix first updates the Tx ring SW consumer index, then
increments Tx ring free slot number and finally frees the mbuf,
this is done in a single iteration of loop.

Fixes: 2c41740bf19e ("net/qede: get consumer index once")
Fixes: 4996b959cde6 ("net/qede: free packets in bulk")
Cc: stable@dpdk.org
Signed-off-by: Devendra Singh Rawat <dsinghrawat@marvell.com>
Signed-off-by: Rasesh Mody <rmody@marvell.com>
drivers/net/qede/qede_rxtx.c