[dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
On Fri, Feb 26, 2016 at 06:01:23PM +0300, Igor Ryzhov wrote: > Signed-off-by: Igor Ryzhov > --- > 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
[dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
On Fri, Feb 26, 2016 at 06:01:23PM +0300, Igor Ryzhov wrote: > Signed-off-by: Igor Ryzhov Acked-by: Yuanhan Liu --yliu
[dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
Signed-off-by: Igor Ryzhov --- 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
[dpdk-dev] [PATCH] virtio: don't count broadcast packets in multicast packets counter
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Igor Ryzhov > Sent: Friday, February 26, 2016 3:01 PM > To: dev at dpdk.org > Subject: [dpdk-dev] [PATCH] virtio: don't count broadcast packets in > multicast packets > counter > > Signed-off-by: Igor Ryzhov Acked-by: Harry van Haaren