patch 'ethdev: fix build with LTO' has been queued to stable release 22.11.2

Xueming Li xuemingl at nvidia.com
Sun Apr 9 17:23:43 CEST 2023


Hi,

FYI, your patch has been queued to stable release 22.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 04/11/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://git.dpdk.org/dpdk-stable/log/?h=22.11-staging

This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/log/?h=22.11-staging/commit/00af2661ac7a56f1f093cb94c4a702ac971b8fe7

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From 00af2661ac7a56f1f093cb94c4a702ac971b8fe7 Mon Sep 17 00:00:00 2001
From: Krzysztof Karas <krzysztof.karas at intel.com>
Date: Mon, 20 Feb 2023 17:44:06 +0100
Subject: [PATCH] ethdev: fix build with LTO
Cc: Xueming Li <xuemingl at nvidia.com>

[ upstream commit cdd7ab072d1e662b1d06840447e7d1b8ab8946e3 ]

When Link Time Optimization is enabled, compiler may
complain about "id" in eth_representor_cmp() being
uninitialized.

To suppress the warning it is enough to add explicit
initialization of the variable causing the issue.

Fixes: df7547a6a2cc ("ethdev: add helper function to get representor ID")

Signed-off-by: Krzysztof Karas <krzysztof.karas at intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit at amd.com>
---
 .mailmap                   | 1 +
 lib/ethdev/rte_class_eth.c | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.mailmap b/.mailmap
index dc8a8637e1..ea09ef90cb 100644
--- a/.mailmap
+++ b/.mailmap
@@ -712,6 +712,7 @@ Konstantin Ananyev <konstantin.v.ananyev at yandex.ru> <konstantin.ananyev at huawei.c
 Krishna Murthy <krishna.j.murthy at intel.com>
 Krzysztof Galazka <krzysztof.galazka at intel.com>
 Krzysztof Kanas <kkanas at marvell.com> <krzysztof.kanas at caviumnetworks.com>
+Krzysztof Karas <krzysztof.karas at intel.com>
 Krzysztof Witek <krzysztof.witek at 6wind.com>
 Kuba Kozak <kubax.kozak at intel.com>
 Kumar Amber <kumar.amber at intel.com>
diff --git a/lib/ethdev/rte_class_eth.c b/lib/ethdev/rte_class_eth.c
index 838b3a8f9f..b61dae849d 100644
--- a/lib/ethdev/rte_class_eth.c
+++ b/lib/ethdev/rte_class_eth.c
@@ -67,7 +67,7 @@ eth_representor_cmp(const char *key __rte_unused,
 	const struct rte_eth_dev *edev = opaque;
 	const struct rte_eth_dev_data *data = edev->data;
 	struct rte_eth_devargs eth_da;
-	uint16_t id, nc, np, nf, i, c, p, f;
+	uint16_t id = 0, nc, np, nf, i, c, p, f;
 
 	if ((data->dev_flags & RTE_ETH_DEV_REPRESENTOR) == 0)
 		return -1; /* not a representor port */
-- 
2.25.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2023-04-09 21:45:39.698642100 +0800
+++ 0035-ethdev-fix-build-with-LTO.patch	2023-04-09 21:45:38.619042200 +0800
@@ -1 +1 @@
-From cdd7ab072d1e662b1d06840447e7d1b8ab8946e3 Mon Sep 17 00:00:00 2001
+From 00af2661ac7a56f1f093cb94c4a702ac971b8fe7 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit cdd7ab072d1e662b1d06840447e7d1b8ab8946e3 ]
@@ -14 +16,0 @@
-Cc: stable at dpdk.org
@@ -24 +26 @@
-index 8b84277954..69b6f4de1d 100644
+index dc8a8637e1..ea09ef90cb 100644
@@ -27 +29 @@
-@@ -716,6 +716,7 @@ Konstantin Ananyev <konstantin.v.ananyev at yandex.ru> <konstantin.ananyev at huawei.c
+@@ -712,6 +712,7 @@ Konstantin Ananyev <konstantin.v.ananyev at yandex.ru> <konstantin.ananyev at huawei.c


More information about the stable mailing list