* [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
@ 2016-02-26 15:01 Igor Ryzhov
2016-02-26 15:14 ` Van Haaren, Harry
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Igor Ryzhov @ 2016-02-26 15:01 UTC (permalink / raw)
To: dev
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
---
drivers/net/virtio/virtio_rxtx.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
index 41a1366..fe18e1d 100644
--- a/drivers/net/virtio/virtio_rxtx.c
+++ b/drivers/net/virtio/virtio_rxtx.c
@@ -543,8 +543,13 @@ virtio_update_packet_stats(struct virtqueue *vq, struct rte_mbuf *mbuf)
}
ea = rte_pktmbuf_mtod(mbuf, struct ether_addr *);
- vq->multicast += is_multicast_ether_addr(ea);
- vq->broadcast += is_broadcast_ether_addr(ea);
+ if (is_multicast_ether_addr(ea)) {
+ if (is_broadcast_ether_addr(ea)) {
+ vq->broadcast++;
+ } else {
+ vq->multicast++;
+ }
+ }
}
#define VIRTIO_MBUF_BURST_SZ 64
--
2.6.4
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
2016-02-26 15:01 [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter Igor Ryzhov
@ 2016-02-26 15:14 ` Van Haaren, Harry
2016-02-29 3:52 ` Yuanhan Liu
2016-03-09 15:12 ` Bruce Richardson
2 siblings, 0 replies; 4+ messages in thread
From: Van Haaren, Harry @ 2016-02-26 15:14 UTC (permalink / raw)
To: Igor Ryzhov, dev
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Igor Ryzhov
> Sent: Friday, February 26, 2016 3:01 PM
> To: dev@dpdk.org
> Subject: [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets
> counter
>
> Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
2016-02-26 15:01 [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter Igor Ryzhov
2016-02-26 15:14 ` Van Haaren, Harry
@ 2016-02-29 3:52 ` Yuanhan Liu
2016-03-09 15:12 ` Bruce Richardson
2 siblings, 0 replies; 4+ messages in thread
From: Yuanhan Liu @ 2016-02-29 3:52 UTC (permalink / raw)
To: Igor Ryzhov; +Cc: dev
On Fri, Feb 26, 2016 at 06:01:23PM +0300, Igor Ryzhov wrote:
> Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
--yliu
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
2016-02-26 15:01 [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter Igor Ryzhov
2016-02-26 15:14 ` Van Haaren, Harry
2016-02-29 3:52 ` Yuanhan Liu
@ 2016-03-09 15:12 ` Bruce Richardson
2 siblings, 0 replies; 4+ messages in thread
From: Bruce Richardson @ 2016-03-09 15:12 UTC (permalink / raw)
To: Igor Ryzhov; +Cc: dev
On Fri, Feb 26, 2016 at 06:01:23PM +0300, Igor Ryzhov wrote:
> Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
> ---
> drivers/net/virtio/virtio_rxtx.c | 9 +++++++--
> 1 file changed, 7 insertions(+), 2 deletions(-)
>
Applied to dpdk-next-net/rel_16_04 with superflous braces removed to comply with
coding standards:
http://dpdk.org/doc/guides/contributing/coding_style.html#control-statements-and-loops
Note to reviewers: if possible, please run checkpatch to catch issues like this.
Regards,
/Bruce
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-03-09 15:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-26 15:01 [dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter Igor Ryzhov
2016-02-26 15:14 ` Van Haaren, Harry
2016-02-29 3:52 ` Yuanhan Liu
2016-03-09 15:12 ` Bruce Richardson
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).