* [dpdk-dev] [PATCH] net/virtio: avoid double accounting of bytes
@ 2018-12-20 10:56 Jens Freimann
2018-12-20 18:01 ` Maxime Coquelin
2018-12-20 18:20 ` Maxime Coquelin
0 siblings, 2 replies; 3+ messages in thread
From: Jens Freimann @ 2018-12-20 10:56 UTC (permalink / raw)
To: dev; +Cc: tiwei.bie, maxime.coquelin
Accounting of bytes was moved to a common function, so at the moment we do
it twice. This patches fixes it for sending packets with packed virtqueues.
Signed-off-by: Jens Freimann <jfreimann@redhat.com>
---
drivers/net/virtio/virtio_rxtx.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
index 8564f18a7..8a08606fb 100644
--- a/drivers/net/virtio/virtio_rxtx.c
+++ b/drivers/net/virtio/virtio_rxtx.c
@@ -1931,7 +1931,6 @@ virtio_xmit_pkts_packed(void *tx_queue, struct rte_mbuf **tx_pkts,
/* Enqueue Packet buffers */
virtqueue_enqueue_xmit_packed(txvq, txm, slots, can_push);
- txvq->stats.bytes += txm->pkt_len;
virtio_update_packet_stats(&txvq->stats, txm);
}
--
2.17.2
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] net/virtio: avoid double accounting of bytes
2018-12-20 10:56 [dpdk-dev] [PATCH] net/virtio: avoid double accounting of bytes Jens Freimann
@ 2018-12-20 18:01 ` Maxime Coquelin
2018-12-20 18:20 ` Maxime Coquelin
1 sibling, 0 replies; 3+ messages in thread
From: Maxime Coquelin @ 2018-12-20 18:01 UTC (permalink / raw)
To: Jens Freimann, dev; +Cc: tiwei.bie
On 12/20/18 11:56 AM, Jens Freimann wrote:
> Accounting of bytes was moved to a common function, so at the moment we do
> it twice. This patches fixes it for sending packets with packed virtqueues.
>
> Signed-off-by: Jens Freimann <jfreimann@redhat.com>
> ---
> drivers/net/virtio/virtio_rxtx.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
> index 8564f18a7..8a08606fb 100644
> --- a/drivers/net/virtio/virtio_rxtx.c
> +++ b/drivers/net/virtio/virtio_rxtx.c
> @@ -1931,7 +1931,6 @@ virtio_xmit_pkts_packed(void *tx_queue, struct rte_mbuf **tx_pkts,
> /* Enqueue Packet buffers */
> virtqueue_enqueue_xmit_packed(txvq, txm, slots, can_push);
>
> - txvq->stats.bytes += txm->pkt_len;
> virtio_update_packet_stats(&txvq->stats, txm);
> }
>
>
Thanks Jens for the quick fix:
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Maxime
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] net/virtio: avoid double accounting of bytes
2018-12-20 10:56 [dpdk-dev] [PATCH] net/virtio: avoid double accounting of bytes Jens Freimann
2018-12-20 18:01 ` Maxime Coquelin
@ 2018-12-20 18:20 ` Maxime Coquelin
1 sibling, 0 replies; 3+ messages in thread
From: Maxime Coquelin @ 2018-12-20 18:20 UTC (permalink / raw)
To: Jens Freimann, dev; +Cc: tiwei.bie
On 12/20/18 11:56 AM, Jens Freimann wrote:
> Accounting of bytes was moved to a common function, so at the moment we do
> it twice. This patches fixes it for sending packets with packed virtqueues.
>
> Signed-off-by: Jens Freimann <jfreimann@redhat.com>
> ---
> drivers/net/virtio/virtio_rxtx.c | 1 -
> 1 file changed, 1 deletion(-)
>
Applied to dpdk-next-virtio.
Maxime
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-12-20 18:20 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-20 10:56 [dpdk-dev] [PATCH] net/virtio: avoid double accounting of bytes Jens Freimann
2018-12-20 18:01 ` Maxime Coquelin
2018-12-20 18:20 ` Maxime Coquelin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).