8a90f3d8d0
Before starting transmission of Tx burst, the driver checked the available space in the sq and limited the number of packets for transmission accordingly. The calculation was incorrect for fragmented packets and potentially had significantly limited the length of Tx bursts. This patch removes the assessment and pushes packets to the sq as long as the burst is not exhausted and space is available in the sq. Correct evaluation of the required space isn't possible before the burst because it depends on the number of segments of each packet. This patch adds per-packet space evaluation for each packet before attempting to process it. In case there is not enough queue space, the burst will just stop without error. Fixes: 2061fe41f212 ("net/ena: linearize Tx mbuf") Cc: stable@dpdk.org Signed-off-by: Igor Chauskin <igorch@amazon.com> Reviewed-by: Michal Krawczyk <mk@semihalf.com>