patch 'net/hns3: fix build warning' has been queued to stable release 21.11.5

Kevin Traynor ktraynor at redhat.com
Thu Jul 20 17:17:33 CEST 2023


Hi,

FYI, your patch has been queued to stable release 21.11.5

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

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/f400487830aed167fb2935ebfc7855139819f05b

Thanks.

Kevin

---
>From f400487830aed167fb2935ebfc7855139819f05b Mon Sep 17 00:00:00 2001
From: Jerin Jacob <jerinj at marvell.com>
Date: Tue, 4 Apr 2023 12:25:25 +0530
Subject: [PATCH] net/hns3: fix build warning
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 60fe5c3cfc3c28952448d2163c4eb1d22d86ccac ]

aarch64 gcc 12.2.0 build complain with below warning[1].
Move the new_link initialization upwards to fix the warning.

[1]
drivers/net/hns3/hns3_ethdev.c: In function ‘hns3_dev_link_update’:
drivers/net/hns3/hns3_ethdev.c:2249:1:
  warning: ‘new_link’ may be used uninitialized [-Wmaybe-uninitialized]

Fixes: 64308555d5bf ("net/hns3: fix link status when port is stopped")

Signed-off-by: Jerin Jacob <jerinj at marvell.com>
Acked-by: Dongdong Liu <liudongdong3 at huawei.com>
---
 drivers/net/hns3/hns3_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/hns3/hns3_ethdev.c b/drivers/net/hns3/hns3_ethdev.c
index fd82e98693..696530f779 100644
--- a/drivers/net/hns3/hns3_ethdev.c
+++ b/drivers/net/hns3/hns3_ethdev.c
@@ -2269,4 +2269,5 @@ hns3_dev_link_update(struct rte_eth_dev *eth_dev, int wait_to_complete)
 	int ret;
 
+	memset(&new_link, 0, sizeof(new_link));
 	/* When port is stopped, report link down. */
 	if (eth_dev->data->dev_started == 0) {
@@ -2292,5 +2293,4 @@ hns3_dev_link_update(struct rte_eth_dev *eth_dev, int wait_to_complete)
 	} while (retry_cnt--);
 
-	memset(&new_link, 0, sizeof(new_link));
 	hns3_setup_linkstatus(eth_dev, &new_link);
 
-- 
2.41.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2023-07-20 16:17:57.803021006 +0100
+++ 0022-net-hns3-fix-build-warning.patch	2023-07-20 16:17:54.486749793 +0100
@@ -1 +1 @@
-From 60fe5c3cfc3c28952448d2163c4eb1d22d86ccac Mon Sep 17 00:00:00 2001
+From f400487830aed167fb2935ebfc7855139819f05b Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 60fe5c3cfc3c28952448d2163c4eb1d22d86ccac ]
+
@@ -18 +19,0 @@
-Cc: stable at dpdk.org
@@ -27 +28 @@
-index 36896f8989..a872cb8dd7 100644
+index fd82e98693..696530f779 100644
@@ -30 +31 @@
-@@ -2258,4 +2258,5 @@ hns3_dev_link_update(struct rte_eth_dev *eth_dev, int wait_to_complete)
+@@ -2269,4 +2269,5 @@ hns3_dev_link_update(struct rte_eth_dev *eth_dev, int wait_to_complete)
@@ -36 +37 @@
-@@ -2281,5 +2282,4 @@ hns3_dev_link_update(struct rte_eth_dev *eth_dev, int wait_to_complete)
+@@ -2292,5 +2293,4 @@ hns3_dev_link_update(struct rte_eth_dev *eth_dev, int wait_to_complete)



More information about the stable mailing list