[dpdk-stable] patch 'net/enic: fix flow initialization error handling' has been queued to stable release 20.11.2

Xueming Li xuemingl at nvidia.com
Mon May 10 18:01:51 CEST 2021


Hi,

FYI, your patch has been queued to stable release 20.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 05/12/21. 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/steevenlee/dpdk

This queued commit can be viewed at:
https://github.com/steevenlee/dpdk/commit/2b03f8ca36f00d15271c3cf6939cc696402e482a

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From 2b03f8ca36f00d15271c3cf6939cc696402e482a Mon Sep 17 00:00:00 2001
From: John Daley <johndale at cisco.com>
Date: Thu, 8 Apr 2021 16:06:31 -0700
Subject: [PATCH] net/enic: fix flow initialization error handling
Cc: Luca Boccassi <bluca at debian.org>

[ upstream commit 5aa67931ec0ee1d335297a8c3fec5643a57c136b ]

Fix a rare case in rte_flow initialization where the action hash table
is not freed if allocating a NIC match table fails.

Fixes: ea7768b5bba8 ("net/enic: add flow implementation based on Flow Manager API")

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

diff --git a/drivers/net/enic/enic_fm_flow.c b/drivers/net/enic/enic_fm_flow.c
index 86b91ed8b1..401076b726 100644
--- a/drivers/net/enic/enic_fm_flow.c
+++ b/drivers/net/enic/enic_fm_flow.c
@@ -2886,7 +2886,7 @@ enic_fm_init(struct enic *enic)
 	rc = enic_fm_init_actions(fm);
 	if (rc) {
 		ENICPMD_LOG(ERR, "cannot create action hash, error:%d", rc);
-		goto error_tables;
+		goto error_counters;
 	}
 	/*
 	 * One default exact match table for each direction. We hold onto
@@ -2895,7 +2895,7 @@ enic_fm_init(struct enic *enic)
 	rc = enic_fet_alloc(fm, 1, NULL, 128, &fm->default_ig_fet);
 	if (rc) {
 		ENICPMD_LOG(ERR, "cannot alloc default IG exact match table");
-		goto error_counters;
+		goto error_actions;
 	}
 	fm->default_ig_fet->ref = 1;
 	rc = enic_fet_alloc(fm, 0, NULL, 128, &fm->default_eg_fet);
@@ -2910,6 +2910,8 @@ enic_fm_init(struct enic *enic)
 
 error_ig_fet:
 	enic_fet_free(fm, fm->default_ig_fet);
+error_actions:
+	rte_hash_free(fm->action_hash);
 error_counters:
 	enic_fm_free_all_counters(fm);
 error_tables:
-- 
2.25.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-05-10 23:59:30.812473700 +0800
+++ 0163-net-enic-fix-flow-initialization-error-handling.patch	2021-05-10 23:59:26.610000000 +0800
@@ -1 +1 @@
-From 5aa67931ec0ee1d335297a8c3fec5643a57c136b Mon Sep 17 00:00:00 2001
+From 2b03f8ca36f00d15271c3cf6939cc696402e482a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Luca Boccassi <bluca at debian.org>
+
+[ upstream commit 5aa67931ec0ee1d335297a8c3fec5643a57c136b ]
@@ -10 +12,0 @@
-Cc: stable at dpdk.org
@@ -19 +21 @@
-index 21d9b1cef7..cd364ee16b 100644
+index 86b91ed8b1..401076b726 100644
@@ -22 +24 @@
-@@ -2890,7 +2890,7 @@ enic_fm_init(struct enic *enic)
+@@ -2886,7 +2886,7 @@ enic_fm_init(struct enic *enic)
@@ -31 +33 @@
-@@ -2899,7 +2899,7 @@ enic_fm_init(struct enic *enic)
+@@ -2895,7 +2895,7 @@ enic_fm_init(struct enic *enic)
@@ -40 +42 @@
-@@ -2914,6 +2914,8 @@ enic_fm_init(struct enic *enic)
+@@ -2910,6 +2910,8 @@ enic_fm_init(struct enic *enic)


More information about the stable mailing list