DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/iavf: fix GTPU UL and DL support for FDIR
@ 2020-12-31  5:13 Junfeng Guo
  2021-01-04  2:28 ` Zhang, Qi Z
  0 siblings, 1 reply; 3+ messages in thread
From: Junfeng Guo @ 2020-12-31  5:13 UTC (permalink / raw)
  To: qi.z.zhang, jingjing.wu, beilei.xing
  Cc: dev, stable, ferruh.yigit, junfeng.guo

For AVF FDIR, GTPU uplink and downlink are not supported in previous
code. This patch distinguishes GTPU with IP/EH/DL/UL for AVF FDIR.

Fixes: 4c7a41ae6b23 ("net/iavf: support flow director GTPU outer IPv4/IPv6")
Cc: stable@dpdk.org

Signed-off-by: Junfeng Guo <junfeng.guo@intel.com>
---
 drivers/net/iavf/iavf_fdir.c | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/drivers/net/iavf/iavf_fdir.c b/drivers/net/iavf/iavf_fdir.c
index 4473936cb9..1b96e16546 100644
--- a/drivers/net/iavf/iavf_fdir.c
+++ b/drivers/net/iavf/iavf_fdir.c
@@ -25,6 +25,9 @@
 #define IAVF_FDIR_IPV6_TC_OFFSET 20
 #define IAVF_IPV6_TC_MASK  (0xFF << IAVF_FDIR_IPV6_TC_OFFSET)
 
+#define IAVF_GTPU_EH_DWLINK 0
+#define IAVF_GTPU_EH_UPLINK 1
+
 #define IAVF_FDIR_INSET_ETH (\
 	IAVF_INSET_ETHERTYPE)
 
@@ -861,7 +864,14 @@ iavf_fdir_parse_pattern(__rte_unused struct iavf_adapter *ad,
 
 			hdr = &filter->add_fltr.rule_cfg.proto_hdrs.proto_hdr[layer];
 
-			VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH);
+			if (!gtp_psc_spec)
+				VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH);
+			else if ((gtp_psc_mask->qfi) && !(gtp_psc_mask->pdu_type))
+				VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH);
+			else if (gtp_psc_spec->pdu_type == IAVF_GTPU_EH_UPLINK)
+				VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH_PDU_UP);
+			else if (gtp_psc_spec->pdu_type == IAVF_GTPU_EH_DWLINK)
+				VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH_PDU_DWN);
 
 			if (gtp_psc_spec && gtp_psc_mask) {
 				if (gtp_psc_mask->qfi == UINT8_MAX) {
-- 
2.25.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [dpdk-dev] [PATCH] net/iavf: fix GTPU UL and DL support for FDIR
  2020-12-31  5:13 [dpdk-dev] [PATCH] net/iavf: fix GTPU UL and DL support for FDIR Junfeng Guo
@ 2021-01-04  2:28 ` Zhang, Qi Z
  2021-01-06  3:32   ` Xu, HailinX
  0 siblings, 1 reply; 3+ messages in thread
From: Zhang, Qi Z @ 2021-01-04  2:28 UTC (permalink / raw)
  To: Guo, Junfeng, Wu, Jingjing, Xing, Beilei; +Cc: dev, stable, Yigit, Ferruh



> -----Original Message-----
> From: Guo, Junfeng <junfeng.guo@intel.com>
> Sent: Thursday, December 31, 2020 1:13 PM
> To: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>;
> Xing, Beilei <beilei.xing@intel.com>
> Cc: dev@dpdk.org; stable@dpdk.org; Yigit, Ferruh <ferruh.yigit@intel.com>; Guo,
> Junfeng <junfeng.guo@intel.com>
> Subject: [PATCH] net/iavf: fix GTPU UL and DL support for FDIR
> 
> For AVF FDIR, GTPU uplink and downlink are not supported in previous code. This
> patch distinguishes GTPU with IP/EH/DL/UL for AVF FDIR.
> 
> Fixes: 4c7a41ae6b23 ("net/iavf: support flow director GTPU outer IPv4/IPv6")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Junfeng Guo <junfeng.guo@intel.com>

Acked-by: Qi Zhang <qi.z.zhang@intel.com>

Applied to dpdk-next-net-intel.

Thanks
Qi

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [dpdk-dev] [PATCH] net/iavf: fix GTPU UL and DL support for FDIR
  2021-01-04  2:28 ` Zhang, Qi Z
@ 2021-01-06  3:32   ` Xu, HailinX
  0 siblings, 0 replies; 3+ messages in thread
From: Xu, HailinX @ 2021-01-06  3:32 UTC (permalink / raw)
  To: Zhang, Qi Z, Guo, Junfeng, Wu, Jingjing, Xing, Beilei
  Cc: dev, stable, Yigit, Ferruh

Tested-by:  Xu, HailinX <hailinx.xu@intel.com>

Regards,
Xu, Hailin

-----Original Message-----
From: dev <dev-bounces@dpdk.org> On Behalf Of Zhang, Qi Z
Sent: Monday, January 4, 2021 10:28 AM
To: Guo, Junfeng <junfeng.guo@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>; Xing, Beilei <beilei.xing@intel.com>
Cc: dev@dpdk.org; stable@dpdk.org; Yigit, Ferruh <ferruh.yigit@intel.com>
Subject: Re: [dpdk-dev] [PATCH] net/iavf: fix GTPU UL and DL support for FDIR



> -----Original Message-----
> From: Guo, Junfeng <junfeng.guo@intel.com>
> Sent: Thursday, December 31, 2020 1:13 PM
> To: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing 
> <jingjing.wu@intel.com>; Xing, Beilei <beilei.xing@intel.com>
> Cc: dev@dpdk.org; stable@dpdk.org; Yigit, Ferruh 
> <ferruh.yigit@intel.com>; Guo, Junfeng <junfeng.guo@intel.com>
> Subject: [PATCH] net/iavf: fix GTPU UL and DL support for FDIR
> 
> For AVF FDIR, GTPU uplink and downlink are not supported in previous 
> code. This patch distinguishes GTPU with IP/EH/DL/UL for AVF FDIR.
> 
> Fixes: 4c7a41ae6b23 ("net/iavf: support flow director GTPU outer 
> IPv4/IPv6")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Junfeng Guo <junfeng.guo@intel.com>

Acked-by: Qi Zhang <qi.z.zhang@intel.com>

Applied to dpdk-next-net-intel.

Thanks
Qi

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-01-06  3:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-31  5:13 [dpdk-dev] [PATCH] net/iavf: fix GTPU UL and DL support for FDIR Junfeng Guo
2021-01-04  2:28 ` Zhang, Qi Z
2021-01-06  3:32   ` Xu, HailinX

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).