patch 'net/ixgbe: fix hash handle leak' has been queued to stable release 19.11.11

christian.ehrhardt at canonical.com christian.ehrhardt at canonical.com
Tue Nov 30 17:33:45 CET 2021


Hi,

FYI, your patch has been queued to stable release 19.11.11

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before December 10th 2021. 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/cpaelzer/dpdk-stable-queue

This queued commit can be viewed at:
https://github.com/cpaelzer/dpdk-stable-queue/commit/61e898b734e61a692e2cc7c95d2c80a312308e36

Thanks.

Christian Ehrhardt <christian.ehrhardt at canonical.com>

---
>From 61e898b734e61a692e2cc7c95d2c80a312308e36 Mon Sep 17 00:00:00 2001
From: Qiming Chen <chenqiming_huawei at 163.com>
Date: Tue, 31 Aug 2021 21:24:07 +0800
Subject: [PATCH] net/ixgbe: fix hash handle leak

[ upstream commit 03f83d6c5c9f9d30ef2cd7c2b0fe5d86935cd372 ]

In the ixgbe_fdir_filter_init and ixgbe_l2_tn_filter_init functions,
after the hash handle is created, the handle is not released in
subsequent abnormal branches.

Fixes: 080e3c0ee989 ("net/ixgbe: store flow director filter")
Fixes: d0c0c416ef1f ("net/ixgbe: store L2 tunnel filter")

Signed-off-by: Qiming Chen <chenqiming_huawei at 163.com>
Acked-by: Qi Zhang <qi.z.zhang at intel.com>
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index 8ec0c76351..0b6a6845a4 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -1439,6 +1439,7 @@ static int ixgbe_fdir_filter_init(struct rte_eth_dev *eth_dev)
 	if (!fdir_info->hash_map) {
 		PMD_INIT_LOG(ERR,
 			     "Failed to allocate memory for fdir hash map!");
+		rte_hash_free(fdir_info->hash_handle);
 		return -ENOMEM;
 	}
 	fdir_info->mask_added = FALSE;
@@ -1475,6 +1476,7 @@ static int ixgbe_l2_tn_filter_init(struct rte_eth_dev *eth_dev)
 	if (!l2_tn_info->hash_map) {
 		PMD_INIT_LOG(ERR,
 			"Failed to allocate memory for L2 TN hash map!");
+		rte_hash_free(l2_tn_info->hash_handle);
 		return -ENOMEM;
 	}
 	l2_tn_info->e_tag_en = FALSE;
-- 
2.34.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-11-30 16:50:07.340357497 +0100
+++ 0021-net-ixgbe-fix-hash-handle-leak.patch	2021-11-30 16:50:05.574871945 +0100
@@ -1 +1 @@
-From 03f83d6c5c9f9d30ef2cd7c2b0fe5d86935cd372 Mon Sep 17 00:00:00 2001
+From 61e898b734e61a692e2cc7c95d2c80a312308e36 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 03f83d6c5c9f9d30ef2cd7c2b0fe5d86935cd372 ]
+
@@ -12 +13,0 @@
-Cc: stable at dpdk.org
@@ -21 +22 @@
-index 3cd2a094ae..7b198d95c2 100644
+index 8ec0c76351..0b6a6845a4 100644
@@ -24 +25 @@
-@@ -1393,6 +1393,7 @@ static int ixgbe_fdir_filter_init(struct rte_eth_dev *eth_dev)
+@@ -1439,6 +1439,7 @@ static int ixgbe_fdir_filter_init(struct rte_eth_dev *eth_dev)
@@ -32 +33 @@
-@@ -1429,6 +1430,7 @@ static int ixgbe_l2_tn_filter_init(struct rte_eth_dev *eth_dev)
+@@ -1475,6 +1476,7 @@ static int ixgbe_l2_tn_filter_init(struct rte_eth_dev *eth_dev)


More information about the stable mailing list