[dpdk-stable] patch 'net/enic: fix header sizes when copying flow patterns' has been queued to stable release 19.11.6

luca.boccassi at gmail.com luca.boccassi at gmail.com
Mon Nov 9 19:40:54 CET 2020


Hi,

FYI, your patch has been queued to stable release 19.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 11/11/20. 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://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/87cb9574f46f2b70e0ad7cb08a3c6f58fc04123b

Thanks.

Luca Boccassi

---
>From 87cb9574f46f2b70e0ad7cb08a3c6f58fc04123b Mon Sep 17 00:00:00 2001
From: Hyong Youb Kim <hyonkim at cisco.com>
Date: Fri, 30 Oct 2020 00:27:49 -0700
Subject: [PATCH] net/enic: fix header sizes when copying flow patterns

[ upstream commit dd649913cca40dd2a7bbd50d63e82b8b75267795 ]

Several functions use sizeof(struct rte_flow_item_eth) and
sizeof(struct rte_flow_item_ipv6) when copying headers. These sizes
used to coincide with the sizes of rte_ether_hdr and
rte_ipv6_hdr. But, with recently added fields, rte_flow_item_eth and
rte_flow_item_ipv6 have grown in size. Use sizeof(rte_ether_hdr) and
sizeof(rte_ipv6_hdr) instead.

Coverity issue: 363572, 363573
Fixes: ea7768b5bba8 ("net/enic: add flow implementation based on Flow Manager API")

Signed-off-by: Hyong Youb Kim <hyonkim at cisco.com>
Reviewed-by: John Daley <johndale at cisco.com>
---
 drivers/net/enic/enic_fm_flow.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/net/enic/enic_fm_flow.c b/drivers/net/enic/enic_fm_flow.c
index ab008c7356..e87988f48b 100644
--- a/drivers/net/enic/enic_fm_flow.c
+++ b/drivers/net/enic/enic_fm_flow.c
@@ -312,8 +312,8 @@ enic_fm_copy_item_eth(struct copy_item_args *arg)
 	fm_mask = &entry->ftm_mask.fk_hdrset[lvl];
 	fm_data->fk_header_select |= FKH_ETHER;
 	fm_mask->fk_header_select |= FKH_ETHER;
-	memcpy(&fm_data->l2.eth, spec, sizeof(*spec));
-	memcpy(&fm_mask->l2.eth, mask, sizeof(*mask));
+	memcpy(&fm_data->l2.eth, spec, sizeof(struct rte_ether_hdr));
+	memcpy(&fm_mask->l2.eth, mask, sizeof(struct rte_ether_hdr));
 	return 0;
 }
 
@@ -423,8 +423,8 @@ enic_fm_copy_item_ipv6(struct copy_item_args *arg)
 
 	fm_data->fk_header_select |= FKH_IPV6;
 	fm_mask->fk_header_select |= FKH_IPV6;
-	memcpy(&fm_data->l3.ip6, spec, sizeof(*spec));
-	memcpy(&fm_mask->l3.ip6, mask, sizeof(*mask));
+	memcpy(&fm_data->l3.ip6, spec, sizeof(struct rte_ipv6_hdr));
+	memcpy(&fm_mask->l3.ip6, mask, sizeof(struct rte_ipv6_hdr));
 	return 0;
 }
 
@@ -970,7 +970,7 @@ enic_fm_copy_vxlan_encap(struct enic_flowman *fm,
 	eth = (struct rte_ether_hdr *)template;
 	ethertype = &eth->ether_type;
 	append_template(&template, &off, item->spec,
-			sizeof(struct rte_flow_item_eth));
+			sizeof(struct rte_ether_hdr));
 	item++;
 	flow_item_skip_void(&item);
 	/* Optional VLAN */
-- 
2.27.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2020-11-09 18:40:13.667422237 +0000
+++ 0066-net-enic-fix-header-sizes-when-copying-flow-patterns.patch	2020-11-09 18:40:11.203312403 +0000
@@ -1 +1 @@
-From dd649913cca40dd2a7bbd50d63e82b8b75267795 Mon Sep 17 00:00:00 2001
+From 87cb9574f46f2b70e0ad7cb08a3c6f58fc04123b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit dd649913cca40dd2a7bbd50d63e82b8b75267795 ]
+
@@ -15 +16,0 @@
-Cc: stable at dpdk.org
@@ -24 +25 @@
-index 9cea94269c..86b91ed8b1 100644
+index ab008c7356..e87988f48b 100644
@@ -27 +28 @@
-@@ -368,8 +368,8 @@ enic_fm_copy_item_eth(struct copy_item_args *arg)
+@@ -312,8 +312,8 @@ enic_fm_copy_item_eth(struct copy_item_args *arg)
@@ -38 +39 @@
-@@ -479,8 +479,8 @@ enic_fm_copy_item_ipv6(struct copy_item_args *arg)
+@@ -423,8 +423,8 @@ enic_fm_copy_item_ipv6(struct copy_item_args *arg)
@@ -49 +50 @@
-@@ -1047,7 +1047,7 @@ enic_fm_copy_vxlan_encap(struct enic_flowman *fm,
+@@ -970,7 +970,7 @@ enic_fm_copy_vxlan_encap(struct enic_flowman *fm,


More information about the stable mailing list