patch 'net/enic: avoid extra unlock in MTU set' has been queued to stable release 20.11.10

luca.boccassi at gmail.com luca.boccassi at gmail.com
Wed Nov 8 20:25:17 CET 2023


Hi,

FYI, your patch has been queued to stable release 20.11.10

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/10/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://github.com/bluca/dpdk-stable

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

Thanks.

Luca Boccassi

---
>From 02f1c312bf87e5fdbf0c7696bfa16b2d7f2a8323 Mon Sep 17 00:00:00 2001
From: Weiguo Li <liweiguo at xencore.cn>
Date: Wed, 1 Nov 2023 15:28:09 +0800
Subject: [PATCH] net/enic: avoid extra unlock in MTU set

[ upstream commit e90884a65bf6d8ed0e1e5618af42cf5856a422f1 ]

The 'set_mtu_done' goto statement is being executed in a context
where the 'mtu_lock' has not been previously locked.

To avoid the extra unlocking operation, replace the goto statement
with a return statement.

Fixes: c3e09182bcd6 ("net/enic: support scatter Rx in MTU update")

Signed-off-by: Weiguo Li <liweiguo at xencore.cn>
Reviewed-by: Ferruh Yigit <ferruh.yigit at amd.com>
---
 drivers/net/enic/enic_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/enic/enic_main.c b/drivers/net/enic/enic_main.c
index 498476fce5..7e21557f58 100644
--- a/drivers/net/enic/enic_main.c
+++ b/drivers/net/enic/enic_main.c
@@ -1630,7 +1630,7 @@ int enic_set_mtu(struct enic *enic, uint16_t new_mtu)
 	 * packet length.
 	 */
 	if (!eth_dev->data->dev_started)
-		goto set_mtu_done;
+		return rc;
 
 	/*
 	 * The device has started, re-do RQs on the fly. In the process, we
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2023-11-08 19:23:52.950910547 +0000
+++ 0019-net-enic-avoid-extra-unlock-in-MTU-set.patch	2023-11-08 19:23:51.785396541 +0000
@@ -1 +1 @@
-From e90884a65bf6d8ed0e1e5618af42cf5856a422f1 Mon Sep 17 00:00:00 2001
+From 02f1c312bf87e5fdbf0c7696bfa16b2d7f2a8323 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e90884a65bf6d8ed0e1e5618af42cf5856a422f1 ]
+
@@ -13 +14,0 @@
-Cc: stable at dpdk.org
@@ -18 +18,0 @@
- .mailmap                     | 2 +-
@@ -20 +20 @@
- 2 files changed, 2 insertions(+), 2 deletions(-)
+ 1 file changed, 1 insertion(+), 1 deletion(-)
@@ -22,13 +21,0 @@
-diff --git a/.mailmap b/.mailmap
-index 1e6d750979..c384d97a1a 100644
---- a/.mailmap
-+++ b/.mailmap
-@@ -1502,7 +1502,7 @@ Waterman Cao <waterman.cao at intel.com>
- Weichun Chen <weichunx.chen at intel.com>
- Wei Dai <wei.dai at intel.com>
- Weifeng Li <liweifeng96 at 126.com>
--Weiguo Li <liwg06 at foxmail.com>
-+Weiguo Li <liweiguo at xencore.cn> <liwg06 at foxmail.com>
- Wei Huang <wei.huang at intel.com>
- Wei Hu <weh at microsoft.com>
- Wei Hu (Xavier) <xavier.huwei at huawei.com>
@@ -36 +23 @@
-index 19a99a82c5..a6aaa760ca 100644
+index 498476fce5..7e21557f58 100644
@@ -39 +26 @@
-@@ -1639,7 +1639,7 @@ int enic_set_mtu(struct enic *enic, uint16_t new_mtu)
+@@ -1630,7 +1630,7 @@ int enic_set_mtu(struct enic *enic, uint16_t new_mtu)


More information about the stable mailing list