[dpdk-stable] [17.11] net/tap: fix reported number of Tx packets
Yongseok Koh
yskoh at mellanox.com
Mon Jan 14 05:23:48 CET 2019
> On Jan 13, 2019, at 12:42 AM, Raslan Darawsheh <rasland at mellanox.com> wrote:
>
> When writev fails to send packets it doesn't update the
> number of Tx packets, but it still num_tx is updated.
>
> The value that should be returned is the actual number
> of sent packets which is num_packets.
>
> Fixes: 02f96a0a82d1 ("net/tap: add TUN/TAP device PMD")
> CC: stable at dpdk.org
>
> Signed-off-by: Raslan Darawsheh <rasland at mellanox.com>
> Acked-by: Keith Wiles <keith.wiles at intel.com>
> ---
Raslan, it doesn't get compiled on stable/17.11
Thanks,
Yongseok
> drivers/net/tap/rte_eth_tap.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/tap/rte_eth_tap.c b/drivers/net/tap/rte_eth_tap.c
> index 466624a..50757ef 100644
> --- a/drivers/net/tap/rte_eth_tap.c
> +++ b/drivers/net/tap/rte_eth_tap.c
> @@ -488,7 +488,7 @@ pmd_tx_burst(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
> txq->stats.errs += nb_pkts - num_tx;
> txq->stats.obytes += num_tx_bytes;
>
> - return num_tx;
> + return num_packets;
> }
>
> static const char *
> --
> 2.7.4
>
More information about the stable
mailing list