From: Declan Doherty <declan.doherty@intel.com>
To: dev@dpdk.org
Cc: Tomasz Kulasek <tomaszx.kulasek@intel.com>,
Declan Doherty <declan.doherty@intel.com>
Subject: [dpdk-dev] [PATCH v3 2/4] net/bond: use ptype flags for LACP rx filtering
Date: Tue, 4 Jul 2017 17:46:25 +0100 [thread overview]
Message-ID: <20170704164627.324-3-declan.doherty@intel.com> (raw)
In-Reply-To: <20170704164627.324-1-declan.doherty@intel.com>
From: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Use packet types flags in mbuf to provide hint for filtering of LACP
control plane traffic from the data path.
Signed-off-by: Declan Doherty <declan.doherty@intel.com>
---
drivers/net/bonding/rte_eth_bond_pmd.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
index f428e96..9730ae0 100644
--- a/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -180,6 +180,13 @@ bond_ethdev_rx_burst_8023ad(void *queue, struct rte_mbuf **bufs,
/* Handle slow protocol packets. */
while (j < num_rx_total) {
+
+ /* If packet is not pure L2 and is known, skip it */
+ if ((bufs[j]->packet_type & ~RTE_PTYPE_L2_ETHER) != 0) {
+ j++;
+ continue;
+ }
+
if (j + 3 < num_rx_total)
rte_prefetch0(rte_pktmbuf_mtod(bufs[j + 3], void *));
@@ -187,7 +194,7 @@ bond_ethdev_rx_burst_8023ad(void *queue, struct rte_mbuf **bufs,
subtype = ((struct slow_protocol_frame *)hdr)->slow_protocol.subtype;
/* Remove packet from array if it is slow packet or slave is not
- * in collecting state or bondign interface is not in promiscus
+ * in collecting state or bonding interface is not in promiscuous
* mode and packet address does not match. */
if (unlikely(is_lacp_packets(hdr->ether_type, subtype, bufs[j]->vlan_tci) ||
!collecting || (!promisc &&
--
2.9.4
next prev parent reply other threads:[~2017-07-04 16:49 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-27 11:27 [dpdk-dev] [PATCH 0/2] LACP control packet filtering offload Tomasz Kulasek
2017-05-27 11:27 ` [dpdk-dev] [PATCH 1/2] " Tomasz Kulasek
2017-05-29 8:10 ` Adrien Mazarguil
2017-06-29 9:18 ` Declan Doherty
2017-05-27 11:27 ` [dpdk-dev] [PATCH 2/2] test-pmd: add set bonding slow_queue hw/sw Tomasz Kulasek
2017-06-29 16:20 ` [dpdk-dev] [PATCH v2 0/2] LACP control packet filtering offload Tomasz Kulasek
2017-06-29 16:20 ` [dpdk-dev] [PATCH v2 1/2] " Tomasz Kulasek
2017-06-29 16:20 ` [dpdk-dev] [PATCH v2 2/2] test-pmd: add set bonding slow_queue hw/sw Tomasz Kulasek
2017-07-04 16:46 ` [dpdk-dev] [PATCH v3 0/4] LACP control packet filtering acceleration Declan Doherty
2017-07-04 16:46 ` [dpdk-dev] [PATCH v3 1/4] net/bond: calculate number of bonding tx/rx queues Declan Doherty
2017-07-04 16:46 ` Declan Doherty [this message]
2017-07-04 19:54 ` [dpdk-dev] [PATCH v3 2/4] net/bond: use ptype flags for LACP rx filtering Declan Doherty
2017-07-04 16:46 ` [dpdk-dev] [PATCH v3 3/4] net/bond: dedicated hw queues for LACP control traffic Declan Doherty
2017-07-04 19:55 ` Declan Doherty
2017-07-05 11:19 ` Ferruh Yigit
2017-07-05 11:33 ` Ferruh Yigit
2017-12-13 8:16 ` linhaifeng
2017-12-13 12:41 ` Kulasek, TomaszX
2017-07-04 16:46 ` [dpdk-dev] [PATCH v3 4/4] app/test-pmd: add cmd for dedicated LACP rx/tx queues Declan Doherty
2017-07-04 19:56 ` Declan Doherty
2017-07-05 11:33 ` Ferruh Yigit
2017-07-05 11:35 ` [dpdk-dev] [PATCH v3 0/4] LACP control packet filtering acceleration Ferruh Yigit
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170704164627.324-3-declan.doherty@intel.com \
--to=declan.doherty@intel.com \
--cc=dev@dpdk.org \
--cc=tomaszx.kulasek@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).