patch 'net/nfp: fix VNI of VXLAN encap action' has been queued to stable release 22.11.2
Xueming Li
xuemingl at nvidia.com
Mon Feb 27 08:00:54 CET 2023
Hi,
FYI, your patch has been queued to stable release 22.11.2
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/01/23. So please
shout if anyone has objections.
Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.
Queued patches are on a temporary branch at:
https://git.dpdk.org/dpdk-stable/log/?h=22.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=22.11-staging&id=7ae80e1379d0f924a6fe7ef3ba7ee3737a62c278
Thanks.
Xueming Li <xuemingl at nvidia.com>
---
>From 7ae80e1379d0f924a6fe7ef3ba7ee3737a62c278 Mon Sep 17 00:00:00 2001
From: Chaoyong He <chaoyong.he at corigine.com>
Date: Wed, 8 Feb 2023 17:23:50 +0800
Subject: [PATCH] net/nfp: fix VNI of VXLAN encap action
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl at nvidia.com>
[ upstream commit 861949032d0f22a6a08bfa101d1beebd9eeb10f9 ]
The helper function which send the tunnel configuration to
firmware requires the vni with CPU endian.
The original VXLAN encap logic wrongly invoke it with the
big-endian value.
Fixes: 724662b4ce5b ("net/nfp: support IPv4 VXLAN encap flow action")
Fixes: c3b7254093c2 ("net/nfp: support IPv6 VXLAN encap flow action")
Signed-off-by: Chaoyong He <chaoyong.he at corigine.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund at corigine.com>
---
drivers/net/nfp/nfp_flow.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/net/nfp/nfp_flow.c b/drivers/net/nfp/nfp_flow.c
index 8784e01628..30e1edacb2 100644
--- a/drivers/net/nfp/nfp_flow.c
+++ b/drivers/net/nfp/nfp_flow.c
@@ -2675,6 +2675,7 @@ nfp_flow_action_vxlan_encap_v4(struct nfp_app_fw_flower *app_fw_flower,
struct nfp_fl_rule_metadata *nfp_flow_meta,
struct nfp_fl_tun *tun)
{
+ uint64_t tun_id;
struct nfp_fl_act_pre_tun *pre_tun;
struct nfp_fl_act_set_tun *set_tun;
const struct rte_flow_item_eth *eth;
@@ -2693,7 +2694,8 @@ nfp_flow_action_vxlan_encap_v4(struct nfp_app_fw_flower *app_fw_flower,
set_tun = (struct nfp_fl_act_set_tun *)(act_data + act_pre_size);
memset(set_tun, 0, act_set_size);
- nfp_flow_set_tun_process(set_tun, NFP_FL_TUN_VXLAN, vxlan->hdr.vx_vni,
+ tun_id = rte_be_to_cpu_32(vxlan->hdr.vx_vni);
+ nfp_flow_set_tun_process(set_tun, NFP_FL_TUN_VXLAN, tun_id,
ipv4->hdr.time_to_live, ipv4->hdr.type_of_service);
set_tun->tun_flags = vxlan->hdr.vx_flags;
@@ -2710,6 +2712,7 @@ nfp_flow_action_vxlan_encap_v6(struct nfp_app_fw_flower *app_fw_flower,
struct nfp_fl_rule_metadata *nfp_flow_meta,
struct nfp_fl_tun *tun)
{
+ uint64_t tun_id;
struct nfp_fl_act_pre_tun *pre_tun;
struct nfp_fl_act_set_tun *set_tun;
const struct rte_flow_item_eth *eth;
@@ -2728,7 +2731,8 @@ nfp_flow_action_vxlan_encap_v6(struct nfp_app_fw_flower *app_fw_flower,
set_tun = (struct nfp_fl_act_set_tun *)(act_data + act_pre_size);
memset(set_tun, 0, act_set_size);
- nfp_flow_set_tun_process(set_tun, NFP_FL_TUN_VXLAN, vxlan->hdr.vx_vni,
+ tun_id = rte_be_to_cpu_32(vxlan->hdr.vx_vni);
+ nfp_flow_set_tun_process(set_tun, NFP_FL_TUN_VXLAN, tun_id,
ipv6->hdr.hop_limits,
(ipv6->hdr.vtc_flow >> RTE_IPV6_HDR_TC_SHIFT) & 0xff);
set_tun->tun_flags = vxlan->hdr.vx_flags;
--
2.25.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2023-02-27 14:08:45.555152000 +0800
+++ 0147-net-nfp-fix-VNI-of-VXLAN-encap-action.patch 2023-02-27 14:08:40.949237000 +0800
@@ -1 +1 @@
-From 861949032d0f22a6a08bfa101d1beebd9eeb10f9 Mon Sep 17 00:00:00 2001
+From 7ae80e1379d0f924a6fe7ef3ba7ee3737a62c278 Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 861949032d0f22a6a08bfa101d1beebd9eeb10f9 ]
@@ -16 +18,0 @@
-Cc: stable at dpdk.org
@@ -25 +27 @@
-index bd3a8d2a3b..4d4d21d997 100644
+index 8784e01628..30e1edacb2 100644
@@ -28 +30 @@
-@@ -2686,6 +2686,7 @@ nfp_flow_action_vxlan_encap_v4(struct nfp_app_fw_flower *app_fw_flower,
+@@ -2675,6 +2675,7 @@ nfp_flow_action_vxlan_encap_v4(struct nfp_app_fw_flower *app_fw_flower,
@@ -36 +38 @@
-@@ -2704,7 +2705,8 @@ nfp_flow_action_vxlan_encap_v4(struct nfp_app_fw_flower *app_fw_flower,
+@@ -2693,7 +2694,8 @@ nfp_flow_action_vxlan_encap_v4(struct nfp_app_fw_flower *app_fw_flower,
@@ -46 +48 @@
-@@ -2721,6 +2723,7 @@ nfp_flow_action_vxlan_encap_v6(struct nfp_app_fw_flower *app_fw_flower,
+@@ -2710,6 +2712,7 @@ nfp_flow_action_vxlan_encap_v6(struct nfp_app_fw_flower *app_fw_flower,
@@ -54 +56 @@
-@@ -2739,7 +2742,8 @@ nfp_flow_action_vxlan_encap_v6(struct nfp_app_fw_flower *app_fw_flower,
+@@ -2728,7 +2731,8 @@ nfp_flow_action_vxlan_encap_v6(struct nfp_app_fw_flower *app_fw_flower,
More information about the stable
mailing list