From: alvinx.zhang@intel.com
To: jia.guo@intel.com, qi.z.zhang@intel.com
Cc: dev@dpdk.org, Alvin Zhang <alvinx.zhang@intel.com>
Subject: [dpdk-dev] [PATCH v3 3/3] net/iavf: support outer IP hash for GTPU
Date: Tue, 8 Sep 2020 17:50:15 +0800 [thread overview]
Message-ID: <20200908095015.23708-3-alvinx.zhang@intel.com> (raw)
In-Reply-To: <20200908095015.23708-1-alvinx.zhang@intel.com>
From: Alvin Zhang <alvinx.zhang@intel.com>
Add headers for GTPU, now outer IP hash can be configured as input
sets for GTPU packet.
Signed-off-by: Alvin Zhang <alvinx.zhang@intel.com>
---
drivers/net/iavf/iavf_hash.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/drivers/net/iavf/iavf_hash.c b/drivers/net/iavf/iavf_hash.c
index ddea3dd..8aeb3f83 100644
--- a/drivers/net/iavf/iavf_hash.c
+++ b/drivers/net/iavf/iavf_hash.c
@@ -135,6 +135,9 @@ struct iavf_hash_flow_cfg {
#define proto_hdr_gtpc { \
VIRTCHNL_PROTO_HDR_GTPC, 0, {BUFF_NOUSED} }
+#define proto_hdr_gtpu { \
+ VIRTCHNL_PROTO_HDR_GTPU_IP, 0, {BUFF_NOUSED} }
+
#define TUNNEL_LEVEL_OUTER 0
#define TUNNEL_LEVEL_INNER 1
@@ -267,6 +270,14 @@ struct virtchnl_proto_hdrs ipv6_udp_gtpc_tmplt = {
TUNNEL_LEVEL_OUTER, 3, {proto_hdr_ipv6, proto_hdr_udp, proto_hdr_gtpc}
};
+struct virtchnl_proto_hdrs outer_ipv4_udp_gtpu_tmplt = {
+ TUNNEL_LEVEL_OUTER, 3, {proto_hdr_ipv4, proto_hdr_udp, proto_hdr_gtpu}
+};
+
+struct virtchnl_proto_hdrs outer_ipv6_udp_gtpu_tmplt = {
+ TUNNEL_LEVEL_OUTER, 3, {proto_hdr_ipv6, proto_hdr_udp, proto_hdr_gtpu}
+};
+
/* rss type super set */
/* IPv4 outer */
@@ -359,6 +370,7 @@ struct virtchnl_proto_hdrs ipv6_udp_gtpc_tmplt = {
{iavf_pattern_eth_vlan_ipv4_udp, IAVF_RSS_TYPE_VLAN_IPV4_UDP, &outer_ipv4_udp_tmplt},
{iavf_pattern_eth_vlan_ipv4_tcp, IAVF_RSS_TYPE_VLAN_IPV4_TCP, &outer_ipv4_tcp_tmplt},
{iavf_pattern_eth_vlan_ipv4_sctp, IAVF_RSS_TYPE_VLAN_IPV4_SCTP, &outer_ipv4_sctp_tmplt},
+ {iavf_pattern_eth_ipv4_gtpu, ETH_RSS_IPV4, &outer_ipv4_udp_gtpu_tmplt},
{iavf_pattern_eth_ipv4_gtpu_ipv4, IAVF_RSS_TYPE_GTPU_IPV4, &inner_ipv4_tmplt},
{iavf_pattern_eth_ipv4_gtpu_ipv4_udp, IAVF_RSS_TYPE_GTPU_IPV4_UDP, &inner_ipv4_udp_tmplt},
{iavf_pattern_eth_ipv4_gtpu_ipv4_tcp, IAVF_RSS_TYPE_GTPU_IPV4_TCP, &inner_ipv4_tcp_tmplt},
@@ -386,6 +398,7 @@ struct virtchnl_proto_hdrs ipv6_udp_gtpc_tmplt = {
{iavf_pattern_eth_vlan_ipv6_udp, IAVF_RSS_TYPE_VLAN_IPV6_UDP, &outer_ipv6_udp_tmplt},
{iavf_pattern_eth_vlan_ipv6_tcp, IAVF_RSS_TYPE_VLAN_IPV6_TCP, &outer_ipv6_tcp_tmplt},
{iavf_pattern_eth_vlan_ipv6_sctp, IAVF_RSS_TYPE_VLAN_IPV6_SCTP, &outer_ipv6_sctp_tmplt},
+ {iavf_pattern_eth_ipv6_gtpu, ETH_RSS_IPV6, &outer_ipv6_udp_gtpu_tmplt},
{iavf_pattern_eth_ipv4_gtpu_ipv6, IAVF_RSS_TYPE_GTPU_IPV6, &inner_ipv6_tmplt},
{iavf_pattern_eth_ipv4_gtpu_ipv6_udp, IAVF_RSS_TYPE_GTPU_IPV6_UDP, &inner_ipv6_udp_tmplt},
{iavf_pattern_eth_ipv4_gtpu_ipv6_tcp, IAVF_RSS_TYPE_GTPU_IPV6_TCP, &inner_ipv6_tcp_tmplt},
--
1.8.3.1
next prev parent reply other threads:[~2020-09-08 9:54 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-08 9:50 [dpdk-dev] [PATCH v3 1/3] common/iavf: add GTPC support alvinx.zhang
2020-09-08 9:50 ` [dpdk-dev] [PATCH v3 2/3] net/iavf: support outer IP hash for GTPC alvinx.zhang
2020-09-08 9:50 ` alvinx.zhang [this message]
2020-09-10 3:26 ` [dpdk-dev] [PATCH v4] net/iavf: support outer IP hash for GTPU alvinx.zhang
2020-09-10 5:24 ` Guo, Jia
2020-09-10 9:24 ` Zhang, AlvinX
2020-09-14 9:03 ` [dpdk-dev] [PATCH v5] net/iavf: support outer IP hash for no inner GTPU alvinx.zhang
2020-09-14 10:33 ` Zhang, Qi Z
2020-09-15 1:54 ` Zhang, AlvinX
2020-09-15 2:43 ` [dpdk-dev] [PATCH v6] " alvinx.zhang
2020-09-15 2:58 ` Zhang, Qi Z
2020-09-10 3:36 ` [dpdk-dev] [PATCH v4 1/2] common/iavf: add GTPC support alvinx.zhang
2020-09-10 3:36 ` [dpdk-dev] [PATCH v4 2/2] net/iavf: support outer IP hash for GTPC alvinx.zhang
2020-09-10 5:14 ` Guo, Jia
2020-09-10 9:29 ` Zhang, AlvinX
2020-09-14 9:12 ` [dpdk-dev] [PATCH v5] " alvinx.zhang
2020-09-14 10:48 ` Zhang, Qi Z
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=20200908095015.23708-3-alvinx.zhang@intel.com \
--to=alvinx.zhang@intel.com \
--cc=dev@dpdk.org \
--cc=jia.guo@intel.com \
--cc=qi.z.zhang@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).