[dpdk-stable] patch 'net/ice: fix deadlock on flow query' has been queued to stable release 20.11.4

Xueming Li xuemingl at nvidia.com
Wed Nov 10 07:28:27 CET 2021


Hi,

FYI, your patch has been queued to stable release 20.11.4

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/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/7722837b520249b1374fa6f30b34db09b34f6ed7

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From 7722837b520249b1374fa6f30b34db09b34f6ed7 Mon Sep 17 00:00:00 2001
From: Yu Wenjun <yuwenjun0x at 163.com>
Date: Thu, 19 Aug 2021 20:10:02 +0800
Subject: [PATCH] net/ice: fix deadlock on flow query
Cc: Xueming Li <xuemingl at nvidia.com>

[ upstream commit 22db014997c68928711e5b9e948ac3986ec1ed58 ]

Default case of the switch statement causes deadlock because it returns
without unlocking the 'flow_ops_lock' lock. Fixing it.

Fixes: 0d6ef740e411 ("net/ice: support flow ops thread safe")

Signed-off-by: Yu Wenjun <yuwenjun0x at 163.com>
Acked-by: Qi Zhang <qi.z.zhang at intel.com>
---
 drivers/net/ice/ice_generic_flow.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ice/ice_generic_flow.c b/drivers/net/ice/ice_generic_flow.c
index 1429cbc3b6..15667c7252 100644
--- a/drivers/net/ice/ice_generic_flow.c
+++ b/drivers/net/ice/ice_generic_flow.c
@@ -2360,15 +2360,16 @@ ice_flow_query(struct rte_eth_dev *dev,
 			ret = flow->engine->query_count(ad, flow, count, error);
 			break;
 		default:
-			return rte_flow_error_set(error, ENOTSUP,
+			ret = rte_flow_error_set(error, ENOTSUP,
 					RTE_FLOW_ERROR_TYPE_ACTION,
 					actions,
 					"action not supported");
+			goto out;
 		}
 	}
 
+out:
 	rte_spinlock_unlock(&pf->flow_ops_lock);
-
 	return ret;
 }
 
-- 
2.33.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-11-10 14:17:03.145274924 +0800
+++ 0023-net-ice-fix-deadlock-on-flow-query.patch	2021-11-10 14:17:01.764080297 +0800
@@ -1 +1 @@
-From 22db014997c68928711e5b9e948ac3986ec1ed58 Mon Sep 17 00:00:00 2001
+From 7722837b520249b1374fa6f30b34db09b34f6ed7 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 22db014997c68928711e5b9e948ac3986ec1ed58 ]
@@ -10 +12,0 @@
-Cc: stable at dpdk.org
@@ -19 +21 @@
-index 66b5743abf..c2fa75f165 100644
+index 1429cbc3b6..15667c7252 100644
@@ -22 +24 @@
-@@ -2518,15 +2518,16 @@ ice_flow_query(struct rte_eth_dev *dev,
+@@ -2360,15 +2360,16 @@ ice_flow_query(struct rte_eth_dev *dev,


More information about the stable mailing list