* patch 'test/ring: fix init with custom number of lcores' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
@ 2025-02-18 12:33 ` Xueming Li
2025-02-18 12:33 ` patch 'vhost: clear ring addresses when getting vring base' " Xueming Li
` (86 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:33 UTC (permalink / raw)
To: Konstantin Ananyev
Cc: xuemingl, Phanendra Vukkisala, Morten Brørup,
Stephen Hemminger, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=8c0b8af3bd76eb9d19ade4503b72a901b6e9780b
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 8c0b8af3bd76eb9d19ade4503b72a901b6e9780b Mon Sep 17 00:00:00 2001
From: Konstantin Ananyev <konstantin.ananyev@huawei.com>
Date: Fri, 6 Dec 2024 13:35:54 -0500
Subject: [PATCH] test/ring: fix init with custom number of lcores
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 2cf3a8d35d2db1cee1523e6e9ef5553432fbf56f ]
ring_stress_autotest fails to initialize the ring when RTE_MAX_LCORE value
is not a number of 2.
There is a flaw in calculation required number of elements in the ring.
Fix it by aligning number of elements to next power of 2.
Fixes: bf28df24e915 ("test/ring: add contention stress test")
Reported-by: Phanendra Vukkisala <pvukkisala@marvell.com>
Signed-off-by: Konstantin Ananyev <konstantin.ananyev@huawei.com>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
app/test/test_ring_stress_impl.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/test/test_ring_stress_impl.h b/app/test/test_ring_stress_impl.h
index 62f046a91a..373091957b 100644
--- a/app/test/test_ring_stress_impl.h
+++ b/app/test/test_ring_stress_impl.h
@@ -295,7 +295,7 @@ mt1_init(struct rte_ring **rng, void **data, uint32_t num)
*data = elm;
/* alloc ring */
- nr = 2 * num;
+ nr = rte_align32pow2(2 * num);
sz = rte_ring_get_memsize(nr);
r = rte_zmalloc(NULL, sz, __alignof__(*r));
if (r == NULL) {
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:00.800358318 +0800
+++ 0001-test-ring-fix-init-with-custom-number-of-lcores.patch 2025-02-18 19:39:00.388244089 +0800
@@ -1 +1 @@
-From 2cf3a8d35d2db1cee1523e6e9ef5553432fbf56f Mon Sep 17 00:00:00 2001
+From 8c0b8af3bd76eb9d19ade4503b72a901b6e9780b Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 2cf3a8d35d2db1cee1523e6e9ef5553432fbf56f ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -26 +28 @@
-index 8b0bfb11fe..ee5274aeef 100644
+index 62f046a91a..373091957b 100644
@@ -29 +31 @@
-@@ -297,7 +297,7 @@ mt1_init(struct rte_ring **rng, void **data, uint32_t num)
+@@ -295,7 +295,7 @@ mt1_init(struct rte_ring **rng, void **data, uint32_t num)
@@ -36 +38 @@
- r = rte_zmalloc(NULL, sz, alignof(typeof(*r)));
+ r = rte_zmalloc(NULL, sz, __alignof__(*r));
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'vhost: clear ring addresses when getting vring base' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
2025-02-18 12:33 ` patch 'test/ring: fix init with custom number of lcores' " Xueming Li
@ 2025-02-18 12:33 ` Xueming Li
2025-02-18 12:33 ` patch 'vhost: check GSO size validity' " Xueming Li
` (85 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:33 UTC (permalink / raw)
To: Jianping Zhao; +Cc: xuemingl, Maxime Coquelin, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=9148bf9355898108b2351a153293b2f8932dd460
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 9148bf9355898108b2351a153293b2f8932dd460 Mon Sep 17 00:00:00 2001
From: Jianping Zhao <zhao305149619@gmail.com>
Date: Wed, 27 Nov 2024 10:03:49 +0800
Subject: [PATCH] vhost: clear ring addresses when getting vring base
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 1846fe767f00a9d0dade333e7838f81e6721b694 ]
Clear ring addresses during vring base retrieval to handle guest reboot
scenarios correctly. This is particularly important for vdpa-blk devices
where the following issue occurs:
When a guest OS with vdpa-blk device reboots, during UEFI stage, only
one vring is actually used and configured. However, QEMU still sends
enable messages for all configured queues. The remaining queues retain
their addresses from before reboot, which reference invalid memory
mappings in the rebooted guest.
The issue manifests in vq_is_ready():
static bool
vq_is_ready(struct virtio_net *dev, struct vhost_virtqueue *vq)
{
/* Only checks pointer validity, not address freshness */
rings_ok = vq->desc && vq->avail && vq->used;
...
}
vq_is_ready() incorrectly considers these queues as ready because it
only checks if desc/avail/used pointers are non-NULL, but cannot
detect that these addresses are stale from the previous boot.
Clear the ring addresses in vhost_user_get_vring_base() to force
the guest driver to reconfigure them before use. This ensures that
vq_is_ready() will return false for queues with stale addresses
until they are properly reconfigured by the guest driver.
Fixes: 3ea7052f4b1b ("vhost: postpone rings addresses translation")
Signed-off-by: Jianping Zhao <zhao305149619@gmail.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
.mailmap | 1 +
lib/vhost/vhost_user.c | 1 +
2 files changed, 2 insertions(+)
diff --git a/.mailmap b/.mailmap
index ff5b0821ba..71967f7247 100644
--- a/.mailmap
+++ b/.mailmap
@@ -638,6 +638,7 @@ Jia He <justin.he@arm.com> <jia.he@hxt-semitech.com>
Jianbo Liu <jianbo.liu@arm.com> <jianbo.liu@linaro.org>
Jianfeng Tan <jianfeng.tan@intel.com>
Jiangu Zhao <zhaojg@arraynetworks.com.cn>
+Jianping Zhao <zhao305149619@gmail.com>
Jianwei Ma <jianwei.ma@intel.com>
Jianwei Mei <jianweix.mei@intel.com>
Jiaqi Min <jiaqix.min@intel.com>
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index 5b6c90437c..14808bd5bc 100644
--- a/lib/vhost/vhost_user.c
+++ b/lib/vhost/vhost_user.c
@@ -2201,6 +2201,7 @@ vhost_user_get_vring_base(struct virtio_net **pdev,
rte_rwlock_write_lock(&vq->access_lock);
vring_invalidate(dev, vq);
+ memset(&vq->ring_addrs, 0, sizeof(struct vhost_vring_addr));
rte_rwlock_write_unlock(&vq->access_lock);
return RTE_VHOST_MSG_RESULT_REPLY;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:00.833629012 +0800
+++ 0002-vhost-clear-ring-addresses-when-getting-vring-base.patch 2025-02-18 19:39:00.398244087 +0800
@@ -1 +1 @@
-From 1846fe767f00a9d0dade333e7838f81e6721b694 Mon Sep 17 00:00:00 2001
+From 9148bf9355898108b2351a153293b2f8932dd460 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 1846fe767f00a9d0dade333e7838f81e6721b694 ]
@@ -36 +38,0 @@
-Cc: stable@dpdk.org
@@ -46 +48 @@
-index b90ff0444c..cc1ffe1ad9 100644
+index ff5b0821ba..71967f7247 100644
@@ -49 +51,2 @@
-@@ -674,6 +674,7 @@ Jianbo Liu <jianbo.liu@arm.com> <jianbo.liu@linaro.org>
+@@ -638,6 +638,7 @@ Jia He <justin.he@arm.com> <jia.he@hxt-semitech.com>
+ Jianbo Liu <jianbo.liu@arm.com> <jianbo.liu@linaro.org>
@@ -51 +53,0 @@
- Jiang Yu <yux.jiang@intel.com>
@@ -58 +60 @@
-index 6d92ad904e..52d8078d7c 100644
+index 5b6c90437c..14808bd5bc 100644
@@ -61 +63 @@
-@@ -2277,6 +2277,7 @@ vhost_user_get_vring_base(struct virtio_net **pdev,
+@@ -2201,6 +2201,7 @@ vhost_user_get_vring_base(struct virtio_net **pdev,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'vhost: check GSO size validity' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
2025-02-18 12:33 ` patch 'test/ring: fix init with custom number of lcores' " Xueming Li
2025-02-18 12:33 ` patch 'vhost: clear ring addresses when getting vring base' " Xueming Li
@ 2025-02-18 12:33 ` Xueming Li
2025-02-18 12:33 ` patch 'vhost: fix log when setting max queue num' " Xueming Li
` (84 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:33 UTC (permalink / raw)
To: Yunjian Wang; +Cc: xuemingl, Maxime Coquelin, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=6bce3ec356d70103851656c31ed61244fc3cc346
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 6bce3ec356d70103851656c31ed61244fc3cc346 Mon Sep 17 00:00:00 2001
From: Yunjian Wang <wangyunjian@huawei.com>
Date: Fri, 20 Dec 2024 11:45:09 +0800
Subject: [PATCH] vhost: check GSO size validity
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 7023f3e532787eec7be674efb7a4aa54f1626b6c ]
The value of tso_segsz cannot be 0, instead check that value of
gso_size was set.
Fixes: d0cf91303d73 ("vhost: add Tx offload capabilities")
Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
lib/vhost/virtio_net.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lib/vhost/virtio_net.c b/lib/vhost/virtio_net.c
index 49c2052eba..25adf94ffa 100644
--- a/lib/vhost/virtio_net.c
+++ b/lib/vhost/virtio_net.c
@@ -2741,6 +2741,9 @@ vhost_dequeue_offload_legacy(struct virtio_net *dev, struct virtio_net_hdr *hdr,
}
if (hdr->gso_type != VIRTIO_NET_HDR_GSO_NONE) {
+ if (hdr->gso_size == 0)
+ goto error;
+
switch (hdr->gso_type & ~VIRTIO_NET_HDR_GSO_ECN) {
case VIRTIO_NET_HDR_GSO_TCPV4:
case VIRTIO_NET_HDR_GSO_TCPV6:
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:00.869052706 +0800
+++ 0003-vhost-check-GSO-size-validity.patch 2025-02-18 19:39:00.398244087 +0800
@@ -1 +1 @@
-From 7023f3e532787eec7be674efb7a4aa54f1626b6c Mon Sep 17 00:00:00 2001
+From 6bce3ec356d70103851656c31ed61244fc3cc346 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 7023f3e532787eec7be674efb7a4aa54f1626b6c ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
-index 69901ab3b5..2ac5bc29a3 100644
+index 49c2052eba..25adf94ffa 100644
@@ -22 +24 @@
-@@ -2733,6 +2733,9 @@ vhost_dequeue_offload_legacy(struct virtio_net *dev, struct virtio_net_hdr *hdr,
+@@ -2741,6 +2741,9 @@ vhost_dequeue_offload_legacy(struct virtio_net *dev, struct virtio_net_hdr *hdr,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'vhost: fix log when setting max queue num' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (2 preceding siblings ...)
2025-02-18 12:33 ` patch 'vhost: check GSO size validity' " Xueming Li
@ 2025-02-18 12:33 ` Xueming Li
2025-02-18 12:34 ` patch 'vhost: reset packets count when not ready' " Xueming Li
` (83 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:33 UTC (permalink / raw)
To: Maxime Coquelin
Cc: xuemingl, Ilya Maximets, Chenbo Xia, Kevin Traynor, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=e099c1e17e8dda291975db45ef6298a6c87e84cc
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From e099c1e17e8dda291975db45ef6298a6c87e84cc Mon Sep 17 00:00:00 2001
From: Maxime Coquelin <maxime.coquelin@redhat.com>
Date: Thu, 9 Jan 2025 15:31:30 +0100
Subject: [PATCH] vhost: fix log when setting max queue num
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 274292190d1384b028552adc601dda4b197f2417 ]
rte_vhost_driver_set_max_queue_num API returns early when
called for a Vhost-user device, as this API is intended to
limit the maximum number of queue pairs supported by VDUSE
devices. However, a log mentioning the maximum number of
queue pairs is being set is emitted unconditionally, which
may confuse the end user.
This patch moves this log after the backend type is
checked, so that it is only called with VDUSE backends.
The check on the requested value is also moved at the same
place.
Fixes: e1808999d36b ("vhost: restrict set max queue pair API to VDUSE")
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Reviewed-by: Ilya Maximets <i.maximets@ovn.org>
Reviewed-by: Chenbo Xia <chenbox@nvidia.com>
Acked-by: Kevin Traynor <ktraynor@redhat.com>
---
lib/vhost/socket.c | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/lib/vhost/socket.c b/lib/vhost/socket.c
index ffb8518e74..6cf76eb7ae 100644
--- a/lib/vhost/socket.c
+++ b/lib/vhost/socket.c
@@ -849,14 +849,6 @@ rte_vhost_driver_set_max_queue_num(const char *path, uint32_t max_queue_pairs)
struct vhost_user_socket *vsocket;
int ret = 0;
- VHOST_LOG_CONFIG(path, INFO, "Setting max queue pairs to %u\n", max_queue_pairs);
-
- if (max_queue_pairs > VHOST_MAX_QUEUE_PAIRS) {
- VHOST_LOG_CONFIG(path, ERR, "Library only supports up to %u queue pairs\n",
- VHOST_MAX_QUEUE_PAIRS);
- return -1;
- }
-
pthread_mutex_lock(&vhost_user.mutex);
vsocket = find_vhost_user_socket(path);
if (!vsocket) {
@@ -876,6 +868,15 @@ rte_vhost_driver_set_max_queue_num(const char *path, uint32_t max_queue_pairs)
goto unlock_exit;
}
+ VHOST_LOG_CONFIG(path, INFO, "Setting max queue pairs to %u", max_queue_pairs);
+
+ if (max_queue_pairs > VHOST_MAX_QUEUE_PAIRS) {
+ VHOST_LOG_CONFIG(path, ERR, "Library only supports up to %u queue pairs",
+ VHOST_MAX_QUEUE_PAIRS);
+ ret = -1;
+ goto unlock_exit;
+ }
+
vsocket->max_queue_pairs = max_queue_pairs;
unlock_exit:
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:00.901479401 +0800
+++ 0004-vhost-fix-log-when-setting-max-queue-num.patch 2025-02-18 19:39:00.398244087 +0800
@@ -1 +1 @@
-From 274292190d1384b028552adc601dda4b197f2417 Mon Sep 17 00:00:00 2001
+From e099c1e17e8dda291975db45ef6298a6c87e84cc Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 274292190d1384b028552adc601dda4b197f2417 ]
@@ -19 +21,0 @@
-Cc: stable@dpdk.org
@@ -30 +32 @@
-index d29d15494c..05a7e5902f 100644
+index ffb8518e74..6cf76eb7ae 100644
@@ -33 +35 @@
-@@ -844,14 +844,6 @@ rte_vhost_driver_set_max_queue_num(const char *path, uint32_t max_queue_pairs)
+@@ -849,14 +849,6 @@ rte_vhost_driver_set_max_queue_num(const char *path, uint32_t max_queue_pairs)
@@ -37 +39 @@
-- VHOST_CONFIG_LOG(path, INFO, "Setting max queue pairs to %u", max_queue_pairs);
+- VHOST_LOG_CONFIG(path, INFO, "Setting max queue pairs to %u\n", max_queue_pairs);
@@ -40 +42 @@
-- VHOST_CONFIG_LOG(path, ERR, "Library only supports up to %u queue pairs",
+- VHOST_LOG_CONFIG(path, ERR, "Library only supports up to %u queue pairs\n",
@@ -48 +50 @@
-@@ -872,6 +864,15 @@ rte_vhost_driver_set_max_queue_num(const char *path, uint32_t max_queue_pairs)
+@@ -876,6 +868,15 @@ rte_vhost_driver_set_max_queue_num(const char *path, uint32_t max_queue_pairs)
@@ -52 +54 @@
-+ VHOST_CONFIG_LOG(path, INFO, "Setting max queue pairs to %u", max_queue_pairs);
++ VHOST_LOG_CONFIG(path, INFO, "Setting max queue pairs to %u", max_queue_pairs);
@@ -55 +57 @@
-+ VHOST_CONFIG_LOG(path, ERR, "Library only supports up to %u queue pairs",
++ VHOST_LOG_CONFIG(path, ERR, "Library only supports up to %u queue pairs",
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'vhost: reset packets count when not ready' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (3 preceding siblings ...)
2025-02-18 12:33 ` patch 'vhost: fix log when setting max queue num' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'crypto/cnxk: fix build with GCC 15' " Xueming Li
` (82 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Maxime Coquelin; +Cc: xuemingl, David Marchand, Chenbo Xia, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=d1e77f15819cfb99a5e655c0e36db6d3534efb21
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From d1e77f15819cfb99a5e655c0e36db6d3534efb21 Mon Sep 17 00:00:00 2001
From: Maxime Coquelin <maxime.coquelin@redhat.com>
Date: Thu, 16 Jan 2025 10:54:14 +0100
Subject: [PATCH] vhost: reset packets count when not ready
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 8b96508af6021d868052545a76ef2ce5219b7702 ]
This patch fixes the rte_vhost_dequeue_burst return value
when the virtqueue is not ready. Without it, a discrepancy
between the packet array and its size is faced by the caller
of this API when the virtqueue is not ready.
Fixes: 9fc93a1e2320 ("vhost: fix virtqueue access check in datapath")
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
Reviewed-by: Chenbo Xia <chenbox@nvidia.com>
---
lib/vhost/virtio_net.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lib/vhost/virtio_net.c b/lib/vhost/virtio_net.c
index 25adf94ffa..d81b518462 100644
--- a/lib/vhost/virtio_net.c
+++ b/lib/vhost/virtio_net.c
@@ -3601,6 +3601,8 @@ rte_vhost_dequeue_burst(int vid, uint16_t queue_id,
rte_rwlock_read_unlock(&vq->access_lock);
virtio_dev_vring_translate(dev, vq);
+
+ count = 0;
goto out_no_unlock;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:00.932503295 +0800
+++ 0005-vhost-reset-packets-count-when-not-ready.patch 2025-02-18 19:39:00.408244086 +0800
@@ -1 +1 @@
-From 8b96508af6021d868052545a76ef2ce5219b7702 Mon Sep 17 00:00:00 2001
+From d1e77f15819cfb99a5e655c0e36db6d3534efb21 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 8b96508af6021d868052545a76ef2ce5219b7702 ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +24 @@
-index 2ac5bc29a3..d85c0c9d42 100644
+index 25adf94ffa..d81b518462 100644
@@ -25 +27 @@
-@@ -3632,6 +3632,8 @@ rte_vhost_dequeue_burst(int vid, uint16_t queue_id,
+@@ -3601,6 +3601,8 @@ rte_vhost_dequeue_burst(int vid, uint16_t queue_id,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'crypto/cnxk: fix build with GCC 15' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (4 preceding siblings ...)
2025-02-18 12:34 ` patch 'vhost: reset packets count when not ready' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/thunderx/base: " Xueming Li
` (81 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, David Marchand, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=448898cf70fadf25518e85bf719cbaf6779e5a00
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 448898cf70fadf25518e85bf719cbaf6779e5a00 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Mon, 20 Jan 2025 15:23:38 -0800
Subject: [PATCH] crypto/cnxk: fix build with GCC 15
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 224e37a6a442b6a1f6d179b1756383f1a80cf3ed ]
GCC 15 produces warnings about uninitialized variables.
In file included from ../lib/mbuf/rte_mbuf.h:36,
from ../lib/cryptodev/rte_crypto.h:15,
from ../lib/cryptodev/rte_cryptodev.h:19,
from ../drivers/crypto/cnxk/cn9k_cryptodev_ops.c:5:
In function ‘pdcp_chain_sg1_prep’,
inlined from ‘cpt_pdcp_chain_alg_prep’ at ../drivers/crypto/cnxk/cnxk_se.h:1621:11,
inlined from ‘fill_pdcp_chain_params’ at ../drivers/crypto/cnxk/cnxk_se.h:3114:8,
inlined from ‘cpt_sym_inst_fill’ at ../drivers/crypto/cnxk/cnxk_se.h:3364:9,
inlined from ‘cn9k_cpt_inst_prep’ at ../drivers/crypto/cnxk/cn9k_cryptodev_ops.c:93:10:
../lib/eal/include/rte_common.h:469:38: warning: ‘fc_params.meta_buf.vaddr’ may be used uninitialized [-Wmaybe-uninitialized]
469 | #define RTE_PTR_ADD(ptr, x) ((void*)((uintptr_t)(ptr) + (x)))
| ^~~~~~~~~~~~~~~~
../drivers/common/cnxk/roc_platform.h:47:34: note: in expansion of macro ‘RTE_PTR_ADD’
47 | #define PLT_PTR_ADD RTE_PTR_ADD
| ^~~~~~~~~~~
../drivers/crypto/cnxk/cnxk_se.h:900:19: note: in expansion of macro ‘PLT_PTR_ADD’
900 | m_vaddr = PLT_PTR_ADD(m_vaddr, ROC_SE_OFF_CTRL_LEN + PLT_ALIGN_CEIL(hdr_len, 8));
| ^~~~~~~~~~~
In file included from ../drivers/crypto/cnxk/cn9k_cryptodev_ops.c:20:
../drivers/crypto/cnxk/cnxk_se.h: In function ‘cn9k_cpt_inst_prep’:
../drivers/crypto/cnxk/cnxk_se.h:3008:33: note: ‘fc_params.meta_buf.vaddr’ was declared here
3008 | struct roc_se_fc_params fc_params;
| ^~~~~~~~~
In function ‘pdcp_chain_sg1_prep’,
inlined from ‘cpt_pdcp_chain_alg_prep’ at ../drivers/crypto/cnxk/cnxk_se.h:1621:11,
inlined from ‘fill_pdcp_chain_params’ at ../drivers/crypto/cnxk/cnxk_se.h:3114:8,
inlined from ‘cpt_sym_inst_fill’ at ../drivers/crypto/cnxk/cnxk_se.h:3364:9,
inlined from ‘cn9k_cpt_inst_prep’ at ../drivers/crypto/cnxk/cn9k_cryptodev_ops.c:82:10:
../lib/eal/include/rte_common.h:469:38: warning: ‘fc_params.meta_buf.vaddr’ may be used uninitialized [-Wmaybe-uninitialized]
469 | #define RTE_PTR_ADD(ptr, x) ((void*)((uintptr_t)(ptr) + (x)))
| ^~~~~~~~~~~~~~~~
../drivers/common/cnxk/roc_platform.h:47:34: note: in expansion of macro ‘RTE_PTR_ADD’
47 | #define PLT_PTR_ADD RTE_PTR_ADD
| ^~~~~~~~~~~
../drivers/crypto/cnxk/cnxk_se.h:900:19: note: in expansion of macro ‘PLT_PTR_ADD’
900 | m_vaddr = PLT_PTR_ADD(m_vaddr, ROC_SE_OFF_CTRL_LEN + PLT_ALIGN_CEIL(hdr_len, 8));
| ^~~~~~~~~~~
../drivers/crypto/cnxk/cnxk_se.h: In function ‘cn9k_cpt_inst_prep’:
../drivers/crypto/cnxk/cnxk_se.h:3008:33: note: ‘fc_params.meta_buf.vaddr’ was declared here
3008 | struct roc_se_fc_params fc_params;
| ^~~~~~~~~
Fixes: d3bff77cc371 ("crypto/cnxk: separate out PDCP chain datapath")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: David Marchand <david.marchand@redhat.com>
---
drivers/crypto/cnxk/cnxk_se.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/crypto/cnxk/cnxk_se.h b/drivers/crypto/cnxk/cnxk_se.h
index cf163e0208..61f1c85857 100644
--- a/drivers/crypto/cnxk/cnxk_se.h
+++ b/drivers/crypto/cnxk/cnxk_se.h
@@ -3009,7 +3009,7 @@ fill_pdcp_chain_params(struct rte_crypto_op *cop, struct cnxk_se_sess *sess,
{
uint32_t ci_data_length, ci_data_offset, a_data_length, a_data_offset;
struct rte_crypto_sym_op *sym_op = cop->sym;
- struct roc_se_fc_params fc_params;
+ struct roc_se_fc_params fc_params = { };
struct rte_mbuf *m_src, *m_dst;
uint8_t cpt_op = sess->cpt_op;
uint64_t d_offs, d_lens;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:00.964886390 +0800
+++ 0006-crypto-cnxk-fix-build-with-GCC-15.patch 2025-02-18 19:39:00.408244086 +0800
@@ -1 +1 @@
-From 224e37a6a442b6a1f6d179b1756383f1a80cf3ed Mon Sep 17 00:00:00 2001
+From 448898cf70fadf25518e85bf719cbaf6779e5a00 Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 224e37a6a442b6a1f6d179b1756383f1a80cf3ed ]
@@ -54 +56,0 @@
-Cc: stable@dpdk.org
@@ -63 +65 @@
-index 7262a49945..649e38c495 100644
+index cf163e0208..61f1c85857 100644
@@ -66 +68 @@
-@@ -3005,7 +3005,7 @@ fill_pdcp_chain_params(struct rte_crypto_op *cop, struct cnxk_se_sess *sess,
+@@ -3009,7 +3009,7 @@ fill_pdcp_chain_params(struct rte_crypto_op *cop, struct cnxk_se_sess *sess,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/thunderx/base: fix build with GCC 15' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (5 preceding siblings ...)
2025-02-18 12:34 ` patch 'crypto/cnxk: fix build with GCC 15' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'eal/x86: fix some intrinsics header include for Windows' " Xueming Li
` (80 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, David Marchand, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=68dee34412e088bc904f639b0428b6a9a9543c72
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 68dee34412e088bc904f639b0428b6a9a9543c72 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Mon, 20 Jan 2025 15:23:39 -0800
Subject: [PATCH] net/thunderx/base: fix build with GCC 15
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit e7133f8fb39f506dc1eef02c2927acda949ca000 ]
Gcc 15 now produces warning with the base code of Thunderx driver.
The issue is that Gcc now defaults to C23 mode, and the standards
gods have decided that the result of partial initialization of a union
is not defined for other fields.
The fix is to use an empty initializer which forces full initialization.
[2377/3224] Compiling C object drivers/net/thunderx/base/libnicvf_base.a.p/nicvf_mbox.c.o
In function ‘nicvf_mbox_send_msg_to_pf_raw’,
inlined from ‘nicvf_mbox_send_async_msg_to_pf’ at ../drivers/net/thunderx/base/nicvf_mbox.c:70:2,
inlined from ‘nicvf_mbox_cfg_done’ at ../drivers/net/thunderx/base/nicvf_mbox.c:468:2:
../drivers/net/thunderx/base/nicvf_mbox.c:59:17: warning: ‘mbx’ is used uninitialized [-Wuninitialized]
59 | nicvf_reg_write(nic, mbx_addr, *mbx_data);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../drivers/net/thunderx/base/nicvf_mbox.c: In function ‘nicvf_mbox_cfg_done’:
../drivers/net/thunderx/base/nicvf_mbox.c:465:24: note: ‘mbx’ declared here
465 | struct nic_mbx mbx = { .msg = { 0 } };
| ^~~
In function ‘nicvf_mbox_send_msg_to_pf_raw’,
inlined from ‘nicvf_mbox_send_async_msg_to_pf’ at ../drivers/net/thunderx/base/nicvf_mbox.c:70:2,
inlined from ‘nicvf_mbox_link_change’ at ../drivers/net/thunderx/base/nicvf_mbox.c:477:2:
../drivers/net/thunderx/base/nicvf_mbox.c:59:17: warning: ‘mbx’ is used uninitialized [-Wuninitialized]
59 | nicvf_reg_write(nic, mbx_addr, *mbx_data);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../drivers/net/thunderx/base/nicvf_mbox.c: In function ‘nicvf_mbox_link_change’:
../drivers/net/thunderx/base/nicvf_mbox.c:474:24: note: ‘mbx’ declared here
474 | struct nic_mbx mbx = { .msg = { 0 } };
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: David Marchand <david.marchand@redhat.com>
---
drivers/net/thunderx/base/nicvf_mbox.c | 42 +++++++++++++-------------
1 file changed, 21 insertions(+), 21 deletions(-)
diff --git a/drivers/net/thunderx/base/nicvf_mbox.c b/drivers/net/thunderx/base/nicvf_mbox.c
index 0e0176974d..29407f75fa 100644
--- a/drivers/net/thunderx/base/nicvf_mbox.c
+++ b/drivers/net/thunderx/base/nicvf_mbox.c
@@ -212,7 +212,7 @@ int
nicvf_mbox_set_mac_addr(struct nicvf *nic,
const uint8_t mac[NICVF_MAC_ADDR_SIZE])
{
- struct nic_mbx mbx = { .msg = {0} };
+ struct nic_mbx mbx = { };
int i;
mbx.msg.msg = NIC_MBOX_MSG_SET_MAC;
@@ -226,7 +226,7 @@ nicvf_mbox_set_mac_addr(struct nicvf *nic,
int
nicvf_mbox_config_cpi(struct nicvf *nic, uint32_t qcnt)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_CPI_CFG;
mbx.cpi_cfg.vf_id = nic->vf_id;
@@ -239,7 +239,7 @@ nicvf_mbox_config_cpi(struct nicvf *nic, uint32_t qcnt)
int
nicvf_mbox_get_rss_size(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_RSS_SIZE;
mbx.rss_size.vf_id = nic->vf_id;
@@ -251,7 +251,7 @@ nicvf_mbox_get_rss_size(struct nicvf *nic)
int
nicvf_mbox_config_rss(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
struct nicvf_rss_reta_info *rss = &nic->rss_info;
size_t tot_len = rss->rss_size;
size_t cur_len;
@@ -284,7 +284,7 @@ int
nicvf_mbox_rq_config(struct nicvf *nic, uint16_t qidx,
struct pf_rq_cfg *pf_rq_cfg)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_RQ_CFG;
mbx.rq.qs_num = nic->vf_id;
@@ -296,7 +296,7 @@ nicvf_mbox_rq_config(struct nicvf *nic, uint16_t qidx,
int
nicvf_mbox_sq_config(struct nicvf *nic, uint16_t qidx)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_SQ_CFG;
mbx.sq.qs_num = nic->vf_id;
@@ -309,7 +309,7 @@ nicvf_mbox_sq_config(struct nicvf *nic, uint16_t qidx)
int
nicvf_mbox_qset_config(struct nicvf *nic, struct pf_qs_cfg *qs_cfg)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
#if NICVF_BYTE_ORDER == NICVF_BIG_ENDIAN
qs_cfg->be = 1;
@@ -325,7 +325,7 @@ nicvf_mbox_qset_config(struct nicvf *nic, struct pf_qs_cfg *qs_cfg)
int
nicvf_mbox_request_sqs(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
size_t i;
assert_primary(nic);
@@ -346,7 +346,7 @@ nicvf_mbox_request_sqs(struct nicvf *nic)
int
nicvf_mbox_rq_drop_config(struct nicvf *nic, uint16_t qidx, bool enable)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
struct pf_rq_drop_cfg *drop_cfg;
/* Enable CQ drop to reserve sufficient CQEs for all tx packets */
@@ -365,7 +365,7 @@ nicvf_mbox_rq_drop_config(struct nicvf *nic, uint16_t qidx, bool enable)
int
nicvf_mbox_update_hw_max_frs(struct nicvf *nic, uint16_t mtu)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_SET_MAX_FRS;
mbx.frs.max_frs = mtu;
@@ -376,7 +376,7 @@ nicvf_mbox_update_hw_max_frs(struct nicvf *nic, uint16_t mtu)
int
nicvf_mbox_rq_sync(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
/* Make sure all packets in the pipeline are written back into mem */
mbx.msg.msg = NIC_MBOX_MSG_RQ_SW_SYNC;
@@ -387,7 +387,7 @@ nicvf_mbox_rq_sync(struct nicvf *nic)
int
nicvf_mbox_rq_bp_config(struct nicvf *nic, uint16_t qidx, bool enable)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_RQ_BP_CFG;
mbx.rq.qs_num = nic->vf_id;
@@ -401,7 +401,7 @@ nicvf_mbox_rq_bp_config(struct nicvf *nic, uint16_t qidx, bool enable)
int
nicvf_mbox_loopback_config(struct nicvf *nic, bool enable)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.lbk.msg = NIC_MBOX_MSG_LOOPBACK;
mbx.lbk.vf_id = nic->vf_id;
@@ -414,7 +414,7 @@ nicvf_mbox_reset_stat_counters(struct nicvf *nic, uint16_t rx_stat_mask,
uint8_t tx_stat_mask, uint16_t rq_stat_mask,
uint16_t sq_stat_mask)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.reset_stat.msg = NIC_MBOX_MSG_RESET_STAT_COUNTER;
mbx.reset_stat.rx_stat_mask = rx_stat_mask;
@@ -427,7 +427,7 @@ nicvf_mbox_reset_stat_counters(struct nicvf *nic, uint16_t rx_stat_mask,
int
nicvf_mbox_set_link_up_down(struct nicvf *nic, bool enable)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.lbk.msg = NIC_MBOX_MSG_SET_LINK;
mbx.lbk.vf_id = nic->vf_id;
@@ -439,7 +439,7 @@ nicvf_mbox_set_link_up_down(struct nicvf *nic, bool enable)
int
nicvf_mbox_change_mode(struct nicvf *nic, struct change_link_mode *cfg)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.mode.msg = NIC_MBOX_MSG_CHANGE_MODE;
mbx.mode.vf_id = nic->vf_id;
@@ -453,7 +453,7 @@ nicvf_mbox_change_mode(struct nicvf *nic, struct change_link_mode *cfg)
void
nicvf_mbox_shutdown(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_SHUTDOWN;
nicvf_mbox_send_msg_to_pf(nic, &mbx);
@@ -462,7 +462,7 @@ nicvf_mbox_shutdown(struct nicvf *nic)
void
nicvf_mbox_cfg_done(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_CFG_DONE;
nicvf_mbox_send_async_msg_to_pf(nic, &mbx);
@@ -471,7 +471,7 @@ nicvf_mbox_cfg_done(struct nicvf *nic)
void
nicvf_mbox_link_change(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_BGX_LINK_CHANGE;
nicvf_mbox_send_async_msg_to_pf(nic, &mbx);
@@ -480,7 +480,7 @@ nicvf_mbox_link_change(struct nicvf *nic)
void
nicvf_mbox_reset_xcast(struct nicvf *nic)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.msg.msg = NIC_MBOX_MSG_RESET_XCAST;
nicvf_mbox_send_msg_to_pf(nic, &mbx);
@@ -489,7 +489,7 @@ nicvf_mbox_reset_xcast(struct nicvf *nic)
int
nicvf_mbox_set_xcast(struct nicvf *nic, uint8_t mode, uint64_t mac)
{
- struct nic_mbx mbx = { .msg = { 0 } };
+ struct nic_mbx mbx = { };
mbx.xcast.msg = NIC_MBOX_MSG_SET_XCAST;
mbx.xcast.mode = mode;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.001152583 +0800
+++ 0007-net-thunderx-base-fix-build-with-GCC-15.patch 2025-02-18 19:39:00.418244084 +0800
@@ -1 +1 @@
-From e7133f8fb39f506dc1eef02c2927acda949ca000 Mon Sep 17 00:00:00 2001
+From 68dee34412e088bc904f639b0428b6a9a9543c72 Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit e7133f8fb39f506dc1eef02c2927acda949ca000 ]
@@ -36,2 +38,0 @@
-
-Cc: stable@dpdk.org
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'eal/x86: fix some intrinsics header include for Windows' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (6 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/thunderx/base: " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'test/bonding: fix active backup receive test' " Xueming Li
` (79 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Andre Muezerie; +Cc: xuemingl, Pier Damouny, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=0608e13c5705e5086fe6f809697a988a833ecd27
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 0608e13c5705e5086fe6f809697a988a833ecd27 Mon Sep 17 00:00:00 2001
From: Andre Muezerie <andremue@linux.microsoft.com>
Date: Tue, 14 Jan 2025 08:21:13 -0800
Subject: [PATCH] eal/x86: fix some intrinsics header include for Windows
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 5b856206c74bbcf19e12cafa15382a7e15b0a1b5 ]
Error reported:
../lib/net/net_crc_sse.c:49:17: error: call to undeclared function
'_mm_clmulepi64_si128'; ISO C99 and later do not support implicit
function declarations [-Wimplicit-function-declaration]
The fix is to remove the unnecessary ifdef around the inclusion of
header file immintrin.h. This header also contains functions that do
not require AVX instructions, so should not be included only when AVX
is available.
Bugzilla ID: 1595
Fixes: da826b7135a4 ("eal: introduce ymm type for AVX 256-bit")
Reported-by: Pier Damouny <pdamouny@nvidia.com>
Signed-off-by: Andre Muezerie <andremue@linux.microsoft.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
.mailmap | 2 +-
lib/eal/x86/include/rte_vect.h | 2 --
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/.mailmap b/.mailmap
index 71967f7247..861d69289f 100644
--- a/.mailmap
+++ b/.mailmap
@@ -1131,7 +1131,7 @@ Petr Houska <t-pehous@microsoft.com>
Phanendra Vukkisala <pvukkisala@marvell.com>
Phil Yang <phil.yang@arm.com>
Philip Prindeville <philipp@redfish-solutions.com>
-Pier Damouny <pdamouny@nvidia.com>
+Pier Damouny <pdamouny@nvidia.com>
Pierre Pfister <ppfister@cisco.com>
Piotr Azarewicz <piotr.azarewicz@intel.com> <piotrx.t.azarewicz@intel.com>
Piotr Bartosiewicz <piotr.bartosiewicz@atendesoftware.pl>
diff --git a/lib/eal/x86/include/rte_vect.h b/lib/eal/x86/include/rte_vect.h
index 560f9e4db3..8c1d0dd830 100644
--- a/lib/eal/x86/include/rte_vect.h
+++ b/lib/eal/x86/include/rte_vect.h
@@ -18,9 +18,7 @@
#if defined(__ICC) || defined(_WIN64)
#include <smmintrin.h> /* SSE4 */
-#if defined(__AVX__)
#include <immintrin.h>
-#endif
#else
#include <x86intrin.h>
#endif
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.035313478 +0800
+++ 0008-eal-x86-fix-some-intrinsics-header-include-for-Windo.patch 2025-02-18 19:39:00.418244084 +0800
@@ -1 +1 @@
-From 5b856206c74bbcf19e12cafa15382a7e15b0a1b5 Mon Sep 17 00:00:00 2001
+From 0608e13c5705e5086fe6f809697a988a833ecd27 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 5b856206c74bbcf19e12cafa15382a7e15b0a1b5 ]
@@ -18 +20,0 @@
-Cc: stable@dpdk.org
@@ -29 +31 @@
-index cc1ffe1ad9..94e12acbd4 100644
+index 71967f7247..861d69289f 100644
@@ -32 +34 @@
-@@ -1192,7 +1192,7 @@ Petr Houska <t-pehous@microsoft.com>
+@@ -1131,7 +1131,7 @@ Petr Houska <t-pehous@microsoft.com>
@@ -42 +44 @@
-index 5ac3ccfd82..5fdcd632ac 100644
+index 560f9e4db3..8c1d0dd830 100644
@@ -45 +47 @@
-@@ -19,9 +19,7 @@
+@@ -18,9 +18,7 @@
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'test/bonding: fix active backup receive test' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (7 preceding siblings ...)
2025-02-18 12:34 ` patch 'eal/x86: fix some intrinsics header include for Windows' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/bonding: fix dedicated queue setup' " Xueming Li
` (78 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, Huisong Li, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=d0d04dead13a23640736a8b83a27bda0164f45be
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From d0d04dead13a23640736a8b83a27bda0164f45be Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 13 Dec 2024 09:17:14 -0800
Subject: [PATCH] test/bonding: fix active backup receive test
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit eb29e625ce41b50898efc8e2618b7eeb128460ed ]
The test had incorrect assumptions about how active backup
should work. When in active backup mode, the secondary (not primary)
ports should be ignored. The test was always broken since initially
written but earlier bug was masking the part of the test which
tested non-primary ports.
Bugzilla ID: 1589
Fixes: 112ce3917674 ("test/bonding: fix loop on members")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Huisong Li <lihuisong@huawei.com>
Tested-by: Huisong Li <lihuisong@huawei.com>
---
app/test/test_link_bonding.c | 74 +++++++++++++++++-------------------
1 file changed, 34 insertions(+), 40 deletions(-)
diff --git a/app/test/test_link_bonding.c b/app/test/test_link_bonding.c
index b53f512815..19b064771a 100644
--- a/app/test/test_link_bonding.c
+++ b/app/test/test_link_bonding.c
@@ -2246,54 +2246,48 @@ test_activebackup_rx_burst(void)
virtual_ethdev_add_mbufs_to_rx_queue(test_params->member_port_ids[i],
&gen_pkt_burst[0], burst_size);
+ /* Expect burst if this was the active port, zero otherwise */
+ unsigned int rx_expect
+ = (test_params->member_port_ids[i] == primary_port) ? burst_size : 0;
+
/* Call rx burst on bonding device */
- TEST_ASSERT_EQUAL(rte_eth_rx_burst(test_params->bonding_port_id, 0,
- &rx_pkt_burst[0], MAX_PKT_BURST), burst_size,
- "rte_eth_rx_burst failed");
+ unsigned int rx_count = rte_eth_rx_burst(test_params->bonding_port_id, 0,
+ &rx_pkt_burst[0], MAX_PKT_BURST);
+ TEST_ASSERT_EQUAL(rx_count, rx_expect,
+ "rte_eth_rx_burst (%u) not as expected (%u)",
+ rx_count, rx_expect);
- if (test_params->member_port_ids[i] == primary_port) {
- /* Verify bonding device rx count */
- rte_eth_stats_get(test_params->bonding_port_id, &port_stats);
- TEST_ASSERT_EQUAL(port_stats.ipackets, (uint64_t)burst_size,
- "Bonding Port (%d) ipackets value (%u) not as expected (%d)",
+ /* Verify bonding device rx count */
+ rte_eth_stats_get(test_params->bonding_port_id, &port_stats);
+ TEST_ASSERT_EQUAL(port_stats.ipackets, rx_expect,
+ "Bonding Port (%d) ipackets value (%u) not as expected (%u)",
test_params->bonding_port_id,
- (unsigned int)port_stats.ipackets, burst_size);
+ (unsigned int)port_stats.ipackets, rx_expect);
- /* Verify bonding member devices rx count */
- for (j = 0; j < test_params->bonding_member_count; j++) {
- rte_eth_stats_get(test_params->member_port_ids[j], &port_stats);
- if (i == j) {
- TEST_ASSERT_EQUAL(port_stats.ipackets, (uint64_t)burst_size,
- "Member Port (%d) ipackets value (%u) not as "
- "expected (%d)",
- test_params->member_port_ids[i],
- (unsigned int)port_stats.ipackets,
- burst_size);
- } else {
- TEST_ASSERT_EQUAL(port_stats.ipackets, 0,
- "Member Port (%d) ipackets value (%u) not as "
- "expected (%d)\n",
- test_params->member_port_ids[i],
- (unsigned int)port_stats.ipackets, 0);
- }
- }
- } else {
- for (j = 0; j < test_params->bonding_member_count; j++) {
- rte_eth_stats_get(test_params->member_port_ids[j], &port_stats);
+ for (j = 0; j < test_params->bonding_member_count; j++) {
+ rte_eth_stats_get(test_params->member_port_ids[j], &port_stats);
+ if (i == j) {
+ TEST_ASSERT_EQUAL(port_stats.ipackets, rx_expect,
+ "Member Port (%d) ipackets (%u) not as expected (%d)",
+ test_params->member_port_ids[i],
+ (unsigned int)port_stats.ipackets, rx_expect);
+
+ /* reset member device stats */
+ rte_eth_stats_reset(test_params->member_port_ids[j]);
+ } else {
TEST_ASSERT_EQUAL(port_stats.ipackets, 0,
- "Member Port (%d) ipackets value (%u) not as expected "
- "(%d)", test_params->member_port_ids[i],
- (unsigned int)port_stats.ipackets, 0);
+ "Member Port (%d) ipackets (%u) not as expected (%d)",
+ test_params->member_port_ids[i],
+ (unsigned int)port_stats.ipackets, 0);
}
}
- /* free mbufs */
- for (i = 0; i < MAX_PKT_BURST; i++) {
- if (rx_pkt_burst[i] != NULL) {
- rte_pktmbuf_free(rx_pkt_burst[i]);
- rx_pkt_burst[i] = NULL;
- }
- }
+ /* extract packets queued to inactive member */
+ if (rx_count == 0)
+ rx_count = rte_eth_rx_burst(test_params->member_port_ids[i], 0,
+ rx_pkt_burst, MAX_PKT_BURST);
+ if (rx_count > 0)
+ rte_pktmbuf_free_bulk(rx_pkt_burst, rx_count);
/* reset bonding device stats */
rte_eth_stats_reset(test_params->bonding_port_id);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.070352072 +0800
+++ 0009-test-bonding-fix-active-backup-receive-test.patch 2025-02-18 19:39:00.428244082 +0800
@@ -1 +1 @@
-From eb29e625ce41b50898efc8e2618b7eeb128460ed Mon Sep 17 00:00:00 2001
+From d0d04dead13a23640736a8b83a27bda0164f45be Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit eb29e625ce41b50898efc8e2618b7eeb128460ed ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
@@ -20,2 +22,2 @@
- app/test/test_link_bonding.c | 69 ++++++++++++++++++------------------
- 1 file changed, 34 insertions(+), 35 deletions(-)
+ app/test/test_link_bonding.c | 74 +++++++++++++++++-------------------
+ 1 file changed, 34 insertions(+), 40 deletions(-)
@@ -24 +26 @@
-index b752a5ecbf..19b064771a 100644
+index b53f512815..19b064771a 100644
@@ -27 +29 @@
-@@ -2246,49 +2246,48 @@ test_activebackup_rx_burst(void)
+@@ -2246,54 +2246,48 @@ test_activebackup_rx_burst(void)
@@ -101 +103,6 @@
-- rte_pktmbuf_free_bulk(rx_pkt_burst, burst_size);
+- for (i = 0; i < MAX_PKT_BURST; i++) {
+- if (rx_pkt_burst[i] != NULL) {
+- rte_pktmbuf_free(rx_pkt_burst[i]);
+- rx_pkt_burst[i] = NULL;
+- }
+- }
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/bonding: fix dedicated queue setup' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (8 preceding siblings ...)
2025-02-18 12:34 ` patch 'test/bonding: fix active backup receive test' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/hns3: fix mbuf freeing in simple Tx path' " Xueming Li
` (77 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Long Wu; +Cc: xuemingl, Chaoyong He, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=eb465c251ea6f64cd49c6ac53a8e71cfb328ebd4
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From eb465c251ea6f64cd49c6ac53a8e71cfb328ebd4 Mon Sep 17 00:00:00 2001
From: Long Wu <long.wu@corigine.com>
Date: Thu, 26 Dec 2024 09:26:18 +0800
Subject: [PATCH] net/bonding: fix dedicated queue setup
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 4da0705bf896327af062212b5a1e6cb1f1366aa5 ]
The bonding PMD hardcoded the value of dedicated hardware Rx/Tx
queue size as (128/512). This will cause the bonding port start
fail if some NIC requires more Rx/Tx descriptors than the hardcoded
number.
Therefore, use the minimum hardware queue size of the member port
to initialize dedicated hardware Rx/Tx queue. If obtaining the
minimum queue size failed, use the default queue size.
Fixes: 112891cd27e5 ("net/bonding: add dedicated HW queues for LACP control")
Signed-off-by: Long Wu <long.wu@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
---
drivers/net/bonding/rte_eth_bond_8023ad.h | 3 +++
drivers/net/bonding/rte_eth_bond_pmd.c | 25 ++++++++++++++++++++---
2 files changed, 25 insertions(+), 3 deletions(-)
diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.h b/drivers/net/bonding/rte_eth_bond_8023ad.h
index 4c280c7565..54e233f858 100644
--- a/drivers/net/bonding/rte_eth_bond_8023ad.h
+++ b/drivers/net/bonding/rte_eth_bond_8023ad.h
@@ -35,6 +35,9 @@ extern "C" {
#define MARKER_TLV_TYPE_INFO 0x01
#define MARKER_TLV_TYPE_RESP 0x02
+#define SLOW_TX_QUEUE_HW_DEFAULT_SIZE 512
+#define SLOW_RX_QUEUE_HW_DEFAULT_SIZE 512
+
typedef void (*rte_eth_bond_8023ad_ext_slowrx_fn)(uint16_t member_id,
struct rte_mbuf *lacp_pkt);
diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
index 4144c86be4..c3a761d0d4 100644
--- a/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -1685,10 +1685,26 @@ member_configure_slow_queue(struct rte_eth_dev *bonding_eth_dev,
}
if (internals->mode4.dedicated_queues.enabled == 1) {
- /* Configure slow Rx queue */
+ struct rte_eth_dev_info member_info = {};
+ uint16_t nb_rx_desc = SLOW_RX_QUEUE_HW_DEFAULT_SIZE;
+ uint16_t nb_tx_desc = SLOW_TX_QUEUE_HW_DEFAULT_SIZE;
+
+ errval = rte_eth_dev_info_get(member_eth_dev->data->port_id,
+ &member_info);
+ if (errval != 0) {
+ RTE_BOND_LOG(ERR,
+ "rte_eth_dev_info_get: port=%d, err (%d)",
+ member_eth_dev->data->port_id,
+ errval);
+ return errval;
+ }
+ if (member_info.rx_desc_lim.nb_min != 0)
+ nb_rx_desc = member_info.rx_desc_lim.nb_min;
+
+ /* Configure slow Rx queue */
errval = rte_eth_rx_queue_setup(member_eth_dev->data->port_id,
- internals->mode4.dedicated_queues.rx_qid, 128,
+ internals->mode4.dedicated_queues.rx_qid, nb_rx_desc,
rte_eth_dev_socket_id(member_eth_dev->data->port_id),
NULL, port->slow_pool);
if (errval != 0) {
@@ -1700,8 +1716,11 @@ member_configure_slow_queue(struct rte_eth_dev *bonding_eth_dev,
return errval;
}
+ if (member_info.tx_desc_lim.nb_min != 0)
+ nb_tx_desc = member_info.tx_desc_lim.nb_min;
+
errval = rte_eth_tx_queue_setup(member_eth_dev->data->port_id,
- internals->mode4.dedicated_queues.tx_qid, 512,
+ internals->mode4.dedicated_queues.tx_qid, nb_tx_desc,
rte_eth_dev_socket_id(member_eth_dev->data->port_id),
NULL);
if (errval != 0) {
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.106319465 +0800
+++ 0010-net-bonding-fix-dedicated-queue-setup.patch 2025-02-18 19:39:00.428244082 +0800
@@ -1 +1 @@
-From 4da0705bf896327af062212b5a1e6cb1f1366aa5 Mon Sep 17 00:00:00 2001
+From eb465c251ea6f64cd49c6ac53a8e71cfb328ebd4 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 4da0705bf896327af062212b5a1e6cb1f1366aa5 ]
@@ -16 +18,0 @@
-Cc: stable@dpdk.org
@@ -26 +28 @@
-index 395e41ff95..4c30bd40ee 100644
+index 4c280c7565..54e233f858 100644
@@ -40 +42 @@
-index f69496feec..467f7fe7ea 100644
+index 4144c86be4..c3a761d0d4 100644
@@ -43 +45 @@
-@@ -1684,10 +1684,26 @@ member_configure_slow_queue(struct rte_eth_dev *bonding_eth_dev,
+@@ -1685,10 +1685,26 @@ member_configure_slow_queue(struct rte_eth_dev *bonding_eth_dev,
@@ -72 +74 @@
-@@ -1699,8 +1715,11 @@ member_configure_slow_queue(struct rte_eth_dev *bonding_eth_dev,
+@@ -1700,8 +1716,11 @@ member_configure_slow_queue(struct rte_eth_dev *bonding_eth_dev,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/hns3: fix mbuf freeing in simple Tx path' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (9 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/bonding: fix dedicated queue setup' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/hns3: remove PVID info dump for VF' " Xueming Li
` (76 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Dengdui Huang; +Cc: xuemingl, Jie Hai, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=bf37bccae0b585e782b37da0fcb748d2807e687c
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From bf37bccae0b585e782b37da0fcb748d2807e687c Mon Sep 17 00:00:00 2001
From: Dengdui Huang <huangdengdui@huawei.com>
Date: Mon, 30 Dec 2024 14:54:03 +0800
Subject: [PATCH] net/hns3: fix mbuf freeing in simple Tx path
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit d78c76dbeffbd2994d77236c403281b34612e024 ]
When RTE_ETH_TX_OFFLOAD_MBUF_FAST_FREE offload is not set,
use rte_pktmbuf_free_seg() to free the mbuf.
Fixes: 7ef933908f04 ("net/hns3: add simple Tx path")
Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
Signed-off-by: Jie Hai <haijie1@huawei.com>
---
drivers/net/hns3/hns3_rxtx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c
index 8d0db134d2..ab4789c2f1 100644
--- a/drivers/net/hns3/hns3_rxtx.c
+++ b/drivers/net/hns3/hns3_rxtx.c
@@ -4047,7 +4047,7 @@ hns3_tx_free_buffer_simple(struct hns3_tx_queue *txq)
for (i = 0; i < txq->tx_rs_thresh; i++)
rte_prefetch0((tx_entry + i)->mbuf);
for (i = 0; i < txq->tx_rs_thresh; i++, tx_entry++) {
- rte_mempool_put(tx_entry->mbuf->pool, tx_entry->mbuf);
+ rte_pktmbuf_free_seg(tx_entry->mbuf);
tx_entry->mbuf = NULL;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.145101859 +0800
+++ 0011-net-hns3-fix-mbuf-freeing-in-simple-Tx-path.patch 2025-02-18 19:39:00.428244082 +0800
@@ -1 +1 @@
-From d78c76dbeffbd2994d77236c403281b34612e024 Mon Sep 17 00:00:00 2001
+From bf37bccae0b585e782b37da0fcb748d2807e687c Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit d78c76dbeffbd2994d77236c403281b34612e024 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
-index 03bbbc435f..09e39cb673 100644
+index 8d0db134d2..ab4789c2f1 100644
@@ -22 +24 @@
-@@ -4006,7 +4006,7 @@ hns3_tx_free_buffer_simple(struct hns3_tx_queue *txq)
+@@ -4047,7 +4047,7 @@ hns3_tx_free_buffer_simple(struct hns3_tx_queue *txq)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/hns3: remove PVID info dump for VF' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (10 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/hns3: fix mbuf freeing in simple Tx path' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/hns3: rename RAS module' " Xueming Li
` (75 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Jie Hai; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=a3acd55cd42561a12519e7467b278960ab17e0c0
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From a3acd55cd42561a12519e7467b278960ab17e0c0 Mon Sep 17 00:00:00 2001
From: Jie Hai <haijie1@huawei.com>
Date: Mon, 30 Dec 2024 14:54:04 +0800
Subject: [PATCH] net/hns3: remove PVID info dump for VF
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 3c805c1ebe02248bb0c2ba944046c2e3354b0c11 ]
Since the PVID status obtained from kernel varies on different
platform, and the PVID of VF can be accessed by 'ip link show'
command, so remove it in case of misunderstanding.
Fixes: 871e5a4f881b ("net/hns3: dump VLAN configuration info")
Signed-off-by: Jie Hai <haijie1@huawei.com>
---
drivers/net/hns3/hns3_dump.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/net/hns3/hns3_dump.c b/drivers/net/hns3/hns3_dump.c
index a3b58e0a8f..fdbce88a1d 100644
--- a/drivers/net/hns3/hns3_dump.c
+++ b/drivers/net/hns3/hns3_dump.c
@@ -632,6 +632,10 @@ hns3_get_vlan_tx_offload_cfg(FILE *file, struct hns3_hw *hw)
static void
hns3_get_port_pvid_info(FILE *file, struct hns3_hw *hw)
{
+ struct hns3_adapter *hns = HNS3_DEV_HW_TO_ADAPTER(hw);
+ if (hns->is_vf)
+ return;
+
fprintf(file, " - pvid status: %s\n",
hw->port_base_vlan_cfg.state ? "On" : "Off");
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.184427852 +0800
+++ 0012-net-hns3-remove-PVID-info-dump-for-VF.patch 2025-02-18 19:39:00.438244080 +0800
@@ -1 +1 @@
-From 3c805c1ebe02248bb0c2ba944046c2e3354b0c11 Mon Sep 17 00:00:00 2001
+From a3acd55cd42561a12519e7467b278960ab17e0c0 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 3c805c1ebe02248bb0c2ba944046c2e3354b0c11 ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
-index 738dcb0c42..f21d32e6a2 100644
+index a3b58e0a8f..fdbce88a1d 100644
@@ -22 +24 @@
-@@ -693,6 +693,10 @@ hns3_get_vlan_tx_offload_cfg(FILE *file, struct hns3_hw *hw)
+@@ -632,6 +632,10 @@ hns3_get_vlan_tx_offload_cfg(FILE *file, struct hns3_hw *hw)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/hns3: rename RAS module' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (11 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/hns3: remove PVID info dump for VF' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/sfc: remove unnecessary assignment' " Xueming Li
` (74 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Jie Hai; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=edb45840ef5e2a41ad99918790a8bfeb3f911d95
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From edb45840ef5e2a41ad99918790a8bfeb3f911d95 Mon Sep 17 00:00:00 2001
From: Jie Hai <haijie1@huawei.com>
Date: Mon, 30 Dec 2024 14:54:05 +0800
Subject: [PATCH] net/hns3: rename RAS module
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 501a40ae8370dcbfe086ef080a60c86a8d428ef6 ]
Rename ROH_MAC module as HIMAC to avoid misunderstandings.
Fixes: 1c1eb759e9d7 ("net/hns3: support RAS process in Kunpeng 930")
Signed-off-by: Jie Hai <haijie1@huawei.com>
---
drivers/net/hns3/hns3_intr.c | 4 ++--
drivers/net/hns3/hns3_intr.h | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/net/hns3/hns3_intr.c b/drivers/net/hns3/hns3_intr.c
index 3f6b9e7fc4..cef0f23f80 100644
--- a/drivers/net/hns3/hns3_intr.c
+++ b/drivers/net/hns3/hns3_intr.c
@@ -1432,8 +1432,8 @@ static const struct hns3_hw_mod_name hns3_hw_module_name[] = {
.module_name = MODULE_MASTER,
.msg = "MODULE_MASTER"
}, {
- .module_name = MODULE_ROH_MAC,
- .msg = "MODULE_ROH_MAC"
+ .module_name = MODULE_HIMAC,
+ .msg = "MODULE_HIMAC"
}
};
diff --git a/drivers/net/hns3/hns3_intr.h b/drivers/net/hns3/hns3_intr.h
index aca1c0722c..fcfb9004cb 100644
--- a/drivers/net/hns3/hns3_intr.h
+++ b/drivers/net/hns3/hns3_intr.h
@@ -104,7 +104,7 @@ enum hns3_mod_name_list {
MODULE_RCB_TX,
MODULE_TXDMA,
MODULE_MASTER,
- MODULE_ROH_MAC,
+ MODULE_HIMAC,
};
enum hns3_err_type_list {
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.220146946 +0800
+++ 0013-net-hns3-rename-RAS-module.patch 2025-02-18 19:39:00.438244080 +0800
@@ -1 +1 @@
-From 501a40ae8370dcbfe086ef080a60c86a8d428ef6 Mon Sep 17 00:00:00 2001
+From edb45840ef5e2a41ad99918790a8bfeb3f911d95 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 501a40ae8370dcbfe086ef080a60c86a8d428ef6 ]
@@ -9 +11,0 @@
-Cc: stable@dpdk.org
@@ -18 +20 @@
-index 2de2b86b02..db5c84061c 100644
+index 3f6b9e7fc4..cef0f23f80 100644
@@ -33 +35 @@
-index 1edb07de36..e88b00c9c9 100644
+index aca1c0722c..fcfb9004cb 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/sfc: remove unnecessary assignment' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (12 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/hns3: rename RAS module' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/mlx5: fix polling CQEs' " Xueming Li
` (73 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Ariel Otilibili; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=d3699f97a72d417a9555c41792d22ee03c7269c2
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From d3699f97a72d417a9555c41792d22ee03c7269c2 Mon Sep 17 00:00:00 2001
From: Ariel Otilibili <otilibil@eurecom.fr>
Date: Wed, 15 Jan 2025 13:11:51 +0100
Subject: [PATCH] net/sfc: remove unnecessary assignment
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit de87641d5c004ef505d58d542a66d66f6a1cb2be ]
The same field was being set twice.
Coverity issue: 384444
Fixes: a62ec90522a6 ("net/sfc: add port representors infrastructure")
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
---
drivers/net/sfc/sfc_repr.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/drivers/net/sfc/sfc_repr.c b/drivers/net/sfc/sfc_repr.c
index c2e5d4eb9e..2c1421b959 100644
--- a/drivers/net/sfc/sfc_repr.c
+++ b/drivers/net/sfc/sfc_repr.c
@@ -769,11 +769,7 @@ static void
sfc_repr_close(struct sfc_repr *sr)
{
SFC_ASSERT(sfc_repr_lock_is_locked(sr));
-
SFC_ASSERT(sr->state == SFC_ETHDEV_CONFIGURED);
- sr->state = SFC_ETHDEV_CLOSING;
-
- /* Put representor close actions here */
sr->state = SFC_ETHDEV_INITIALIZED;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.253376840 +0800
+++ 0014-net-sfc-remove-unnecessary-assignment.patch 2025-02-18 19:39:00.438244080 +0800
@@ -1 +1 @@
-From de87641d5c004ef505d58d542a66d66f6a1cb2be Mon Sep 17 00:00:00 2001
+From d3699f97a72d417a9555c41792d22ee03c7269c2 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit de87641d5c004ef505d58d542a66d66f6a1cb2be ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/mlx5: fix polling CQEs' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (13 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/sfc: remove unnecessary assignment' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/iavf: remove reset of Tx prepare function pointer' " Xueming Li
` (72 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Gavin Hu; +Cc: xuemingl, Changqi Dingluo, Viacheslav Ovsiienko, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=ffb0f31822050174353cf595bc9c3258fd304f6b
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From ffb0f31822050174353cf595bc9c3258fd304f6b Mon Sep 17 00:00:00 2001
From: Gavin Hu <gahu@nvidia.com>
Date: Fri, 6 Dec 2024 02:58:11 +0200
Subject: [PATCH] net/mlx5: fix polling CQEs
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 73f7ae1d721aa5c388123db11827937205985999 ]
In certain situations, the receive queue (rxq) fails to replenish its
internal ring with memory buffers (mbufs) from the pool. This can happen
when the pool has a limited number of mbufs allocated, and the user
application holds incoming packets for an extended period, resulting in a
delayed release of mbufs. Consequently, the pool becomes depleted,
preventing the rxq from replenishing from it.
There was a bug in the behavior of the vectorized rxq_cq_process_v routine,
which handled completion queue entries (CQEs) in batches of four. This
routine consistently accessed four mbufs from the internal queue ring,
regardless of whether they had been replenished. As a result, it could
access mbufs that no longer belonged to the poll mode driver (PMD).
The fix involves checking if there are four replenished mbufs available
before allowing rxq_cq_process_v to handle the batch. Once replenishment
succeeds during the polling process, the routine will resume its operation.
Fixes: 1ded26239aa0 ("net/mlx5: refactor vectorized Rx")
Reported-by: Changqi Dingluo <dingluochangqi.ck@bytedance.com>
Signed-off-by: Gavin Hu <gahu@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
.mailmap | 3 ++-
drivers/net/mlx5/mlx5_rxtx_vec.c | 3 +++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/.mailmap b/.mailmap
index 861d69289f..820c201bfe 100644
--- a/.mailmap
+++ b/.mailmap
@@ -212,6 +212,7 @@ Chandubabu Namburu <chandu@amd.com>
Chang Miao <chang.miao@corigine.com>
Changchun Ouyang <changchun.ouyang@intel.com>
Changpeng Liu <changpeng.liu@intel.com>
+Changqi Dingluo <dingluochangqi.ck@bytedance.com>
Changqing Wu <changqingx.wu@intel.com>
Chaoyong He <chaoyong.he@corigine.com>
Chao Zhu <chaozhu@linux.vnet.ibm.com> <bjzhuc@cn.ibm.com>
@@ -440,7 +441,7 @@ Gargi Sau <gargi.sau@intel.com>
Gary Mussar <gmussar@ciena.com>
Gaurav Singh <gaurav1086@gmail.com>
Gautam Dawar <gdawar@solarflare.com>
-Gavin Hu <gavin.hu@arm.com> <gavin.hu@linaro.org>
+Gavin Hu <gahu@nvidia.com> <gavin.hu@arm.com> <gavin.hu@linaro.org>
Geoffrey Le Gourriérec <geoffrey.le_gourrierec@6wind.com>
Geoffrey Lv <geoffrey.lv@gmail.com>
Geoff Thorpe <geoff.thorpe@nxp.com>
diff --git a/drivers/net/mlx5/mlx5_rxtx_vec.c b/drivers/net/mlx5/mlx5_rxtx_vec.c
index 2363d7ed27..9b9c63f862 100644
--- a/drivers/net/mlx5/mlx5_rxtx_vec.c
+++ b/drivers/net/mlx5/mlx5_rxtx_vec.c
@@ -325,6 +325,9 @@ rxq_burst_v(struct mlx5_rxq_data *rxq, struct rte_mbuf **pkts,
/* Not to cross queue end. */
pkts_n = RTE_MIN(pkts_n, q_n - elts_idx);
pkts_n = RTE_MIN(pkts_n, q_n - cq_idx);
+ /* Not to move past the allocated mbufs. */
+ pkts_n = RTE_MIN(pkts_n, RTE_ALIGN_FLOOR(rxq->rq_ci - rxq->rq_pi,
+ MLX5_VPMD_DESCS_PER_LOOP));
if (!pkts_n) {
*no_cq = !rcvd_pkt;
return rcvd_pkt;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.285030635 +0800
+++ 0015-net-mlx5-fix-polling-CQEs.patch 2025-02-18 19:39:00.448244079 +0800
@@ -1 +1 @@
-From 73f7ae1d721aa5c388123db11827937205985999 Mon Sep 17 00:00:00 2001
+From ffb0f31822050174353cf595bc9c3258fd304f6b Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 73f7ae1d721aa5c388123db11827937205985999 ]
@@ -24 +26,0 @@
-Cc: stable@dpdk.org
@@ -35 +37 @@
-index 38e511a28b..1ed47e1cad 100644
+index 861d69289f..820c201bfe 100644
@@ -38 +40 @@
-@@ -225,6 +225,7 @@ Chandubabu Namburu <chandu@amd.com>
+@@ -212,6 +212,7 @@ Chandubabu Namburu <chandu@amd.com>
@@ -46 +48 @@
-@@ -465,7 +466,7 @@ Gargi Sau <gargi.sau@intel.com>
+@@ -440,7 +441,7 @@ Gargi Sau <gargi.sau@intel.com>
@@ -52 +53,0 @@
- Gavin Li <gavinl@nvidia.com>
@@ -54,0 +56 @@
+ Geoff Thorpe <geoff.thorpe@nxp.com>
@@ -56 +58 @@
-index 1872bf310c..1b701801c5 100644
+index 2363d7ed27..9b9c63f862 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/iavf: remove reset of Tx prepare function pointer' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (14 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/mlx5: fix polling CQEs' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/ice: fix memory leak in scalar Rx' " Xueming Li
` (71 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Bruce Richardson; +Cc: xuemingl, Vladimir Medvedkin, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=f5753bf08752b3d848a30f20f956ee734425560c
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From f5753bf08752b3d848a30f20f956ee734425560c Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Fri, 13 Dec 2024 14:33:19 +0000
Subject: [PATCH] net/iavf: remove reset of Tx prepare function pointer
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 41be96c907607bc709654f71901913f1534264f8 ]
The iavf driver only contains a single Tx prepare function, so when
selecting the Tx path, there is no need to reset and reassign the
function pointer in the ethdev structure. This fixes an issue where the
pointer was reset to NULL, but never assigned back later on function
selection.
Fixes: 5712bf9d6e14 ("net/iavf: add Tx AVX2 offload path")
Fixes: 08eb6a9cc2e1 ("net/iavf: fix Tx L4 checksum")
Fixes: 4f8259df563a ("net/iavf: enable Tx outer checksum offload on AVX512")
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
---
drivers/net/iavf/iavf_rxtx.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/net/iavf/iavf_rxtx.c b/drivers/net/iavf/iavf_rxtx.c
index 5fbc581b95..ced1c21c24 100644
--- a/drivers/net/iavf/iavf_rxtx.c
+++ b/drivers/net/iavf/iavf_rxtx.c
@@ -4010,7 +4010,6 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
if (!use_sse && !use_avx2 && !use_avx512)
goto normal;
- dev->tx_pkt_prepare = NULL;
if (use_sse) {
PMD_DRV_LOG(DEBUG, "Using Vector Tx (port %d).",
dev->data->port_id);
@@ -4027,7 +4026,6 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
goto normal;
} else {
dev->tx_pkt_burst = iavf_xmit_pkts_vec_avx2_offload;
- dev->tx_pkt_prepare = iavf_prep_pkts;
PMD_DRV_LOG(DEBUG, "Using AVX2 OFFLOAD Vector Tx (port %d).",
dev->data->port_id);
}
@@ -4040,12 +4038,10 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
dev->data->port_id);
} else if (check_ret == IAVF_VECTOR_OFFLOAD_PATH) {
dev->tx_pkt_burst = iavf_xmit_pkts_vec_avx512_offload;
- dev->tx_pkt_prepare = iavf_prep_pkts;
PMD_DRV_LOG(DEBUG, "Using AVX512 OFFLOAD Vector Tx (port %d).",
dev->data->port_id);
} else {
dev->tx_pkt_burst = iavf_xmit_pkts_vec_avx512_ctx_offload;
- dev->tx_pkt_prepare = iavf_prep_pkts;
PMD_DRV_LOG(DEBUG, "Using AVX512 CONTEXT OFFLOAD Vector Tx (port %d).",
dev->data->port_id);
}
@@ -4078,7 +4074,6 @@ normal:
PMD_DRV_LOG(DEBUG, "Using Basic Tx callback (port=%d).",
dev->data->port_id);
dev->tx_pkt_burst = iavf_xmit_pkts;
- dev->tx_pkt_prepare = iavf_prep_pkts;
if (no_poll_on_link_down) {
adapter->tx_pkt_burst = dev->tx_pkt_burst;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.320662928 +0800
+++ 0016-net-iavf-remove-reset-of-Tx-prepare-function-pointer.patch 2025-02-18 19:39:00.448244079 +0800
@@ -1 +1 @@
-From 41be96c907607bc709654f71901913f1534264f8 Mon Sep 17 00:00:00 2001
+From f5753bf08752b3d848a30f20f956ee734425560c Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 41be96c907607bc709654f71901913f1534264f8 ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -20,2 +22,2 @@
- drivers/net/iavf/iavf_rxtx.c | 6 ------
- 1 file changed, 6 deletions(-)
+ drivers/net/iavf/iavf_rxtx.c | 5 -----
+ 1 file changed, 5 deletions(-)
@@ -24 +26 @@
-index f7df5f21f2..457b5a5655 100644
+index 5fbc581b95..ced1c21c24 100644
@@ -27 +29 @@
-@@ -4173,7 +4173,6 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
+@@ -4010,7 +4010,6 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
@@ -35 +37 @@
-@@ -4190,7 +4189,6 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
+@@ -4027,7 +4026,6 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
@@ -38 +40 @@
- tx_burst_type = IAVF_TX_AVX2_OFFLOAD;
+ dev->tx_pkt_burst = iavf_xmit_pkts_vec_avx2_offload;
@@ -43 +45 @@
-@@ -4203,17 +4201,14 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
+@@ -4040,12 +4038,10 @@ iavf_set_tx_function(struct rte_eth_dev *dev)
@@ -46 +48 @@
- tx_burst_type = IAVF_TX_AVX512_OFFLOAD;
+ dev->tx_pkt_burst = iavf_xmit_pkts_vec_avx512_offload;
@@ -50,5 +51,0 @@
- } else if (check_ret == IAVF_VECTOR_CTX_PATH) {
- tx_burst_type = IAVF_TX_AVX512_CTX;
-- dev->tx_pkt_prepare = iavf_prep_pkts;
- PMD_DRV_LOG(DEBUG, "Using AVX512 CONTEXT Vector Tx (port %d).",
- dev->data->port_id);
@@ -56 +53 @@
- tx_burst_type = IAVF_TX_AVX512_CTX_OFFLOAD;
+ dev->tx_pkt_burst = iavf_xmit_pkts_vec_avx512_ctx_offload;
@@ -61 +58 @@
-@@ -4251,7 +4246,6 @@ normal:
+@@ -4078,7 +4074,6 @@ normal:
@@ -64 +61 @@
- tx_burst_type = IAVF_TX_DEFAULT;
+ dev->tx_pkt_burst = iavf_xmit_pkts;
@@ -68 +65 @@
- adapter->tx_burst_type = tx_burst_type;
+ adapter->tx_pkt_burst = dev->tx_pkt_burst;
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/ice: fix memory leak in scalar Rx' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (15 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/iavf: remove reset of Tx prepare function pointer' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'common/cnxk: fix atomic load in batch ops' " Xueming Li
` (70 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Vladimir Medvedkin; +Cc: xuemingl, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=fb6aaabf7945b8fd242286cd69368b5cf42a4a91
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From fb6aaabf7945b8fd242286cd69368b5cf42a4a91 Mon Sep 17 00:00:00 2001
From: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
Date: Fri, 17 Jan 2025 17:52:05 +0000
Subject: [PATCH] net/ice: fix memory leak in scalar Rx
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 07cbd0b43ce4af9d628c8ad751789934d0a8c4a7 ]
If the buffer splitting feature is configured and the payload mbuf
allocation fails, the previously allocated header mbuf may be returned
not fully initialized or a memory leak may occur. This patch handles
this case correctly by freeing the corresponding header buffer.
Fixes: 629dad3ef325 ("net/ice: support buffer split in scalar Rx")
Signed-off-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/ice/ice_rxtx.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c
index 644d106814..6af16f9aed 100644
--- a/drivers/net/ice/ice_rxtx.c
+++ b/drivers/net/ice/ice_rxtx.c
@@ -484,6 +484,7 @@ ice_alloc_rx_queue_mbufs(struct ice_rx_queue *rxq)
struct rte_mbuf *mbuf_pay;
mbuf_pay = rte_mbuf_raw_alloc(rxq->rxseg[1].mp);
if (unlikely(!mbuf_pay)) {
+ rte_pktmbuf_free(mbuf);
PMD_DRV_LOG(ERR, "Failed to allocate payload mbuf for RX");
return -ENOMEM;
}
@@ -1874,6 +1875,8 @@ ice_rx_alloc_bufs(struct ice_rx_queue *rxq)
diag_pay = rte_mempool_get_bulk(rxq->rxseg[1].mp,
(void *)mbufs_pay, rxq->rx_free_thresh);
if (unlikely(diag_pay != 0)) {
+ rte_mempool_put_bulk(rxq->mp, (void *)rxep,
+ rxq->rx_free_thresh);
PMD_RX_LOG(ERR, "Failed to get payload mbufs in bulk");
return -ENOMEM;
}
@@ -2580,6 +2583,13 @@ ice_recv_pkts(void *rx_queue,
nmb_pay = rte_mbuf_raw_alloc(rxq->rxseg[1].mp);
if (unlikely(!nmb_pay)) {
rxq->vsi->adapter->pf.dev_data->rx_mbuf_alloc_failed++;
+ rxe->mbuf = NULL;
+ nb_hold--;
+ if (unlikely(rx_id == 0))
+ rx_id = rxq->nb_rx_desc;
+
+ rx_id--;
+ rte_pktmbuf_free(nmb);
break;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.356617522 +0800
+++ 0017-net-ice-fix-memory-leak-in-scalar-Rx.patch 2025-02-18 19:39:00.458244077 +0800
@@ -1 +1 @@
-From 07cbd0b43ce4af9d628c8ad751789934d0a8c4a7 Mon Sep 17 00:00:00 2001
+From fb6aaabf7945b8fd242286cd69368b5cf42a4a91 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 07cbd0b43ce4af9d628c8ad751789934d0a8c4a7 ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -21 +23 @@
-index 0c7106c7e0..f58df9bdfe 100644
+index 644d106814..6af16f9aed 100644
@@ -32 +34 @@
-@@ -1900,6 +1901,8 @@ ice_rx_alloc_bufs(struct ice_rx_queue *rxq)
+@@ -1874,6 +1875,8 @@ ice_rx_alloc_bufs(struct ice_rx_queue *rxq)
@@ -41 +43 @@
-@@ -2607,6 +2610,13 @@ ice_recv_pkts(void *rx_queue,
+@@ -2580,6 +2583,13 @@ ice_recv_pkts(void *rx_queue,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'common/cnxk: fix atomic load in batch ops' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (16 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/ice: fix memory leak in scalar Rx' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'common/cnxk: fix DPI mailbox structure' " Xueming Li
` (69 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Nawal Kishor; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=3d543686ef3e94e2da99b52b42d02293e7b511bc
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 3d543686ef3e94e2da99b52b42d02293e7b511bc Mon Sep 17 00:00:00 2001
From: Nawal Kishor <nkishor@marvell.com>
Date: Mon, 2 Dec 2024 22:27:39 +0530
Subject: [PATCH] common/cnxk: fix atomic load in batch ops
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 73d38682fddd614d95942442c20b3a1de211bb4c ]
In roc batch alloc wait code, __ATOMIC_RELAXED is changed to
__ATOMIC_ACQUIRE in order to avoid potential out of order loads.
Fixes: 50d08d3934ec ("common/cnxk: fix batch alloc completion poll logic")
Signed-off-by: Nawal Kishor <nkishor@marvell.com>
---
.mailmap | 1 +
drivers/common/cnxk/roc_npa.h | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/.mailmap b/.mailmap
index 820c201bfe..75440baa40 100644
--- a/.mailmap
+++ b/.mailmap
@@ -1025,6 +1025,7 @@ Natanael Copa <ncopa@alpinelinux.org>
Nathan Brown <nathan.brown@arm.com>
Nathan Law <nlaw@brocade.com>
Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
+Nawal Kishor <nkishor@marvell.com>
Neel Patel <neel.patel@amd.com> <neel@pensando.io>
Neil Horman <nhorman@tuxdriver.com>
Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
diff --git a/drivers/common/cnxk/roc_npa.h b/drivers/common/cnxk/roc_npa.h
index 4ad5f044b5..ebc2a62536 100644
--- a/drivers/common/cnxk/roc_npa.h
+++ b/drivers/common/cnxk/roc_npa.h
@@ -247,7 +247,7 @@ roc_npa_batch_alloc_wait(uint64_t *cache_line, unsigned int wait_us)
/* Batch alloc status code is updated in bits [5:6] of the first word
* of the 128 byte cache line.
*/
- while (((__atomic_load_n(cache_line, __ATOMIC_RELAXED) >> 5) & 0x3) ==
+ while (((__atomic_load_n(cache_line, __ATOMIC_ACQUIRE) >> 5) & 0x3) ==
ALLOC_CCODE_INVAL)
if (wait_us && (plt_tsc_cycles() - start) >= ticks)
break;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.393198316 +0800
+++ 0018-common-cnxk-fix-atomic-load-in-batch-ops.patch 2025-02-18 19:39:00.458244077 +0800
@@ -1 +1 @@
-From 73d38682fddd614d95942442c20b3a1de211bb4c Mon Sep 17 00:00:00 2001
+From 3d543686ef3e94e2da99b52b42d02293e7b511bc Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 73d38682fddd614d95942442c20b3a1de211bb4c ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
-index 1ed47e1cad..8524952d24 100644
+index 820c201bfe..75440baa40 100644
@@ -22 +24 @@
-@@ -1079,6 +1079,7 @@ Natanael Copa <ncopa@alpinelinux.org>
+@@ -1025,6 +1025,7 @@ Natanael Copa <ncopa@alpinelinux.org>
@@ -31 +33 @@
-index f7cb4460e7..8525038810 100644
+index 4ad5f044b5..ebc2a62536 100644
@@ -34 +36 @@
-@@ -255,7 +255,7 @@ roc_npa_batch_alloc_wait(uint64_t *cache_line, unsigned int wait_us)
+@@ -247,7 +247,7 @@ roc_npa_batch_alloc_wait(uint64_t *cache_line, unsigned int wait_us)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'common/cnxk: fix DPI mailbox structure' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (17 preceding siblings ...)
2025-02-18 12:34 ` patch 'common/cnxk: fix atomic load in batch ops' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'eventdev: fix format string data type in log messages' " Xueming Li
` (68 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Vamsi Attunuru; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=ab740bf72ab0a9ba7d31dd2b375c937e558a6b2b
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From ab740bf72ab0a9ba7d31dd2b375c937e558a6b2b Mon Sep 17 00:00:00 2001
From: Vamsi Attunuru <vattunuru@marvell.com>
Date: Wed, 15 Jan 2025 18:06:54 +0530
Subject: [PATCH] common/cnxk: fix DPI mailbox structure
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit b03c474188383c3d3d529b1c9ca86767e5fb6167 ]
In the existing DPI mailbox structure, one of the fields
spans a 64-bit boundary, making it appear unusual and
complicatng extraction using bit operations.
Patch enlarges csize fields to ensure that mailbox fields
are correctly positioned.
Fixes: b6e395692b6d ("common/cnxk: add DPI DMA support")
Signed-off-by: Vamsi Attunuru <vattunuru@marvell.com>
---
drivers/common/cnxk/roc_dpi_priv.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/common/cnxk/roc_dpi_priv.h b/drivers/common/cnxk/roc_dpi_priv.h
index 518a3e7351..a050187406 100644
--- a/drivers/common/cnxk/roc_dpi_priv.h
+++ b/drivers/common/cnxk/roc_dpi_priv.h
@@ -24,7 +24,7 @@ typedef union dpi_mbox_msg_t {
/* Command code */
uint64_t cmd : 4;
/* Command buffer size in 8-byte words */
- uint64_t csize : 14;
+ uint64_t csize : 16;
/* aura of the command buffer */
uint64_t aura : 20;
/* SSO PF function */
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.429179410 +0800
+++ 0019-common-cnxk-fix-DPI-mailbox-structure.patch 2025-02-18 19:39:00.458244077 +0800
@@ -1 +1 @@
-From b03c474188383c3d3d529b1c9ca86767e5fb6167 Mon Sep 17 00:00:00 2001
+From ab740bf72ab0a9ba7d31dd2b375c937e558a6b2b Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit b03c474188383c3d3d529b1c9ca86767e5fb6167 ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
@@ -22 +24 @@
-index 1f975915f7..05b6751ca6 100644
+index 518a3e7351..a050187406 100644
@@ -25 +27 @@
-@@ -27,7 +27,7 @@ typedef union dpi_mbox_msg_t {
+@@ -24,7 +24,7 @@ typedef union dpi_mbox_msg_t {
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'eventdev: fix format string data type in log messages' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (18 preceding siblings ...)
2025-02-18 12:34 ` patch 'common/cnxk: fix DPI mailbox structure' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'crypto/virtio: fix redundant queue free' " Xueming Li
` (67 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Andre Muezerie; +Cc: xuemingl, Stephen Hemminger, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=f8a34a17125c870368cd85438033d58d626d187c
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From f8a34a17125c870368cd85438033d58d626d187c Mon Sep 17 00:00:00 2001
From: Andre Muezerie <andremue@linux.microsoft.com>
Date: Fri, 27 Dec 2024 08:18:05 -0800
Subject: [PATCH] eventdev: fix format string data type in log messages
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit b2ff5f66189e75deea067598263929c591250e1b ]
The fix is to use the correct macro for the data type being logged.
Fixes: 112bf8055d90 ("eventdev/dma: support vchan add and delete")
Fixes: 2c6e23cd5e76 ("eventdev/dma: support adapter runtime params")
Signed-off-by: Andre Muezerie <andremue@linux.microsoft.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
lib/eventdev/rte_event_dma_adapter.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lib/eventdev/rte_event_dma_adapter.c b/lib/eventdev/rte_event_dma_adapter.c
index 4196164305..8c66ae35bf 100644
--- a/lib/eventdev/rte_event_dma_adapter.c
+++ b/lib/eventdev/rte_event_dma_adapter.c
@@ -1004,7 +1004,7 @@ rte_event_dma_adapter_vchan_add(uint8_t id, int16_t dma_dev_id, uint16_t vchan,
EVENT_DMA_ADAPTER_ID_VALID_OR_ERR_RET(id, -EINVAL);
if (!rte_dma_is_valid(dma_dev_id)) {
- RTE_EDEV_LOG_ERR("Invalid dma_dev_id = %" PRIu8, dma_dev_id);
+ RTE_EDEV_LOG_ERR("Invalid dma_dev_id = %" PRId16, dma_dev_id);
return -EINVAL;
}
@@ -1117,7 +1117,7 @@ rte_event_dma_adapter_vchan_del(uint8_t id, int16_t dma_dev_id, uint16_t vchan)
EVENT_DMA_ADAPTER_ID_VALID_OR_ERR_RET(id, -EINVAL);
if (!rte_dma_is_valid(dma_dev_id)) {
- RTE_EDEV_LOG_ERR("Invalid dma_dev_id = %" PRIu8, dma_dev_id);
+ RTE_EDEV_LOG_ERR("Invalid dma_dev_id = %" PRId16, dma_dev_id);
return -EINVAL;
}
@@ -1275,7 +1275,7 @@ dma_adapter_cap_check(struct event_dma_adapter *adapter)
ret = rte_event_dma_adapter_caps_get(adapter->eventdev_id, adapter->next_dmadev_id, &caps);
if (ret) {
- RTE_EDEV_LOG_ERR("Failed to get adapter caps dev %" PRIu8 " cdev %" PRIu8,
+ RTE_EDEV_LOG_ERR("Failed to get adapter caps dev %" PRIu8 " cdev %" PRIu16,
adapter->eventdev_id, adapter->next_dmadev_id);
return ret;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.463100804 +0800
+++ 0020-eventdev-fix-format-string-data-type-in-log-messages.patch 2025-02-18 19:39:00.468244075 +0800
@@ -1 +1 @@
-From b2ff5f66189e75deea067598263929c591250e1b Mon Sep 17 00:00:00 2001
+From f8a34a17125c870368cd85438033d58d626d187c Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit b2ff5f66189e75deea067598263929c591250e1b ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
-index ff2bc408c1..165374d195 100644
+index 4196164305..8c66ae35bf 100644
@@ -22 +24 @@
-@@ -996,7 +996,7 @@ rte_event_dma_adapter_vchan_add(uint8_t id, int16_t dma_dev_id, uint16_t vchan,
+@@ -1004,7 +1004,7 @@ rte_event_dma_adapter_vchan_add(uint8_t id, int16_t dma_dev_id, uint16_t vchan,
@@ -31 +33 @@
-@@ -1109,7 +1109,7 @@ rte_event_dma_adapter_vchan_del(uint8_t id, int16_t dma_dev_id, uint16_t vchan)
+@@ -1117,7 +1117,7 @@ rte_event_dma_adapter_vchan_del(uint8_t id, int16_t dma_dev_id, uint16_t vchan)
@@ -40 +42 @@
-@@ -1267,7 +1267,7 @@ dma_adapter_cap_check(struct event_dma_adapter *adapter)
+@@ -1275,7 +1275,7 @@ dma_adapter_cap_check(struct event_dma_adapter *adapter)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'crypto/virtio: fix redundant queue free' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (19 preceding siblings ...)
2025-02-18 12:34 ` patch 'eventdev: fix format string data type in log messages' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'crypto/openssl: fix CMAC auth context update' " Xueming Li
` (66 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Rajesh Mudimadugula; +Cc: xuemingl, Akhil Goyal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=90eb624eb6120756bd3ab64b2a0350406203840e
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 90eb624eb6120756bd3ab64b2a0350406203840e Mon Sep 17 00:00:00 2001
From: Rajesh Mudimadugula <rmudimadugul@marvell.com>
Date: Wed, 27 Nov 2024 14:12:48 +0000
Subject: [PATCH] crypto/virtio: fix redundant queue free
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 89241aba832c044a9efb99329cfaa9faff8a6c4e ]
Remove multiple invocations of virtio_crypto_queue_release,
and set virtio crypto queue as null upon free to avoid
segfaults.
Fixes: 6f0175ff53e0 ("crypto/virtio: support basic PMD ops")
Signed-off-by: Rajesh Mudimadugula <rmudimadugul@marvell.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
---
.mailmap | 1 +
drivers/crypto/virtio/virtio_cryptodev.c | 11 +++++------
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/.mailmap b/.mailmap
index 75440baa40..658de81358 100644
--- a/.mailmap
+++ b/.mailmap
@@ -1185,6 +1185,7 @@ Rahul Gupta <rahul.gupta@broadcom.com>
Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Rahul Shah <rahul.r.shah@intel.com>
Raja Zidane <rzidane@nvidia.com>
+Rajesh Mudimadugula <rmudimadugul@marvell.com>
Rajesh Ravi <rajesh.ravi@broadcom.com>
Rakesh Kudurumalla <rkudurumalla@marvell.com> <rkudurumalla@caviumnetworks.com>
Ralf Hoffmann <ralf.hoffmann@allegro-packets.com>
diff --git a/drivers/crypto/virtio/virtio_cryptodev.c b/drivers/crypto/virtio/virtio_cryptodev.c
index c0d3178b71..0c3af3e3b0 100644
--- a/drivers/crypto/virtio/virtio_cryptodev.c
+++ b/drivers/crypto/virtio/virtio_cryptodev.c
@@ -479,10 +479,13 @@ virtio_crypto_free_queues(struct rte_cryptodev *dev)
/* control queue release */
virtio_crypto_queue_release(hw->cvq);
+ hw->cvq = NULL;
/* data queue release */
- for (i = 0; i < hw->max_dataqueues; i++)
+ for (i = 0; i < hw->max_dataqueues; i++) {
virtio_crypto_queue_release(dev->data->queue_pairs[i]);
+ dev->data->queue_pairs[i] = NULL;
+ }
}
static int
@@ -614,6 +617,7 @@ virtio_crypto_qp_release(struct rte_cryptodev *dev, uint16_t queue_pair_id)
}
virtio_crypto_queue_release(vq);
+ dev->data->queue_pairs[queue_pair_id] = NULL;
return 0;
}
@@ -761,8 +765,6 @@ crypto_virtio_create(const char *name, struct rte_pci_device *pci_dev,
static int
virtio_crypto_dev_uninit(struct rte_cryptodev *cryptodev)
{
- struct virtio_crypto_hw *hw = cryptodev->data->dev_private;
-
PMD_INIT_FUNC_TRACE();
if (rte_eal_process_type() == RTE_PROC_SECONDARY)
@@ -777,9 +779,6 @@ virtio_crypto_dev_uninit(struct rte_cryptodev *cryptodev)
cryptodev->enqueue_burst = NULL;
cryptodev->dequeue_burst = NULL;
- /* release control queue */
- virtio_crypto_queue_release(hw->cvq);
-
rte_free(cryptodev->data);
cryptodev->data = NULL;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.496296798 +0800
+++ 0021-crypto-virtio-fix-redundant-queue-free.patch 2025-02-18 19:39:00.468244075 +0800
@@ -1 +1 @@
-From 89241aba832c044a9efb99329cfaa9faff8a6c4e Mon Sep 17 00:00:00 2001
+From 90eb624eb6120756bd3ab64b2a0350406203840e Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 89241aba832c044a9efb99329cfaa9faff8a6c4e ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +23 @@
-index 8524952d24..e428ed3dec 100644
+index 75440baa40..658de81358 100644
@@ -24 +26 @@
-@@ -1252,6 +1252,7 @@ Rahul Gupta <rahul.gupta@broadcom.com>
+@@ -1185,6 +1185,7 @@ Rahul Gupta <rahul.gupta@broadcom.com>
@@ -33 +35 @@
-index 643921dc02..98415af123 100644
+index c0d3178b71..0c3af3e3b0 100644
@@ -36 +38 @@
-@@ -478,10 +478,13 @@ virtio_crypto_free_queues(struct rte_cryptodev *dev)
+@@ -479,10 +479,13 @@ virtio_crypto_free_queues(struct rte_cryptodev *dev)
@@ -51 +53 @@
-@@ -613,6 +616,7 @@ virtio_crypto_qp_release(struct rte_cryptodev *dev, uint16_t queue_pair_id)
+@@ -614,6 +617,7 @@ virtio_crypto_qp_release(struct rte_cryptodev *dev, uint16_t queue_pair_id)
@@ -59 +61 @@
-@@ -760,8 +764,6 @@ crypto_virtio_create(const char *name, struct rte_pci_device *pci_dev,
+@@ -761,8 +765,6 @@ crypto_virtio_create(const char *name, struct rte_pci_device *pci_dev,
@@ -68 +70 @@
-@@ -776,9 +778,6 @@ virtio_crypto_dev_uninit(struct rte_cryptodev *cryptodev)
+@@ -777,9 +779,6 @@ virtio_crypto_dev_uninit(struct rte_cryptodev *cryptodev)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'crypto/openssl: fix CMAC auth context update' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (20 preceding siblings ...)
2025-02-18 12:34 ` patch 'crypto/virtio: fix redundant queue free' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'crypto/virtio: fix data queues iteration' " Xueming Li
` (65 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Wathsala Vithanage
Cc: xuemingl, Jack Bond-Preston, Hemant Agrawal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=73730daf5971a5c639cc107c2039d93ff2a71c16
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 73730daf5971a5c639cc107c2039d93ff2a71c16 Mon Sep 17 00:00:00 2001
From: Wathsala Vithanage <wathsala.vithanage@arm.com>
Date: Fri, 29 Nov 2024 20:20:22 +0000
Subject: [PATCH] crypto/openssl: fix CMAC auth context update
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 0241aebfa3bdc53fb36972fb116298adbdbd3957 ]
This patch removes an unnecessary cleanup of the shared CMAC context at
the end of the CMAC authentication function, which causes subsequent
calls to it to fail.
Fixes: 17d5bc6135af ("crypto/openssl: make per-QP auth context clones")
Signed-off-by: Wathsala Vithanage <wathsala.vithanage@arm.com>
Reviewed-by: Jack Bond-Preston <jack.bond-preston@foss.arm.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
drivers/crypto/openssl/rte_openssl_pmd.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/crypto/openssl/rte_openssl_pmd.c b/drivers/crypto/openssl/rte_openssl_pmd.c
index 017e74e765..11734c4c21 100644
--- a/drivers/crypto/openssl/rte_openssl_pmd.c
+++ b/drivers/crypto/openssl/rte_openssl_pmd.c
@@ -1595,9 +1595,6 @@ process_openssl_auth_cmac(struct rte_mbuf *mbuf_src, uint8_t *dst, int offset,
process_auth_final:
if (CMAC_Final(ctx, dst, (size_t *)&dstlen) != 1)
goto process_auth_err;
-
- CMAC_CTX_cleanup(ctx);
-
return 0;
process_auth_err:
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.531040292 +0800
+++ 0022-crypto-openssl-fix-CMAC-auth-context-update.patch 2025-02-18 19:39:00.468244075 +0800
@@ -1 +1 @@
-From 0241aebfa3bdc53fb36972fb116298adbdbd3957 Mon Sep 17 00:00:00 2001
+From 73730daf5971a5c639cc107c2039d93ff2a71c16 Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 0241aebfa3bdc53fb36972fb116298adbdbd3957 ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
@@ -24 +26 @@
-index d2cf20c059..b090611bd0 100644
+index 017e74e765..11734c4c21 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'crypto/virtio: fix data queues iteration' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (21 preceding siblings ...)
2025-02-18 12:34 ` patch 'crypto/openssl: fix CMAC auth context update' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/octeon_ep: remove useless assignment' " Xueming Li
` (64 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Gowrishankar Muthukrishnan; +Cc: xuemingl, Akhil Goyal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=4ab8b71371eb81a32a1ba7beb3ec4fd4c70400c5
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 4ab8b71371eb81a32a1ba7beb3ec4fd4c70400c5 Mon Sep 17 00:00:00 2001
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Date: Tue, 7 Jan 2025 23:06:02 +0530
Subject: [PATCH] crypto/virtio: fix data queues iteration
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit e27ff6e63a8d6202149d5b458ad3d78711806dfc ]
Fix dataqueues iteration using nb_queue_pairs info available in
device data instead of max dataqueues as dataqueue count might
have been changed in device configuration.
Fixes: 6f0175ff53e0 ("crypto/virtio: support basic PMD ops")
Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
---
drivers/crypto/virtio/virtio_cryptodev.c | 3 +--
drivers/crypto/virtio/virtio_rxtx.c | 3 +--
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/virtio/virtio_cryptodev.c b/drivers/crypto/virtio/virtio_cryptodev.c
index 0c3af3e3b0..332e109876 100644
--- a/drivers/crypto/virtio/virtio_cryptodev.c
+++ b/drivers/crypto/virtio/virtio_cryptodev.c
@@ -849,9 +849,8 @@ static void
virtio_crypto_dev_free_mbufs(struct rte_cryptodev *dev)
{
uint32_t i;
- struct virtio_crypto_hw *hw = dev->data->dev_private;
- for (i = 0; i < hw->max_dataqueues; i++) {
+ for (i = 0; i < dev->data->nb_queue_pairs; i++) {
VIRTIO_CRYPTO_INIT_LOG_DBG("Before freeing dataq[%d] used "
"and unused buf", i);
VIRTQUEUE_DUMP((struct virtqueue *)
diff --git a/drivers/crypto/virtio/virtio_rxtx.c b/drivers/crypto/virtio/virtio_rxtx.c
index 48b5f4ebbb..d02486661f 100644
--- a/drivers/crypto/virtio/virtio_rxtx.c
+++ b/drivers/crypto/virtio/virtio_rxtx.c
@@ -419,12 +419,11 @@ virtio_crypto_dataq_start(struct rte_cryptodev *dev)
* - Setup vring structure for data queues
*/
uint16_t i;
- struct virtio_crypto_hw *hw = dev->data->dev_private;
PMD_INIT_FUNC_TRACE();
/* Start data vring. */
- for (i = 0; i < hw->max_dataqueues; i++) {
+ for (i = 0; i < dev->data->nb_queue_pairs; i++) {
virtio_crypto_vring_start(dev->data->queue_pairs[i]);
VIRTQUEUE_DUMP((struct virtqueue *)dev->data->queue_pairs[i]);
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.565292086 +0800
+++ 0023-crypto-virtio-fix-data-queues-iteration.patch 2025-02-18 19:39:00.478244073 +0800
@@ -1 +1 @@
-From e27ff6e63a8d6202149d5b458ad3d78711806dfc Mon Sep 17 00:00:00 2001
+From 4ab8b71371eb81a32a1ba7beb3ec4fd4c70400c5 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit e27ff6e63a8d6202149d5b458ad3d78711806dfc ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +23 @@
-index 98415af123..b4a6fae9e0 100644
+index 0c3af3e3b0..332e109876 100644
@@ -24 +26 @@
-@@ -848,9 +848,8 @@ static void
+@@ -849,9 +849,8 @@ static void
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/octeon_ep: remove useless assignment' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (22 preceding siblings ...)
2025-02-18 12:34 ` patch 'crypto/virtio: fix data queues iteration' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/enetfec: " Xueming Li
` (63 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Ariel Otilibili; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=8be7239b2ead21484e215b740c28a238958bf95a
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 8be7239b2ead21484e215b740c28a238958bf95a Mon Sep 17 00:00:00 2001
From: Ariel Otilibili <otilibil@eurecom.fr>
Date: Wed, 18 Dec 2024 21:00:09 +0100
Subject: [PATCH] net/octeon_ep: remove useless assignment
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 4143d5f09074c15706479ad4e271f3ab16d90579 ]
Coverity issue: 385414
Fixes: c836a7ba33ee ("net/octeon_ep: support mailbox between VF and PF")
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
---
drivers/net/octeon_ep/otx_ep_mbox.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/net/octeon_ep/otx_ep_mbox.c b/drivers/net/octeon_ep/otx_ep_mbox.c
index c92adeaf9a..210a5ffcea 100644
--- a/drivers/net/octeon_ep/otx_ep_mbox.c
+++ b/drivers/net/octeon_ep/otx_ep_mbox.c
@@ -247,9 +247,6 @@ int otx_ep_mbox_get_link_info(struct rte_eth_dev *eth_dev,
}
link->link_status = RTE_ETH_LINK_UP;
link->link_duplex = RTE_ETH_LINK_FULL_DUPLEX;
- link->link_autoneg = (link_info.autoneg ==
- OTX_EP_LINK_AUTONEG) ? RTE_ETH_LINK_AUTONEG : RTE_ETH_LINK_FIXED;
-
link->link_autoneg = link_info.autoneg;
link->link_speed = link_info.speed;
return 0;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.598796180 +0800
+++ 0024-net-octeon_ep-remove-useless-assignment.patch 2025-02-18 19:39:00.478244073 +0800
@@ -1 +1 @@
-From 4143d5f09074c15706479ad4e271f3ab16d90579 Mon Sep 17 00:00:00 2001
+From 8be7239b2ead21484e215b740c28a238958bf95a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 4143d5f09074c15706479ad4e271f3ab16d90579 ]
@@ -8 +10,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
-index 64a51c1fd0..1d7e08d2cc 100644
+index c92adeaf9a..210a5ffcea 100644
@@ -19 +21 @@
-@@ -256,9 +256,6 @@ int otx_ep_mbox_get_link_info(struct rte_eth_dev *eth_dev,
+@@ -247,9 +247,6 @@ int otx_ep_mbox_get_link_info(struct rte_eth_dev *eth_dev,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/enetfec: remove useless assignment' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (23 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/octeon_ep: remove useless assignment' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/nfp: fix multiple PFs check from NSP' " Xueming Li
` (62 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Ariel Otilibili; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=f8e1bf5b56ca685f1dc38c2f414c65c945cab493
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From f8e1bf5b56ca685f1dc38c2f414c65c945cab493 Mon Sep 17 00:00:00 2001
From: Ariel Otilibili <otilibil@eurecom.fr>
Date: Wed, 18 Dec 2024 21:00:09 +0100
Subject: [PATCH] net/enetfec: remove useless assignment
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 93fdf2ab302f244076c3894ab4a1a5b86d704eae ]
Coverity issue: 374016
Fixes: bb5b5bf1e5c6 ("net/enetfec: support queue configuration")
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
---
drivers/net/enetfec/enet_ethdev.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/net/enetfec/enet_ethdev.c b/drivers/net/enetfec/enet_ethdev.c
index 8c7067fbb5..10620aed86 100644
--- a/drivers/net/enetfec/enet_ethdev.c
+++ b/drivers/net/enetfec/enet_ethdev.c
@@ -414,7 +414,6 @@ enetfec_tx_queue_setup(struct rte_eth_dev *dev,
offset_des_active_txq[queue_idx];
bd_base = (struct bufdesc *)(((uintptr_t)bd_base) + size);
txq->bd.last = (struct bufdesc *)(((uintptr_t)bd_base) - dsize);
- bdp = txq->bd.base;
bdp = txq->bd.cur;
for (i = 0; i < txq->bd.ring_size; i++) {
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.630332475 +0800
+++ 0025-net-enetfec-remove-useless-assignment.patch 2025-02-18 19:39:00.488244072 +0800
@@ -1 +1 @@
-From 93fdf2ab302f244076c3894ab4a1a5b86d704eae Mon Sep 17 00:00:00 2001
+From f8e1bf5b56ca685f1dc38c2f414c65c945cab493 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 93fdf2ab302f244076c3894ab4a1a5b86d704eae ]
@@ -8 +10,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
-index 91c0f60490..0d27b63953 100644
+index 8c7067fbb5..10620aed86 100644
@@ -19 +21 @@
-@@ -415,7 +415,6 @@ enetfec_tx_queue_setup(struct rte_eth_dev *dev,
+@@ -414,7 +414,6 @@ enetfec_tx_queue_setup(struct rte_eth_dev *dev,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/nfp: fix multiple PFs check from NSP' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (24 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/enetfec: " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/nfp: fix misuse of function return values' " Xueming Li
` (61 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Zerun Fu; +Cc: xuemingl, Chaoyong He, Long Wu, Peng Zhang, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=b96c0c90f65f490a52bdeec9ecfb9ac67375e03f
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From b96c0c90f65f490a52bdeec9ecfb9ac67375e03f Mon Sep 17 00:00:00 2001
From: Zerun Fu <zerun.fu@corigine.com>
Date: Wed, 22 Jan 2025 09:28:15 +0800
Subject: [PATCH] net/nfp: fix multiple PFs check from NSP
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit c19d389f5b553b0a9dddbb22882750c17a6fa577 ]
Fix multiple PFs check from NSP problem in the logic of PF initialization.
Fixes: 8ad2cc8fec37 ("net/nfp: add flag for multiple PFs support")
Signed-off-by: Zerun Fu <zerun.fu@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
Reviewed-by: Long Wu <long.wu@corigine.com>
Reviewed-by: Peng Zhang <peng.zhang@corigine.com>
---
drivers/net/nfp/nfp_ethdev.c | 20 +++++++++++++-------
1 file changed, 13 insertions(+), 7 deletions(-)
diff --git a/drivers/net/nfp/nfp_ethdev.c b/drivers/net/nfp/nfp_ethdev.c
index e704c90dc5..b27324c0b4 100644
--- a/drivers/net/nfp/nfp_ethdev.c
+++ b/drivers/net/nfp/nfp_ethdev.c
@@ -985,24 +985,25 @@ nfp_check_multi_pf_from_fw(uint32_t total_vnics)
return false;
}
-static inline bool
+static inline int
nfp_check_multi_pf_from_nsp(struct rte_pci_device *pci_dev,
- struct nfp_cpp *cpp)
+ struct nfp_cpp *cpp,
+ bool *flag)
{
- bool flag;
struct nfp_nsp *nsp;
nsp = nfp_nsp_open(cpp);
if (nsp == NULL) {
PMD_DRV_LOG(ERR, "NFP error when obtaining NSP handle");
- return false;
+ return -EIO;
}
- flag = (nfp_nsp_get_abi_ver_major(nsp) > 0) &&
+ *flag = (nfp_nsp_get_abi_ver_major(nsp) > 0) &&
(pci_dev->id.device_id == PCI_DEVICE_ID_NFP3800_PF_NIC);
nfp_nsp_close(nsp);
- return flag;
+
+ return 0;
}
static int
@@ -1294,7 +1295,12 @@ nfp_pf_init(struct rte_pci_device *pci_dev)
goto hwinfo_cleanup;
}
- pf_dev->multi_pf.enabled = nfp_check_multi_pf_from_nsp(pci_dev, cpp);
+ ret = nfp_check_multi_pf_from_nsp(pci_dev, cpp, &pf_dev->multi_pf.enabled);
+ if (ret != 0) {
+ PMD_INIT_LOG(ERR, "Failed to check multi pf from NSP.");
+ goto eth_table_cleanup;
+ }
+
pf_dev->multi_pf.function_id = function_id;
ret = nfp_net_force_port_down(pf_dev, nfp_eth_table, cpp);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.660983970 +0800
+++ 0026-net-nfp-fix-multiple-PFs-check-from-NSP.patch 2025-02-18 19:39:00.488244072 +0800
@@ -1 +1 @@
-From c19d389f5b553b0a9dddbb22882750c17a6fa577 Mon Sep 17 00:00:00 2001
+From b96c0c90f65f490a52bdeec9ecfb9ac67375e03f Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit c19d389f5b553b0a9dddbb22882750c17a6fa577 ]
@@ -9 +11,0 @@
-Cc: stable@dpdk.org
@@ -20 +22 @@
-index df5482f74a..58a5b1d94e 100644
+index e704c90dc5..b27324c0b4 100644
@@ -23 +25 @@
-@@ -1751,24 +1751,25 @@ nfp_check_multi_pf_from_fw(uint32_t total_vnics)
+@@ -985,24 +985,25 @@ nfp_check_multi_pf_from_fw(uint32_t total_vnics)
@@ -39 +41 @@
- PMD_DRV_LOG(ERR, "NFP error when obtaining NSP handle.");
+ PMD_DRV_LOG(ERR, "NFP error when obtaining NSP handle");
@@ -55,2 +57,2 @@
-@@ -2434,8 +2435,13 @@ nfp_pf_init(struct rte_pci_device *pci_dev)
- goto eth_table_cleanup;
+@@ -1294,7 +1295,12 @@ nfp_pf_init(struct rte_pci_device *pci_dev)
+ goto hwinfo_cleanup;
@@ -58,0 +61 @@
+- pf_dev->multi_pf.enabled = nfp_check_multi_pf_from_nsp(pci_dev, cpp);
@@ -65,2 +67,0 @@
- pf_dev->nfp_eth_table = nfp_eth_table;
-- pf_dev->multi_pf.enabled = nfp_check_multi_pf_from_nsp(pci_dev, cpp);
@@ -68 +68,0 @@
- pf_dev->total_phyports = nfp_net_get_phyports_from_nsp(pf_dev);
@@ -69,0 +70 @@
+ ret = nfp_net_force_port_down(pf_dev, nfp_eth_table, cpp);
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/nfp: fix misuse of function return values' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (25 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/nfp: fix multiple PFs check from NSP' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/nfp: fix multi-PF control flag' " Xueming Li
` (60 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Zerun Fu; +Cc: xuemingl, Chaoyong He, Long Wu, Peng Zhang, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=01778ceb375343d651eb169cdca88b32126aafe6
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 01778ceb375343d651eb169cdca88b32126aafe6 Mon Sep 17 00:00:00 2001
From: Zerun Fu <zerun.fu@corigine.com>
Date: Wed, 22 Jan 2025 09:33:20 +0800
Subject: [PATCH] net/nfp: fix misuse of function return values
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit f19ffdb1574cb0a9c9566b0b5c4098beb95ced49 ]
The 'nfp_ct_offload_add()' return 0 means the result is right
while return negative number means the wrong result.
The caller assigns the 'int' variable to the 'bool' variable.
So the negative number will be transform to 'true'. This will
cause an error because 'true' will be regard as no problem.
Fixes: b4ae16eae01c ("net/nfp: support to add and delete flows to firmware")
Signed-off-by: Zerun Fu <zerun.fu@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
Reviewed-by: Long Wu <long.wu@corigine.com>
Reviewed-by: Peng Zhang <peng.zhang@corigine.com>
---
drivers/net/nfp/flower/nfp_conntrack.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/net/nfp/flower/nfp_conntrack.c b/drivers/net/nfp/flower/nfp_conntrack.c
index f89003be8b..654b449e90 100644
--- a/drivers/net/nfp/flower/nfp_conntrack.c
+++ b/drivers/net/nfp/flower/nfp_conntrack.c
@@ -1436,6 +1436,7 @@ nfp_ct_do_flow_merge(struct nfp_ct_zone_entry *ze,
struct nfp_ct_flow_entry *pre_ct_entry,
struct nfp_ct_flow_entry *post_ct_entry)
{
+ int err;
bool ret;
uint64_t new_cookie[2];
uint8_t cnt_same_item = 0;
@@ -1504,9 +1505,10 @@ nfp_ct_do_flow_merge(struct nfp_ct_zone_entry *ze,
}
/* Send to firmware */
- ret = nfp_ct_offload_add(pre_ct_entry->repr, merge_entry);
- if (ret != 0) {
+ err = nfp_ct_offload_add(pre_ct_entry->repr, merge_entry);
+ if (err != 0) {
PMD_DRV_LOG(ERR, "Send the merged flow to firmware failed");
+ ret = false;
goto merge_table_del;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.692836664 +0800
+++ 0027-net-nfp-fix-misuse-of-function-return-values.patch 2025-02-18 19:39:00.498244070 +0800
@@ -1 +1 @@
-From f19ffdb1574cb0a9c9566b0b5c4098beb95ced49 Mon Sep 17 00:00:00 2001
+From 01778ceb375343d651eb169cdca88b32126aafe6 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit f19ffdb1574cb0a9c9566b0b5c4098beb95ced49 ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
@@ -25 +27 @@
-index 0b21e4ee5b..439a1a1b0e 100644
+index f89003be8b..654b449e90 100644
@@ -28 +30 @@
-@@ -1440,6 +1440,7 @@ nfp_ct_do_flow_merge(struct nfp_ct_zone_entry *ze,
+@@ -1436,6 +1436,7 @@ nfp_ct_do_flow_merge(struct nfp_ct_zone_entry *ze,
@@ -36 +38 @@
-@@ -1508,9 +1509,10 @@ nfp_ct_do_flow_merge(struct nfp_ct_zone_entry *ze,
+@@ -1504,9 +1505,10 @@ nfp_ct_do_flow_merge(struct nfp_ct_zone_entry *ze,
@@ -40 +42 @@
-- ret = nfp_ct_offload_add(pre_ct_entry->dev, merge_entry);
+- ret = nfp_ct_offload_add(pre_ct_entry->repr, merge_entry);
@@ -42 +44 @@
-+ err = nfp_ct_offload_add(pre_ct_entry->dev, merge_entry);
++ err = nfp_ct_offload_add(pre_ct_entry->repr, merge_entry);
@@ -44 +46 @@
- PMD_DRV_LOG(ERR, "Send the merged flow to firmware failed.");
+ PMD_DRV_LOG(ERR, "Send the merged flow to firmware failed");
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/nfp: fix multi-PF control flag' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (26 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/nfp: fix misuse of function return values' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/ice: fix flows handling' " Xueming Li
` (59 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Peng Zhang; +Cc: xuemingl, Chaoyong He, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=92bddea79da424642f3c194619ccb02ff3a28898
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 92bddea79da424642f3c194619ccb02ff3a28898 Mon Sep 17 00:00:00 2001
From: Peng Zhang <peng.zhang@corigine.com>
Date: Wed, 22 Jan 2025 09:39:30 +0800
Subject: [PATCH] net/nfp: fix multi-PF control flag
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 02c056aaac1ba1bd16658eef19cb78457d556041 ]
In the original logic of 'nfp_net_start()', we don't set the
'NFP_NET_CFG_CTRL_MULTI_PF' flag when using multi-pf firmware.
Fix it by adding the missing logic.
Fixes: 95f978efab42 ("net/nfp: enable multiple PF in application firmware")
Signed-off-by: Peng Zhang <peng.zhang@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
---
drivers/net/nfp/nfp_ethdev.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/nfp/nfp_ethdev.c b/drivers/net/nfp/nfp_ethdev.c
index b27324c0b4..32f49a6613 100644
--- a/drivers/net/nfp/nfp_ethdev.c
+++ b/drivers/net/nfp/nfp_ethdev.c
@@ -150,6 +150,9 @@ nfp_net_start(struct rte_eth_dev *dev)
ctrl_extend |= NFP_NET_CFG_CTRL_IPSEC_SM_LOOKUP
| NFP_NET_CFG_CTRL_IPSEC_LM_LOOKUP;
+ if ((cap_extend & NFP_NET_CFG_CTRL_MULTI_PF) != 0 && pf_dev->multi_pf.enabled)
+ ctrl_extend |= NFP_NET_CFG_CTRL_MULTI_PF;
+
update = NFP_NET_CFG_UPDATE_GEN;
if (nfp_ext_reconfig(hw, ctrl_extend, update) != 0)
return -EIO;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.724540359 +0800
+++ 0028-net-nfp-fix-multi-PF-control-flag.patch 2025-02-18 19:39:00.498244070 +0800
@@ -1 +1 @@
-From 02c056aaac1ba1bd16658eef19cb78457d556041 Mon Sep 17 00:00:00 2001
+From 92bddea79da424642f3c194619ccb02ff3a28898 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 02c056aaac1ba1bd16658eef19cb78457d556041 ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -21 +23 @@
-index 58a5b1d94e..ca808afdd9 100644
+index b27324c0b4..32f49a6613 100644
@@ -24,3 +26,3 @@
-@@ -472,6 +472,9 @@ nfp_net_start(struct rte_eth_dev *dev)
- if ((cap_extend & NFP_NET_CFG_CTRL_FLOW_STEER) != 0)
- ctrl_extend |= NFP_NET_CFG_CTRL_FLOW_STEER;
+@@ -150,6 +150,9 @@ nfp_net_start(struct rte_eth_dev *dev)
+ ctrl_extend |= NFP_NET_CFG_CTRL_IPSEC_SM_LOOKUP
+ | NFP_NET_CFG_CTRL_IPSEC_LM_LOOKUP;
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/ice: fix flows handling' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (27 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/nfp: fix multi-PF control flag' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/cnxk: fix NIX send header L3 type' " Xueming Li
` (58 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Vladimir Medvedkin; +Cc: xuemingl, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=03db2facc30eb7fb51f5755496559aa05b1f23b8
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 03db2facc30eb7fb51f5755496559aa05b1f23b8 Mon Sep 17 00:00:00 2001
From: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
Date: Thu, 30 Jan 2025 16:14:42 +0000
Subject: [PATCH] net/ice: fix flows handling
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit fabc9e1322e26b41ab74a8e35dcb477c702c3f6d ]
Currently ICE PMD uses group attribute to select the appropriate HW engine
to offload the flow. This behavior violates the rte_flow API, existing
documentation/examples, and reveals hardware specific details.
This patch eliminates the use of the group attribute and runs each engine
parser in the order they work in the HW pipeline.
Fixes: 9c5f0070fa3f ("net/ice: map group to pipeline stage")
Signed-off-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/ice/ice_generic_flow.c | 30 +++++++++++++++++-------------
1 file changed, 17 insertions(+), 13 deletions(-)
diff --git a/drivers/net/ice/ice_generic_flow.c b/drivers/net/ice/ice_generic_flow.c
index 50d760004f..5c34e0385f 100644
--- a/drivers/net/ice/ice_generic_flow.c
+++ b/drivers/net/ice/ice_generic_flow.c
@@ -20,6 +20,8 @@
#define ICE_FLOW_ENGINE_DISABLED(mask, type) ((mask) & BIT(type))
+#define ICE_FLOW_ENGINE_NB 3
+
static struct ice_engine_list engine_list =
TAILQ_HEAD_INITIALIZER(engine_list);
@@ -2295,21 +2297,23 @@ ice_flow_process_filter(struct rte_eth_dev *dev,
return 0;
}
- parser = get_flow_parser(attr->group);
- if (parser == NULL) {
- rte_flow_error_set(error, EINVAL,
- RTE_FLOW_ERROR_TYPE_ATTR,
- NULL, "NULL attribute.");
- return -rte_errno;
- }
+ for (int i = 0; i < ICE_FLOW_ENGINE_NB; i++) {
+ parser = get_flow_parser(i);
+ if (parser == NULL) {
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ATTR,
+ NULL, "NULL attribute.");
+ return -rte_errno;
+ }
- if (ice_parse_engine(ad, flow, parser, attr->priority,
- pattern, actions, error)) {
- *engine = parser->engine;
- return 0;
- } else {
- return -rte_errno;
+ if (ice_parse_engine(ad, flow, parser, attr->priority,
+ pattern, actions, error)) {
+ *engine = parser->engine;
+ return 0;
+ }
}
+
+ return -rte_errno;
}
static int
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.758260553 +0800
+++ 0029-net-ice-fix-flows-handling.patch 2025-02-18 19:39:00.508244068 +0800
@@ -1 +1 @@
-From fabc9e1322e26b41ab74a8e35dcb477c702c3f6d Mon Sep 17 00:00:00 2001
+From 03db2facc30eb7fb51f5755496559aa05b1f23b8 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit fabc9e1322e26b41ab74a8e35dcb477c702c3f6d ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
- drivers/net/intel/ice/ice_generic_flow.c | 30 ++++++++++++++----------
+ drivers/net/ice/ice_generic_flow.c | 30 +++++++++++++++++-------------
@@ -22 +24 @@
-diff --git a/drivers/net/intel/ice/ice_generic_flow.c b/drivers/net/intel/ice/ice_generic_flow.c
+diff --git a/drivers/net/ice/ice_generic_flow.c b/drivers/net/ice/ice_generic_flow.c
@@ -24,2 +26,2 @@
---- a/drivers/net/intel/ice/ice_generic_flow.c
-+++ b/drivers/net/intel/ice/ice_generic_flow.c
+--- a/drivers/net/ice/ice_generic_flow.c
++++ b/drivers/net/ice/ice_generic_flow.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/cnxk: fix NIX send header L3 type' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (28 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/ice: fix flows handling' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'gro: fix unprocessed IPv4 packets' " Xueming Li
` (57 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Rahul Bhansali; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=0de3886c84a5fd5df323b2a8513f519fb37f3cc1
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 0de3886c84a5fd5df323b2a8513f519fb37f3cc1 Mon Sep 17 00:00:00 2001
From: Rahul Bhansali <rbhansali@marvell.com>
Date: Thu, 30 Jan 2025 17:25:26 +0530
Subject: [PATCH] net/cnxk: fix NIX send header L3 type
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 32c18e7364e30a8e43cc7cc6709a7ce606fa285e ]
For small packets less than 55 bytes, SQ error interrupts are
observed.
When checksum offload flag is enabled and mbuf ol_flags are not
set, then default L3 type will be set to IPv6 in vector
processing. Based on this, HW will still validate for minimum
header size and generate send header error if mismatch.
To address this, will set default L3 type to none. Mbuf ol_flags
RTE_MBUF_F_TX_IPV6 will set with offload feature TSO or L4
checksum only, so handled in corresponding routine.
Fixes: f71b7dbbf04b ("net/cnxk: add vector Tx for CN10K")
Fixes: e829e60c6917 ("net/cnxk: support Tx burst vector for CN20K")
Fixes: 862e28128707 ("net/cnxk: add vector Tx for CN9K")
Signed-off-by: Rahul Bhansali <rbhansali@marvell.com>
---
drivers/net/cnxk/cn10k_tx.h | 7 +++++--
drivers/net/cnxk/cn9k_tx.h | 7 +++++--
2 files changed, 10 insertions(+), 4 deletions(-)
diff --git a/drivers/net/cnxk/cn10k_tx.h b/drivers/net/cnxk/cn10k_tx.h
index c84154ee84..fc82704d47 100644
--- a/drivers/net/cnxk/cn10k_tx.h
+++ b/drivers/net/cnxk/cn10k_tx.h
@@ -1824,6 +1824,9 @@ cn10k_nix_prepare_tso(struct rte_mbuf *m, union nix_send_hdr_w1_u *w1,
w0->lso_mps = m->tso_segsz;
w0->lso_format = NIX_LSO_FORMAT_IDX_TSOV4 + !!(ol_flags & RTE_MBUF_F_TX_IPV6);
w1->ol4type = NIX_SENDL4TYPE_TCP_CKSUM;
+ w1->ol3type = ((!!(ol_flags & RTE_MBUF_F_TX_IPV4)) << 1) +
+ ((!!(ol_flags & RTE_MBUF_F_TX_IPV6)) << 2) +
+ !!(ol_flags & RTE_MBUF_F_TX_IP_CKSUM);
/* Handle tunnel tso */
if ((flags & NIX_TX_OFFLOAD_OL3_OL4_CSUM_F) &&
@@ -2524,7 +2527,7 @@ again:
*/
const uint8x16_t tbl = {
/* [0-15] = il4type:il3type */
- 0x04, /* none (IPv6 assumed) */
+ 0x00, /* none */
0x14, /* RTE_MBUF_F_TX_TCP_CKSUM (IPv6 assumed) */
0x24, /* RTE_MBUF_F_TX_SCTP_CKSUM (IPv6 assumed) */
0x34, /* RTE_MBUF_F_TX_UDP_CKSUM (IPv6 assumed) */
@@ -2728,7 +2731,7 @@ again:
const uint8x16x2_t tbl = {{
{
/* [0-15] = il4type:il3type */
- 0x04, /* none (IPv6) */
+ 0x00, /* none */
0x14, /* RTE_MBUF_F_TX_TCP_CKSUM (IPv6) */
0x24, /* RTE_MBUF_F_TX_SCTP_CKSUM (IPv6) */
0x34, /* RTE_MBUF_F_TX_UDP_CKSUM (IPv6) */
diff --git a/drivers/net/cnxk/cn9k_tx.h b/drivers/net/cnxk/cn9k_tx.h
index 4715bf8a65..3d6af8a38f 100644
--- a/drivers/net/cnxk/cn9k_tx.h
+++ b/drivers/net/cnxk/cn9k_tx.h
@@ -889,6 +889,9 @@ cn9k_nix_prepare_tso(struct rte_mbuf *m, union nix_send_hdr_w1_u *w1,
w0->lso_mps = m->tso_segsz;
w0->lso_format = NIX_LSO_FORMAT_IDX_TSOV4 + !!(ol_flags & RTE_MBUF_F_TX_IPV6);
w1->ol4type = NIX_SENDL4TYPE_TCP_CKSUM;
+ w1->ol3type = ((!!(ol_flags & RTE_MBUF_F_TX_IPV4)) << 1) +
+ ((!!(ol_flags & RTE_MBUF_F_TX_IPV6)) << 2) +
+ !!(ol_flags & RTE_MBUF_F_TX_IP_CKSUM);
/* Handle tunnel tso */
if ((flags & NIX_TX_OFFLOAD_OL3_OL4_CSUM_F) &&
@@ -1402,7 +1405,7 @@ cn9k_nix_xmit_pkts_vector(void *tx_queue, struct rte_mbuf **tx_pkts,
*/
const uint8x16_t tbl = {
/* [0-15] = il4type:il3type */
- 0x04, /* none (IPv6 assumed) */
+ 0x00, /* none */
0x14, /* RTE_MBUF_F_TX_TCP_CKSUM (IPv6 assumed) */
0x24, /* RTE_MBUF_F_TX_SCTP_CKSUM (IPv6 assumed) */
0x34, /* RTE_MBUF_F_TX_UDP_CKSUM (IPv6 assumed) */
@@ -1606,7 +1609,7 @@ cn9k_nix_xmit_pkts_vector(void *tx_queue, struct rte_mbuf **tx_pkts,
const uint8x16x2_t tbl = {{
{
/* [0-15] = il4type:il3type */
- 0x04, /* none (IPv6) */
+ 0x00, /* none */
0x14, /* RTE_MBUF_F_TX_TCP_CKSUM (IPv6) */
0x24, /* RTE_MBUF_F_TX_SCTP_CKSUM (IPv6) */
0x34, /* RTE_MBUF_F_TX_UDP_CKSUM (IPv6) */
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.805639945 +0800
+++ 0030-net-cnxk-fix-NIX-send-header-L3-type.patch 2025-02-18 19:39:00.518244067 +0800
@@ -1 +1 @@
-From 32c18e7364e30a8e43cc7cc6709a7ce606fa285e Mon Sep 17 00:00:00 2001
+From 0de3886c84a5fd5df323b2a8513f519fb37f3cc1 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 32c18e7364e30a8e43cc7cc6709a7ce606fa285e ]
@@ -20 +22,0 @@
-Cc: stable@dpdk.org
@@ -25 +26,0 @@
- drivers/net/cnxk/cn20k_tx.h | 7 +++++--
@@ -27 +28 @@
- 3 files changed, 15 insertions(+), 6 deletions(-)
+ 2 files changed, 10 insertions(+), 4 deletions(-)
@@ -30 +31 @@
-index 7d9b259a5f..77f4e54cd8 100644
+index c84154ee84..fc82704d47 100644
@@ -33 +34 @@
-@@ -1773,6 +1773,9 @@ cn10k_nix_prepare_tso(struct rte_mbuf *m, union nix_send_hdr_w1_u *w1,
+@@ -1824,6 +1824,9 @@ cn10k_nix_prepare_tso(struct rte_mbuf *m, union nix_send_hdr_w1_u *w1,
@@ -43,33 +44 @@
-@@ -2477,7 +2480,7 @@ again:
- */
- const uint8x16_t tbl = {
- /* [0-15] = il4type:il3type */
-- 0x04, /* none (IPv6 assumed) */
-+ 0x00, /* none */
- 0x14, /* RTE_MBUF_F_TX_TCP_CKSUM (IPv6 assumed) */
- 0x24, /* RTE_MBUF_F_TX_SCTP_CKSUM (IPv6 assumed) */
- 0x34, /* RTE_MBUF_F_TX_UDP_CKSUM (IPv6 assumed) */
-@@ -2681,7 +2684,7 @@ again:
- const uint8x16x2_t tbl = {{
- {
- /* [0-15] = il4type:il3type */
-- 0x04, /* none (IPv6) */
-+ 0x00, /* none */
- 0x14, /* RTE_MBUF_F_TX_TCP_CKSUM (IPv6) */
- 0x24, /* RTE_MBUF_F_TX_SCTP_CKSUM (IPv6) */
- 0x34, /* RTE_MBUF_F_TX_UDP_CKSUM (IPv6) */
-diff --git a/drivers/net/cnxk/cn20k_tx.h b/drivers/net/cnxk/cn20k_tx.h
-index c731406529..8c3ba8326d 100644
---- a/drivers/net/cnxk/cn20k_tx.h
-+++ b/drivers/net/cnxk/cn20k_tx.h
-@@ -1733,6 +1733,9 @@ cn20k_nix_prepare_tso(struct rte_mbuf *m, union nix_send_hdr_w1_u *w1, union nix
- w0->lso_mps = m->tso_segsz;
- w0->lso_format = NIX_LSO_FORMAT_IDX_TSOV4 + !!(ol_flags & RTE_MBUF_F_TX_IPV6);
- w1->ol4type = NIX_SENDL4TYPE_TCP_CKSUM;
-+ w1->ol3type = ((!!(ol_flags & RTE_MBUF_F_TX_IPV4)) << 1) +
-+ ((!!(ol_flags & RTE_MBUF_F_TX_IPV6)) << 2) +
-+ !!(ol_flags & RTE_MBUF_F_TX_IP_CKSUM);
-
- /* Handle tunnel tso */
- if ((flags & NIX_TX_OFFLOAD_OL3_OL4_CSUM_F) && (ol_flags & RTE_MBUF_F_TX_TUNNEL_MASK)) {
-@@ -2395,7 +2398,7 @@ again:
+@@ -2524,7 +2527,7 @@ again:
@@ -84 +53 @@
-@@ -2595,7 +2598,7 @@ again:
+@@ -2728,7 +2731,7 @@ again:
@@ -94 +63 @@
-index 9370985864..902a17860c 100644
+index 4715bf8a65..3d6af8a38f 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'gro: fix unprocessed IPv4 packets' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (29 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/cnxk: fix NIX send header L3 type' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'eal/linux: fix memseg length in legacy mem init' " Xueming Li
` (56 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Konstantin Ananyev; +Cc: xuemingl, Ferruh Yigit, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=d3e164cbd7619aaf591d3054eff45dd1454af5c1
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From d3e164cbd7619aaf591d3054eff45dd1454af5c1 Mon Sep 17 00:00:00 2001
From: Konstantin Ananyev <konstantin.ananyev@huawei.com>
Date: Wed, 5 Feb 2025 17:33:11 -0800
Subject: [PATCH] gro: fix unprocessed IPv4 packets
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 5c762a58c3fa81e232a5cba8087577be1a593c33 ]
gro_vxlan_tcp4_tbl_timeout_flush() is called without taking into account
that first entries in pkts[] can be already occupied by
un-processed packets.
Fixes: 74080d7dcf31 ("gro: support IPv6 for TCP")
Signed-off-by: Konstantin Ananyev <konstantin.ananyev@huawei.com>
Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
---
lib/gro/rte_gro.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/gro/rte_gro.c b/lib/gro/rte_gro.c
index d824eebd93..db86117609 100644
--- a/lib/gro/rte_gro.c
+++ b/lib/gro/rte_gro.c
@@ -327,7 +327,7 @@ rte_gro_reassemble_burst(struct rte_mbuf **pkts,
/* Flush all packets from the tables */
if (do_vxlan_tcp_gro) {
i += gro_vxlan_tcp4_tbl_timeout_flush(&vxlan_tcp_tbl,
- 0, pkts, nb_pkts);
+ 0, &pkts[i], nb_pkts - i);
}
if (do_vxlan_udp_gro) {
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.859778936 +0800
+++ 0031-gro-fix-unprocessed-IPv4-packets.patch 2025-02-18 19:39:00.518244067 +0800
@@ -1 +1 @@
-From 5c762a58c3fa81e232a5cba8087577be1a593c33 Mon Sep 17 00:00:00 2001
+From d3e164cbd7619aaf591d3054eff45dd1454af5c1 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 5c762a58c3fa81e232a5cba8087577be1a593c33 ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'eal/linux: fix memseg length in legacy mem init' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (30 preceding siblings ...)
2025-02-18 12:34 ` patch 'gro: fix unprocessed IPv4 packets' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'buildtools: fix some Python regex syntax warnings' " Xueming Li
` (55 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Yang Ming; +Cc: xuemingl, Dmitry Kozlyuk, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=a242697f142110e44ed2c17385bd138993e585e8
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From a242697f142110e44ed2c17385bd138993e585e8 Mon Sep 17 00:00:00 2001
From: Yang Ming <ming.1.yang@nokia-sbell.com>
Date: Thu, 2 Jan 2025 16:58:38 +0800
Subject: [PATCH] eal/linux: fix memseg length in legacy mem init
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit b974cbbbef6e1036e7ed7d19fefb7ef8cda0e4a1 ]
Fix the issue where OS memory is mistakenly freed with rte_free
by setting the length (len) of unused memseg to 0.
When `eal_legacy_hugepage_init()` releases the VA space for
unused memseg lists(MSLs), it does not reset MSLs' length to 0.
As a result, `mlx5_mem_is_rte()` may incorrectly identify OS
memory as rte memory.
This can lead to `mlx_free()` calling `rte_free()` on OS memory,
causing an "EAL: Error: Invalid memory" log and failing to free
the OS memory.
This issue is occasional and occurs when the DPDK program’s
memory map places the heap address range between 0 and len(32G).
In such cases, malloc may return an address less than len,
causing `mlx5_mem_is_rte()` to incorrectly treat it as rte
memory.
Also, consider how the MSL with `base_va == NULL` ends up in
`mlx5_mem_is_rte()`. It comes from `rte_mem_virt2memseg_list()`
which iterates MSLs and checks that an address belongs to
[`base_va`; `base_va+len`) without checking whether
`base_va == NULL` i.e. that the MSL is inactive. So this patch
also corrects `rte_mem_virt2memseg_list()` behavior.
Fixes: 66cc45e293ed ("mem: replace memseg with memseg lists")
Signed-off-by: Yang Ming <ming.1.yang@nokia-sbell.com>
Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
---
.mailmap | 1 +
lib/eal/linux/eal_memory.c | 1 +
2 files changed, 2 insertions(+)
diff --git a/.mailmap b/.mailmap
index 658de81358..60eac79c6b 100644
--- a/.mailmap
+++ b/.mailmap
@@ -1630,6 +1630,7 @@ Yahui Cao <yahui.cao@intel.com>
Yajun Wu <yajunw@nvidia.com>
Yangchao Zhou <zhouyates@gmail.com>
Yanglong Wu <yanglong.wu@intel.com>
+Yang Ming <ming.1.yang@nokia-sbell.com>
Yang Zhang <zy107165@alibaba-inc.com>
Yanjie Xu <yanjie.xu@intel.com>
Yan Xia <yanx.xia@intel.com>
diff --git a/lib/eal/linux/eal_memory.c b/lib/eal/linux/eal_memory.c
index 9b6f08fba8..077f77d406 100644
--- a/lib/eal/linux/eal_memory.c
+++ b/lib/eal/linux/eal_memory.c
@@ -1472,6 +1472,7 @@ eal_legacy_hugepage_init(void)
mem_sz = msl->len;
munmap(msl->base_va, mem_sz);
msl->base_va = NULL;
+ msl->len = 0;
msl->heap = 0;
/* destroy backing fbarray */
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.893148730 +0800
+++ 0032-eal-linux-fix-memseg-length-in-legacy-mem-init.patch 2025-02-18 19:39:00.528244065 +0800
@@ -1 +1 @@
-From b974cbbbef6e1036e7ed7d19fefb7ef8cda0e4a1 Mon Sep 17 00:00:00 2001
+From a242697f142110e44ed2c17385bd138993e585e8 Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit b974cbbbef6e1036e7ed7d19fefb7ef8cda0e4a1 ]
@@ -34 +36,0 @@
-Cc: stable@dpdk.org
@@ -44 +46 @@
-index 9209a716e0..19bbdbc0c8 100644
+index 658de81358..60eac79c6b 100644
@@ -47 +49 @@
-@@ -1722,6 +1722,7 @@ Yahui Cao <yahui.cao@intel.com>
+@@ -1630,6 +1630,7 @@ Yahui Cao <yahui.cao@intel.com>
@@ -56 +58 @@
-index 45879ca743..9dda60c0e1 100644
+index 9b6f08fba8..077f77d406 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'buildtools: fix some Python regex syntax warnings' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (31 preceding siblings ...)
2025-02-18 12:34 ` patch 'eal/linux: fix memseg length in legacy mem init' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'use Python raw string notation' " Xueming Li
` (54 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Ariel Otilibili; +Cc: xuemingl, Robin Jarry, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=d139f13116e3e901f36a6701c79c694b39ce89fc
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From d139f13116e3e901f36a6701c79c694b39ce89fc Mon Sep 17 00:00:00 2001
From: Ariel Otilibili <otilibil@eurecom.fr>
Date: Fri, 13 Dec 2024 15:40:58 +0100
Subject: [PATCH] buildtools: fix some Python regex syntax warnings
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 5506d5a71031c003d8c0b740dbb72eb7a4968edb ]
* invalid escape sequences now generate SyntaxWarning
* therefore changed syntax to raw string noration.
Fixes: 0aeaf75df879 ("test: define unit tests suites based on test types")
Fixes: 25065ef1f6c0 ("test: emit warning for orphaned tests")
Link: https://docs.python.org/3/library/re.html#module-re
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
Acked-by: Robin Jarry <rjarry@redhat.com>
---
buildtools/get-test-suites.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/buildtools/get-test-suites.py b/buildtools/get-test-suites.py
index c61f6a273f..fd22d25f36 100644
--- a/buildtools/get-test-suites.py
+++ b/buildtools/get-test-suites.py
@@ -6,10 +6,10 @@ import sys
import re
input_list = sys.argv[1:]
-test_def_regex = re.compile("REGISTER_([A-Z]+)_TEST\s*\(\s*([a-z0-9_]+)")
+test_def_regex = re.compile(r"REGISTER_([A-Z]+)_TEST\s*\(\s*([a-z0-9_]+)")
test_suites = {}
# track tests not in any test suite.
-non_suite_regex = re.compile("REGISTER_TEST_COMMAND\s*\(\s*([a-z0-9_]+)")
+non_suite_regex = re.compile(r"REGISTER_TEST_COMMAND\s*\(\s*([a-z0-9_]+)")
non_suite_tests = []
def get_fast_test_params(test_name, ln):
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.927931024 +0800
+++ 0033-buildtools-fix-some-Python-regex-syntax-warnings.patch 2025-02-18 19:39:00.528244065 +0800
@@ -1 +1 @@
-From 5506d5a71031c003d8c0b740dbb72eb7a4968edb Mon Sep 17 00:00:00 2001
+From d139f13116e3e901f36a6701c79c694b39ce89fc Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 5506d5a71031c003d8c0b740dbb72eb7a4968edb ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'use Python raw string notation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (32 preceding siblings ...)
2025-02-18 12:34 ` patch 'buildtools: fix some Python regex syntax warnings' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/af_packet: fix socket close on device stop' " Xueming Li
` (53 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Ariel Otilibili; +Cc: xuemingl, Robin Jarry, Luca Vizzarro, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=837d7d50fc98f48c06cfbe2b17ebd1e3542348b0
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 837d7d50fc98f48c06cfbe2b17ebd1e3542348b0 Mon Sep 17 00:00:00 2001
From: Ariel Otilibili <otilibil@eurecom.fr>
Date: Sat, 14 Dec 2024 11:36:35 +0100
Subject: [PATCH] use Python raw string notation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit d3e90e5e37872f1040f37a08b056102c1a302bb3 ]
* follow up of a discussion with Robin Jarry
* since 3.12 invalid escape sequences generate SyntaxWarning
* in the future, these invalid sequences will generate SyntaxError
* therefore changed syntax to raw string notation.
Link: https://inbox.dpdk.org/dev/D6AMQXRSG8E7.33BAORRHRHV9A@redhat.com/
Link: https://docs.python.org/3/whatsnew/3.12.html#other-language-changes
Fixes: 9d4efc5cc6f9 ("buildtools: fix NUMA nodes count")
Fixes: f88b0b892204 ("devtools: forbid indent with tabs in Meson")
Suggested-by: Robin Jarry <rjarry@redhat.com>
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
Reviewed-by: Luca Vizzarro <luca.vizzarro@arm.com>
---
buildtools/get-numa-count.py | 2 +-
devtools/check-meson.py | 2 +-
dts/tests/TestSuite_smoke_tests.py | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/buildtools/get-numa-count.py b/buildtools/get-numa-count.py
index 2f243886cd..f8bea5b58e 100644
--- a/buildtools/get-numa-count.py
+++ b/buildtools/get-numa-count.py
@@ -11,7 +11,7 @@ import re
if os.name == 'posix':
if os.path.isdir('/sys/devices/system/node'):
numa_nodes = glob.glob('/sys/devices/system/node/node*')
- numa_nodes.sort(key=lambda l: int(re.findall('\d+', l)[0]))
+ numa_nodes.sort(key=lambda l: int(re.findall(r'\d+', l)[0]))
print(int(os.path.basename(numa_nodes[-1])[4:]) + 1)
else:
subprocess.run(['sysctl', '-n', 'vm.ndomains'], check=False)
diff --git a/devtools/check-meson.py b/devtools/check-meson.py
index 4b2338828d..9a33d8b036 100755
--- a/devtools/check-meson.py
+++ b/devtools/check-meson.py
@@ -51,7 +51,7 @@ def check_indentation(filename, contents):
code, comments = split_code_comments(line)
if not code.strip():
continue
- if re.match('^ *\t', code):
+ if re.match(r'^ *\t', code):
print(f'Error parsing {filename}:{lineno}, got some tabulation')
if code.endswith('files('):
if infiles:
diff --git a/dts/tests/TestSuite_smoke_tests.py b/dts/tests/TestSuite_smoke_tests.py
index 5e897cf5d2..e130a6b603 100644
--- a/dts/tests/TestSuite_smoke_tests.py
+++ b/dts/tests/TestSuite_smoke_tests.py
@@ -91,7 +91,7 @@ class SmokeTests(TestSuite):
# with the address for the nic we are on in the loop and then captures the
# name of the driver in a group
devbind_info_for_nic = re.search(
- f"{nic.pci}[^\\n]*drv=([\\d\\w-]*) [^\\n]*",
+ rf"{nic.pci}[^\\n]*drv=([\\d\\w-]*) [^\\n]*",
all_nics_in_dpdk_devbind,
)
self.verify(
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.956691919 +0800
+++ 0034-use-Python-raw-string-notation.patch 2025-02-18 19:39:00.528244065 +0800
@@ -1 +1 @@
-From d3e90e5e37872f1040f37a08b056102c1a302bb3 Mon Sep 17 00:00:00 2001
+From 837d7d50fc98f48c06cfbe2b17ebd1e3542348b0 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit d3e90e5e37872f1040f37a08b056102c1a302bb3 ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -21,5 +23,4 @@
- buildtools/get-numa-count.py | 2 +-
- devtools/check-meson.py | 2 +-
- dts/framework/testbed_model/traffic_generator/scapy.py | 2 +-
- dts/tests/TestSuite_smoke_tests.py | 2 +-
- 4 files changed, 4 insertions(+), 4 deletions(-)
+ buildtools/get-numa-count.py | 2 +-
+ devtools/check-meson.py | 2 +-
+ dts/tests/TestSuite_smoke_tests.py | 2 +-
+ 3 files changed, 3 insertions(+), 3 deletions(-)
@@ -53,12 +53,0 @@
-diff --git a/dts/framework/testbed_model/traffic_generator/scapy.py b/dts/framework/testbed_model/traffic_generator/scapy.py
-index d24efc44e6..a16cdf6758 100644
---- a/dts/framework/testbed_model/traffic_generator/scapy.py
-+++ b/dts/framework/testbed_model/traffic_generator/scapy.py
-@@ -237,6 +237,6 @@ class ScapyTrafficGenerator(PythonShell, CapturingTrafficGenerator):
- )
- # In the string of bytes "b'XXXX'", we only want the contents ("XXXX")
- list_of_packets_base64 = re.findall(
-- f"^b'({REGEX_FOR_BASE64_ENCODING})'", packet_strs, re.MULTILINE
-+ rf"^b'({REGEX_FOR_BASE64_ENCODING})'", packet_strs, re.MULTILINE
- )
- return [Ether(base64_bytes(pakt)) for pakt in list_of_packets_base64]
@@ -66 +55 @@
-index bc3a2a6bf9..ab5ad44850 100644
+index 5e897cf5d2..e130a6b603 100644
@@ -69 +58 @@
-@@ -136,7 +136,7 @@ class TestSmokeTests(TestSuite):
+@@ -91,7 +91,7 @@ class SmokeTests(TestSuite):
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/af_packet: fix socket close on device stop' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (33 preceding siblings ...)
2025-02-18 12:34 ` patch 'use Python raw string notation' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'ethdev: fix functions available in new device event' " Xueming Li
` (52 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Tudor Cornea; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=6594bba195d9047e43e30d22170baab5f103d08a
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 6594bba195d9047e43e30d22170baab5f103d08a Mon Sep 17 00:00:00 2001
From: Tudor Cornea <tudor.cornea@gmail.com>
Date: Tue, 4 Feb 2025 18:45:08 +0200
Subject: [PATCH] net/af_packet: fix socket close on device stop
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 872e846f6bb31afbdd508903380cf05a3d313a3a ]
Currently, if we call rte_eth_dev_stop(), the sockets are closed.
If we attempt to start the port again, socket related operations
will not work correctly.
This can be alleviated by closing the socket at the same place in
which we currently free the memory, in eth_dev_close().
If an application calls rte_eth_dev_stop() on a port managed
by the af_packet PMD, the port becomes unusable. This is in contrast
with ports managed by other drivers (e.g virtio).
I also managed to reproduce the issue using testpmd.
sudo ip link add test-veth0 type veth peer name test-veth1
sudo ip link set test-veth0 up
sudo ip link set test-veth1 up
AF_PACKET_ARGS=\
"blocksz=4096,framesz=2048,framecnt=512,qpairs=1,qdisc_bypass=0"
sudo ./dpdk-testpmd \
-l 0-3 \
-m 1024 \
--no-huge \
--no-shconf \
--no-pci \
--vdev=net_af_packet0,iface=test-veth0,${AF_PACKET_ARGS} \
--vdev=net_af_packet1,iface=test-veth1,${AF_PACKET_ARGS} \
-- \
-i
testpmd> start tx_first
Forwarding will start, and we will see traffic on the interfaces.
testpmd> stop
testpmd> port stop 0
Stopping ports...
Checking link statuses...
Done
testpmd> port stop 1
Stopping ports...
Checking link statuses...
Done
testpmd> port start 0
AFPACKET: eth_dev_macaddr_set(): receive socket not found
Port 0: CA:65:81:63:81:B2
Checking link statuses...
Done
testpmd> port start 1
AFPACKET: eth_dev_macaddr_set(): receive socket not found
Port 1: CA:12:D0:BE:93:3F
Checking link statuses...
Done
testpmd> start tx_first
When we start forwarding again, we can see that there is no traffic
on the interfaces. This does not happen when testing with other PMD
drivers (e.g virtio).
With the patch, the port should re-initialize correctly.
testpmd> port start 0
Port 0: CA:65:81:63:81:B2
Checking link statuses...
Done
Fixes: 364e08f2bbc0 ("af_packet: add PMD for AF_PACKET-based virtual devices")
Signed-off-by: Tudor Cornea <tudor.cornea@gmail.com>
---
drivers/net/af_packet/rte_eth_af_packet.c | 30 +++++++++++------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/drivers/net/af_packet/rte_eth_af_packet.c b/drivers/net/af_packet/rte_eth_af_packet.c
index 6b7b16f348..0b059bfd0b 100644
--- a/drivers/net/af_packet/rte_eth_af_packet.c
+++ b/drivers/net/af_packet/rte_eth_af_packet.c
@@ -332,27 +332,12 @@ static int
eth_dev_stop(struct rte_eth_dev *dev)
{
unsigned i;
- int sockfd;
struct pmd_internals *internals = dev->data->dev_private;
for (i = 0; i < internals->nb_queues; i++) {
- sockfd = internals->rx_queue[i].sockfd;
- if (sockfd != -1)
- close(sockfd);
-
- /* Prevent use after free in case tx fd == rx fd */
- if (sockfd != internals->tx_queue[i].sockfd) {
- sockfd = internals->tx_queue[i].sockfd;
- if (sockfd != -1)
- close(sockfd);
- }
-
- internals->rx_queue[i].sockfd = -1;
- internals->tx_queue[i].sockfd = -1;
dev->data->rx_queue_state[i] = RTE_ETH_QUEUE_STATE_STOPPED;
dev->data->tx_queue_state[i] = RTE_ETH_QUEUE_STATE_STOPPED;
}
-
dev->data->dev_link.link_status = RTE_ETH_LINK_DOWN;
return 0;
}
@@ -447,6 +432,7 @@ eth_dev_close(struct rte_eth_dev *dev)
struct pmd_internals *internals;
struct tpacket_req *req;
unsigned int q;
+ int sockfd;
if (rte_eal_process_type() != RTE_PROC_PRIMARY)
return 0;
@@ -457,6 +443,20 @@ eth_dev_close(struct rte_eth_dev *dev)
internals = dev->data->dev_private;
req = &internals->req;
for (q = 0; q < internals->nb_queues; q++) {
+ sockfd = internals->rx_queue[q].sockfd;
+ if (sockfd != -1)
+ close(sockfd);
+
+ /* Prevent use after free in case tx fd == rx fd */
+ if (sockfd != internals->tx_queue[q].sockfd) {
+ sockfd = internals->tx_queue[q].sockfd;
+ if (sockfd != -1)
+ close(sockfd);
+ }
+
+ internals->rx_queue[q].sockfd = -1;
+ internals->tx_queue[q].sockfd = -1;
+
munmap(internals->rx_queue[q].map,
2 * req->tp_block_size * req->tp_block_nr);
rte_free(internals->rx_queue[q].rd);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:01.988448413 +0800
+++ 0035-net-af_packet-fix-socket-close-on-device-stop.patch 2025-02-18 19:39:00.528244065 +0800
@@ -1 +1 @@
-From 872e846f6bb31afbdd508903380cf05a3d313a3a Mon Sep 17 00:00:00 2001
+From 6594bba195d9047e43e30d22170baab5f103d08a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 872e846f6bb31afbdd508903380cf05a3d313a3a ]
@@ -77 +79,0 @@
-Cc: stable@dpdk.org
@@ -85 +87 @@
-index 7fcd27ee0c..ab34285ed9 100644
+index 6b7b16f348..0b059bfd0b 100644
@@ -88 +90 @@
-@@ -363,27 +363,12 @@ static int
+@@ -332,27 +332,12 @@ static int
@@ -116 +118 @@
-@@ -510,6 +495,7 @@ eth_dev_close(struct rte_eth_dev *dev)
+@@ -447,6 +432,7 @@ eth_dev_close(struct rte_eth_dev *dev)
@@ -124 +126 @@
-@@ -520,6 +506,20 @@ eth_dev_close(struct rte_eth_dev *dev)
+@@ -457,6 +443,20 @@ eth_dev_close(struct rte_eth_dev *dev)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'ethdev: fix functions available in new device event' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (34 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/af_packet: fix socket close on device stop' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'vhost: add null callback checks' " Xueming Li
` (51 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Huisong Li; +Cc: xuemingl, Thomas Monjalon, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c1c2fd8405a0f6bef24a1a1375ddafdecf285f7e
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From c1c2fd8405a0f6bef24a1a1375ddafdecf285f7e Mon Sep 17 00:00:00 2001
From: Huisong Li <lihuisong@huawei.com>
Date: Fri, 17 Jan 2025 17:12:10 +0800
Subject: [PATCH] ethdev: fix functions available in new device event
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 0b8f35358ceb0178878f72b66a36dc0ab7924377 ]
During probing, before the port becomes generally available, the
rte_eth_dev_socket_id() and rte_eth_dev_owner_*() are available to
the application.
Fixes: 7dcd73e37965 ("drivers/bus: set device NUMA node to unknown by default")
Fixes: 53ef1b34776b ("ethdev: add sanity checks in control APIs")
Signed-off-by: Huisong Li <lihuisong@huawei.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
---
lib/ethdev/rte_ethdev.c | 14 +++++++++++---
lib/ethdev/rte_ethdev.h | 8 +++++++-
2 files changed, 18 insertions(+), 4 deletions(-)
diff --git a/lib/ethdev/rte_ethdev.c b/lib/ethdev/rte_ethdev.c
index dfcdf76fee..86fd457f78 100644
--- a/lib/ethdev/rte_ethdev.c
+++ b/lib/ethdev/rte_ethdev.c
@@ -600,9 +600,10 @@ rte_eth_dev_owner_get(const uint16_t port_id, struct rte_eth_dev_owner *owner)
struct rte_eth_dev *ethdev;
int ret;
- RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
- ethdev = &rte_eth_devices[port_id];
+ if (port_id >= RTE_MAX_ETHPORTS)
+ return -ENODEV;
+ ethdev = &rte_eth_devices[port_id];
if (!eth_dev_is_allocated(ethdev)) {
RTE_ETHDEV_LOG(ERR, "Port ID %"PRIu16" is not allocated\n",
port_id);
@@ -635,8 +636,15 @@ int
rte_eth_dev_socket_id(uint16_t port_id)
{
int socket_id = SOCKET_ID_ANY;
+ struct rte_eth_dev *ethdev;
- if (!rte_eth_dev_is_valid_port(port_id)) {
+ if (port_id >= RTE_MAX_ETHPORTS) {
+ rte_errno = EINVAL;
+ return socket_id;
+ }
+
+ ethdev = &rte_eth_devices[port_id];
+ if (!eth_dev_is_allocated(ethdev)) {
rte_errno = EINVAL;
} else {
socket_id = rte_eth_devices[port_id].data->numa_node;
diff --git a/lib/ethdev/rte_ethdev.h b/lib/ethdev/rte_ethdev.h
index 545799c341..089bf3626d 100644
--- a/lib/ethdev/rte_ethdev.h
+++ b/lib/ethdev/rte_ethdev.h
@@ -4029,7 +4029,13 @@ enum rte_eth_event_type {
RTE_ETH_EVENT_VF_MBOX, /**< message from the VF received by PF */
RTE_ETH_EVENT_MACSEC, /**< MACsec offload related event */
RTE_ETH_EVENT_INTR_RMV, /**< device removal event */
- RTE_ETH_EVENT_NEW, /**< port is probed */
+ /**
+ * The port is being probed, i.e. allocated and not yet available.
+ * It is too early to check validity, query infos, and configure
+ * the port. But some functions, like rte_eth_dev_socket_id() and
+ * rte_eth_dev_owner_*() are available to the application.
+ */
+ RTE_ETH_EVENT_NEW,
RTE_ETH_EVENT_DESTROY, /**< port is released */
RTE_ETH_EVENT_IPSEC, /**< IPsec offload related event */
RTE_ETH_EVENT_FLOW_AGED,/**< New aged-out flows is detected */
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.017703608 +0800
+++ 0036-ethdev-fix-functions-available-in-new-device-event.patch 2025-02-18 19:39:00.538244063 +0800
@@ -1 +1 @@
-From 0b8f35358ceb0178878f72b66a36dc0ab7924377 Mon Sep 17 00:00:00 2001
+From c1c2fd8405a0f6bef24a1a1375ddafdecf285f7e Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 0b8f35358ceb0178878f72b66a36dc0ab7924377 ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -18,2 +20,2 @@
- lib/ethdev/rte_ethdev.h | 3 ++-
- 2 files changed, 13 insertions(+), 4 deletions(-)
+ lib/ethdev/rte_ethdev.h | 8 +++++++-
+ 2 files changed, 18 insertions(+), 4 deletions(-)
@@ -22 +24 @@
-index b7cb26f0d3..c4079bb924 100644
+index dfcdf76fee..86fd457f78 100644
@@ -25 +27 @@
-@@ -602,9 +602,10 @@ rte_eth_dev_owner_get(const uint16_t port_id, struct rte_eth_dev_owner *owner)
+@@ -600,9 +600,10 @@ rte_eth_dev_owner_get(const uint16_t port_id, struct rte_eth_dev_owner *owner)
@@ -36 +38 @@
- RTE_ETHDEV_LOG_LINE(ERR, "Port ID %"PRIu16" is not allocated",
+ RTE_ETHDEV_LOG(ERR, "Port ID %"PRIu16" is not allocated\n",
@@ -38 +40 @@
-@@ -637,8 +638,15 @@ int
+@@ -635,8 +636,15 @@ int
@@ -56 +58 @@
-index 978104d232..40d97b17d4 100644
+index 545799c341..089bf3626d 100644
@@ -59,5 +61,8 @@
-@@ -4162,7 +4162,8 @@ enum rte_eth_event_type {
- /**
- * The port is being probed, i.e. allocated and not yet available.
- * It is too early to check validity, query infos, and configure
-- * the port.
+@@ -4029,7 +4029,13 @@ enum rte_eth_event_type {
+ RTE_ETH_EVENT_VF_MBOX, /**< message from the VF received by PF */
+ RTE_ETH_EVENT_MACSEC, /**< MACsec offload related event */
+ RTE_ETH_EVENT_INTR_RMV, /**< device removal event */
+- RTE_ETH_EVENT_NEW, /**< port is probed */
++ /**
++ * The port is being probed, i.e. allocated and not yet available.
++ * It is too early to check validity, query infos, and configure
@@ -66,2 +71,2 @@
- */
- RTE_ETH_EVENT_NEW,
++ */
++ RTE_ETH_EVENT_NEW,
@@ -68,0 +74,2 @@
+ RTE_ETH_EVENT_IPSEC, /**< IPsec offload related event */
+ RTE_ETH_EVENT_FLOW_AGED,/**< New aged-out flows is detected */
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'vhost: add null callback checks' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (35 preceding siblings ...)
2025-02-18 12:34 ` patch 'ethdev: fix functions available in new device event' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'build: force GCC 15 to initialize padding bits' " Xueming Li
` (50 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Kevin Traynor; +Cc: xuemingl, Maxime Coquelin, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c452aa7dc067ca90419d85ba633ca8dedbae312c
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From c452aa7dc067ca90419d85ba633ca8dedbae312c Mon Sep 17 00:00:00 2001
From: Kevin Traynor <ktraynor@redhat.com>
Date: Fri, 24 Jan 2025 14:14:07 +0000
Subject: [PATCH] vhost: add null callback checks
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 66be1a05a480a0484b02c1a0194126763f4dbb99 ]
rte_vhost_driver_callback_register() does not specify
any mandatory callbacks in struct rte_vhost_device_ops.
Add some missing NULL checks before calling rte_vhost_device_ops
callbacks.
Fixes: 4796ad63ba1f ("examples/vhost: import userspace vhost application")
Signed-off-by: Kevin Traynor <ktraynor@redhat.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
lib/vhost/vduse.c | 3 ++-
lib/vhost/vhost.c | 5 +++--
lib/vhost/vhost_user.c | 3 ++-
3 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c
index b46f0e53c7..3b1a3b008e 100644
--- a/lib/vhost/vduse.c
+++ b/lib/vhost/vduse.c
@@ -317,7 +317,8 @@ vduse_device_start(struct virtio_net *dev)
dev->flags |= VIRTIO_DEV_READY;
- if (dev->notify_ops->new_device(dev->vid) == 0)
+ if (!dev->notify_ops->new_device ||
+ dev->notify_ops->new_device(dev->vid) == 0)
dev->flags |= VIRTIO_DEV_RUNNING;
for (i = 0; i < dev->nr_vring; i++) {
diff --git a/lib/vhost/vhost.c b/lib/vhost/vhost.c
index 8a1f992d9d..276c5f12b7 100644
--- a/lib/vhost/vhost.c
+++ b/lib/vhost/vhost.c
@@ -750,10 +750,11 @@ vhost_destroy_device_notify(struct virtio_net *dev)
if (dev->flags & VIRTIO_DEV_RUNNING) {
vdpa_dev = dev->vdpa_dev;
- if (vdpa_dev)
+ if (vdpa_dev && vdpa_dev->ops->dev_close)
vdpa_dev->ops->dev_close(dev->vid);
dev->flags &= ~VIRTIO_DEV_RUNNING;
- dev->notify_ops->destroy_device(dev->vid);
+ if (dev->notify_ops->destroy_device)
+ dev->notify_ops->destroy_device(dev->vid);
}
}
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index 14808bd5bc..e01675e478 100644
--- a/lib/vhost/vhost_user.c
+++ b/lib/vhost/vhost_user.c
@@ -3280,7 +3280,8 @@ unlock:
*/
if (!(dev->flags & VIRTIO_DEV_RUNNING)) {
- if (dev->notify_ops->new_device(dev->vid) == 0)
+ if (!dev->notify_ops->new_device ||
+ dev->notify_ops->new_device(dev->vid) == 0)
dev->flags |= VIRTIO_DEV_RUNNING;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.055757102 +0800
+++ 0037-vhost-add-null-callback-checks.patch 2025-02-18 19:39:00.548244061 +0800
@@ -1 +1 @@
-From 66be1a05a480a0484b02c1a0194126763f4dbb99 Mon Sep 17 00:00:00 2001
+From c452aa7dc067ca90419d85ba633ca8dedbae312c Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 66be1a05a480a0484b02c1a0194126763f4dbb99 ]
@@ -13 +15,0 @@
-Cc: stable@dpdk.org
@@ -24 +26 @@
-index 8ba58555f9..be548f051e 100644
+index b46f0e53c7..3b1a3b008e 100644
@@ -27 +29 @@
-@@ -318,7 +318,8 @@ vduse_device_start(struct virtio_net *dev, bool reconnect)
+@@ -317,7 +317,8 @@ vduse_device_start(struct virtio_net *dev)
@@ -38 +40 @@
-index 2f34d3500e..f01ae6130e 100644
+index 8a1f992d9d..276c5f12b7 100644
@@ -41 +43 @@
-@@ -751,10 +751,11 @@ vhost_destroy_device_notify(struct virtio_net *dev)
+@@ -750,10 +750,11 @@ vhost_destroy_device_notify(struct virtio_net *dev)
@@ -56 +58 @@
-index 52d8078d7c..26dc0bde97 100644
+index 14808bd5bc..e01675e478 100644
@@ -59 +61 @@
-@@ -3301,7 +3301,8 @@ unlock:
+@@ -3280,7 +3280,8 @@ unlock:
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'build: force GCC 15 to initialize padding bits' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (36 preceding siblings ...)
2025-02-18 12:34 ` patch 'vhost: add null callback checks' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/bnxt: fix indication of allocation' " Xueming Li
` (49 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Stephen Hemminger
Cc: xuemingl, Morten Brørup, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=9fa42e1aec84ff057805160f38ee1537e74608b0
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 9fa42e1aec84ff057805160f38ee1537e74608b0 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 24 Jan 2025 10:26:48 -0800
Subject: [PATCH] build: force GCC 15 to initialize padding bits
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 3c015da37afecbeaa7c9ebf8cf2adcb20ab0e54d ]
With GCC 15, the compiler has changed the default behavior when
initialization is used for aggregate variables. The new default
is to follow the standard (C23) and not initialize everything by
default. This breaks assumptions in some drivers and can be
lead to other bugs. Use the new zero initialization flag to
force of all fields to zero.
Note: other compilers always initialize to zero in these cases.
Only GCC seems to have decided to start initializing less as
a silly attempt at optimization.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
config/meson.build | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/config/meson.build b/config/meson.build
index 898b719929..394d612924 100644
--- a/config/meson.build
+++ b/config/meson.build
@@ -303,7 +303,7 @@ endif
# enable extra warnings and disable any unwanted warnings
# -Wall is added by default at warning level 1, and -Wextra
# at warning level 2 (DPDK default)
-warning_flags = [
+global_cflags = [
# additional warnings in alphabetical order
'-Wcast-qual',
'-Wdeprecated',
@@ -324,22 +324,25 @@ warning_flags = [
'-Wno-address-of-packed-member',
'-Wno-packed-not-aligned',
'-Wno-missing-field-initializers',
+
+ # guarantee that all non-initialized parts of structure/union are zero
+ '-fzero-init-padding-bits=all',
]
if cc.get_id() == 'gcc' and cc.version().version_compare('>=10.0')
# FIXME: Bugzilla 396
- warning_flags += '-Wno-zero-length-bounds'
+ global_cflags += '-Wno-zero-length-bounds'
endif
if not dpdk_conf.get('RTE_ARCH_64')
# for 32-bit, don't warn about casting a 32-bit pointer to 64-bit int - it's fine!!
- warning_flags += '-Wno-pointer-to-int-cast'
+ global_cflags += '-Wno-pointer-to-int-cast'
endif
if cc.get_id() == 'intel'
warning_ids = [181, 188, 2203, 2279, 2557, 3179, 3656]
foreach i:warning_ids
- warning_flags += '-diag-disable=@0@'.format(i)
+ global_cflags += '-diag-disable=@0@'.format(i)
endforeach
endif
-foreach arg: warning_flags
+foreach arg: global_cflags
if cc.has_argument(arg)
add_project_arguments(arg, language: 'c')
endif
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.089365896 +0800
+++ 0038-build-force-GCC-15-to-initialize-padding-bits.patch 2025-02-18 19:39:00.548244061 +0800
@@ -1 +1 @@
-From 3c015da37afecbeaa7c9ebf8cf2adcb20ab0e54d Mon Sep 17 00:00:00 2001
+From 9fa42e1aec84ff057805160f38ee1537e74608b0 Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 3c015da37afecbeaa7c9ebf8cf2adcb20ab0e54d ]
@@ -20,2 +22,0 @@
-Cc: stable@dpdk.org
-
@@ -26,2 +27,2 @@
- config/meson.build | 11 +++++++----
- 1 file changed, 7 insertions(+), 4 deletions(-)
+ config/meson.build | 13 ++++++++-----
+ 1 file changed, 8 insertions(+), 5 deletions(-)
@@ -30 +31 @@
-index 710206095b..f31fef216c 100644
+index 898b719929..394d612924 100644
@@ -33 +34 @@
-@@ -310,7 +310,7 @@ endif
+@@ -303,7 +303,7 @@ endif
@@ -42,2 +43,2 @@
-@@ -330,16 +330,19 @@ warning_flags = [
- # globally disabled warnings
+@@ -324,22 +324,25 @@ warning_flags = [
+ '-Wno-address-of-packed-member',
@@ -50 +51,5 @@
-
+ if cc.get_id() == 'gcc' and cc.version().version_compare('>=10.0')
+ # FIXME: Bugzilla 396
+- warning_flags += '-Wno-zero-length-bounds'
++ global_cflags += '-Wno-zero-length-bounds'
+ endif
@@ -63,5 +67,0 @@
-
-@@ -351,7 +354,7 @@ if cc.has_argument('-Wvla')
- endif
- endif
-
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/bnxt: fix indication of allocation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (37 preceding siblings ...)
2025-02-18 12:34 ` patch 'build: force GCC 15 to initialize padding bits' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/bnxt: fix crash when representor is re-attached' " Xueming Li
` (48 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Andre Muezerie; +Cc: xuemingl, Ajit Khaparde, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=378ab42db956366cf0160937cf6eb6db61530787
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 378ab42db956366cf0160937cf6eb6db61530787 Mon Sep 17 00:00:00 2001
From: Andre Muezerie <andremue@linux.microsoft.com>
Date: Fri, 17 Jan 2025 12:51:33 -0800
Subject: [PATCH] net/bnxt: fix indication of allocation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 8531f9ba0062032454121f4959cd3d495cd4147e ]
When experimenting with the -std=c2x compiler option the error below
popped up:
../drivers/net/bnxt/tf_core/tf_sram_mgr.c:952:39: error: incompatible
types when assigning to type ‘_Bool *’ from type ‘_Bool’
The code indicates that the intention was to assign false to the bool
being pointed to, not to the pointer itself.
Fixes: 37ff91c158a3 ("net/bnxt: add SRAM manager model")
Signed-off-by: Andre Muezerie <andremue@linux.microsoft.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
drivers/net/bnxt/tf_core/tf_sram_mgr.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/bnxt/tf_core/tf_sram_mgr.c b/drivers/net/bnxt/tf_core/tf_sram_mgr.c
index 87e8882fed..0dffd74cd5 100644
--- a/drivers/net/bnxt/tf_core/tf_sram_mgr.c
+++ b/drivers/net/bnxt/tf_core/tf_sram_mgr.c
@@ -949,7 +949,7 @@ int tf_sram_mgr_is_allocated(void *sram_handle,
tf_sram_slice_2_str(parms->slice_size),
tf_sram_bank_2_str(parms->bank_id));
- parms->is_allocated = false;
+ *parms->is_allocated = false;
goto done;
}
@@ -964,7 +964,7 @@ int tf_sram_mgr_is_allocated(void *sram_handle,
if (block == NULL) {
TFP_DRV_LOG(ERR, "block not found in list 0x%x\n",
parms->sram_offset);
- parms->is_allocated = false;
+ *parms->is_allocated = false;
goto done;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.121518390 +0800
+++ 0039-net-bnxt-fix-indication-of-allocation.patch 2025-02-18 19:39:00.548244061 +0800
@@ -1 +1 @@
-From 8531f9ba0062032454121f4959cd3d495cd4147e Mon Sep 17 00:00:00 2001
+From 378ab42db956366cf0160937cf6eb6db61530787 Mon Sep 17 00:00:00 2001
@@ -7,0 +8,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 8531f9ba0062032454121f4959cd3d495cd4147e ]
@@ -19 +21,0 @@
-Cc: stable@dpdk.org
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/bnxt: fix crash when representor is re-attached' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (38 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/bnxt: fix indication of allocation' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/mlx5: fix Netlink socket leak' " Xueming Li
` (47 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Sangtani Parag Satishbhai
Cc: xuemingl, Somnath Kotur, Kalesh AP, Ajit Khaparde, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=5bdead115568a2e275aa60e36752d22ad25dad61
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 5bdead115568a2e275aa60e36752d22ad25dad61 Mon Sep 17 00:00:00 2001
From: Sangtani Parag Satishbhai <parag-satishbhai.sangtani@broadcom.com>
Date: Thu, 19 Dec 2024 17:31:13 -0800
Subject: [PATCH] net/bnxt: fix crash when representor is re-attached
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit fca6cf68bbcf9b84e4388239031fb168a6624375 ]
When the PCI port is detached using the testpmd command,
as part of cleanup testpmd removes resources of parent
port and all the children's ports and calls the driver specific
pci_remove API with the parent rte ethdev to clean-up ethdevs.
For the bnxt driver, a condition to check type of ethdev is added
in bnxt_pci_remove and based on the condition relevant
ethdev is removed (VF/PF or VFR). As the RTE layer always
calls PCI remove with the parent ethdev, the bnxt_pci_remove
never frees children (VFRs) ethdev. As, these ethdevs were not
freed it gives spurious status in re-allocation check(when pci
port attach command is executed) and when RTE layers tries to
access interrupt specific info from the ethdev due to uninitialized
members it access NULL pointer which results in seg fault. The fix
is made in bnxt_pci_remove to clean ethdev for parent (PF/VF) along
with children (VFRs).
Fixes: 322bd6e70272 ("net/bnxt: add port representor infrastructure")
Signed-off-by: Sangtani Parag Satishbhai <parag-satishbhai.sangtani@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
drivers/net/bnxt/bnxt_ethdev.c | 22 +++++++++++++++-------
1 file changed, 15 insertions(+), 7 deletions(-)
diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c
index 988895a065..35d9e0b53b 100644
--- a/drivers/net/bnxt/bnxt_ethdev.c
+++ b/drivers/net/bnxt/bnxt_ethdev.c
@@ -6440,6 +6440,8 @@ static int bnxt_pci_probe(struct rte_pci_driver *pci_drv __rte_unused,
static int bnxt_pci_remove(struct rte_pci_device *pci_dev)
{
struct rte_eth_dev *eth_dev;
+ uint16_t port_id;
+ int rc = 0;
eth_dev = rte_eth_dev_allocated(pci_dev->device.name);
if (!eth_dev)
@@ -6449,14 +6451,20 @@ static int bnxt_pci_remove(struct rte_pci_device *pci_dev)
* +ve value will at least help in proper cleanup
*/
- PMD_DRV_LOG(DEBUG, "BNXT Port:%d pci remove\n", eth_dev->data->port_id);
if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
- if (eth_dev->data->dev_flags & RTE_ETH_DEV_REPRESENTOR)
- return rte_eth_dev_destroy(eth_dev,
- bnxt_representor_uninit);
- else
- return rte_eth_dev_destroy(eth_dev,
- bnxt_dev_uninit);
+ RTE_ETH_FOREACH_DEV_OF(port_id, &pci_dev->device) {
+ PMD_DRV_LOG(DEBUG, "BNXT Port:%d pci remove", port_id);
+ eth_dev = &rte_eth_devices[port_id];
+ if (eth_dev->data->dev_flags & RTE_ETH_DEV_REPRESENTOR)
+ rc = rte_eth_dev_destroy(eth_dev,
+ bnxt_representor_uninit);
+ else
+ rc = rte_eth_dev_destroy(eth_dev,
+ bnxt_dev_uninit);
+ if (rc != 0)
+ return rc;
+ }
+ return rc;
} else {
return rte_eth_dev_pci_generic_remove(pci_dev, NULL);
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.154466185 +0800
+++ 0040-net-bnxt-fix-crash-when-representor-is-re-attached.patch 2025-02-18 19:39:00.548244061 +0800
@@ -1 +1 @@
-From fca6cf68bbcf9b84e4388239031fb168a6624375 Mon Sep 17 00:00:00 2001
+From 5bdead115568a2e275aa60e36752d22ad25dad61 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit fca6cf68bbcf9b84e4388239031fb168a6624375 ]
@@ -23 +25,0 @@
-Cc: stable@dpdk.org
@@ -34 +36 @@
-index b18247feb2..144d4377bd 100644
+index 988895a065..35d9e0b53b 100644
@@ -37 +39 @@
-@@ -6993,6 +6993,8 @@ static int bnxt_pci_probe(struct rte_pci_driver *pci_drv __rte_unused,
+@@ -6440,6 +6440,8 @@ static int bnxt_pci_probe(struct rte_pci_driver *pci_drv __rte_unused,
@@ -46 +48 @@
-@@ -7002,14 +7004,20 @@ static int bnxt_pci_remove(struct rte_pci_device *pci_dev)
+@@ -6449,14 +6451,20 @@ static int bnxt_pci_remove(struct rte_pci_device *pci_dev)
@@ -50 +52 @@
-- PMD_DRV_LOG_LINE(DEBUG, "BNXT Port:%d pci remove", eth_dev->data->port_id);
+- PMD_DRV_LOG(DEBUG, "BNXT Port:%d pci remove\n", eth_dev->data->port_id);
@@ -52 +54 @@
-- if (rte_eth_dev_is_repr(eth_dev))
+- if (eth_dev->data->dev_flags & RTE_ETH_DEV_REPRESENTOR)
@@ -59 +61 @@
-+ PMD_DRV_LOG_LINE(DEBUG, "BNXT Port:%d pci remove", port_id);
++ PMD_DRV_LOG(DEBUG, "BNXT Port:%d pci remove", port_id);
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/mlx5: fix Netlink socket leak' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (39 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/bnxt: fix crash when representor is re-attached' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/mlx5: adjust actions per rule limitation' " Xueming Li
` (46 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Minggang Li (Gavin); +Cc: xuemingl, Viacheslav Ovsiienko, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=e0ddea424190d6214b8b532ef03c1a45c88a1174
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From e0ddea424190d6214b8b532ef03c1a45c88a1174 Mon Sep 17 00:00:00 2001
From: "Minggang Li (Gavin)" <gavinl@nvidia.com>
Date: Mon, 23 Dec 2024 12:10:58 +0200
Subject: [PATCH] net/mlx5: fix Netlink socket leak
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 556a5f4ccd452d9281c3476b120d1306e0093e01 ]
Fixes: 72d7efe464b1 ("common/mlx5: share interrupt management")
Signed-off-by: Minggang Li (Gavin) <gavinl@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
.mailmap | 1 +
drivers/net/mlx5/linux/mlx5_os.c | 5 +++++
2 files changed, 6 insertions(+)
diff --git a/.mailmap b/.mailmap
index 60eac79c6b..6984cb9940 100644
--- a/.mailmap
+++ b/.mailmap
@@ -982,6 +982,7 @@ Mike Stolarchuk <mike.stolarchuk@bigswitch.com>
Mike Ximing Chen <mike.ximing.chen@intel.com>
Milena Olech <milena.olech@intel.com>
Min Cao <min.cao@intel.com>
+Minggang Li (Gavin) <gavinl@nvidia.com>
Minghuan Lian <minghuan.lian@nxp.com>
Mingjin Ye <mingjinx.ye@intel.com>
Mingshan Zhang <mingshan.zhang@intel.com>
diff --git a/drivers/net/mlx5/linux/mlx5_os.c b/drivers/net/mlx5/linux/mlx5_os.c
index 9dcdc8581a..fdc4dc1cf8 100644
--- a/drivers/net/mlx5/linux/mlx5_os.c
+++ b/drivers/net/mlx5/linux/mlx5_os.c
@@ -2968,10 +2968,15 @@ mlx5_os_dev_shared_handler_install(struct mlx5_dev_ctx_shared *sh)
void
mlx5_os_dev_shared_handler_uninstall(struct mlx5_dev_ctx_shared *sh)
{
+ int fd;
+
mlx5_os_interrupt_handler_destroy(sh->intr_handle,
mlx5_dev_interrupt_handler, sh);
+ fd = rte_intr_fd_get(sh->intr_handle_nl);
mlx5_os_interrupt_handler_destroy(sh->intr_handle_nl,
mlx5_dev_interrupt_handler_nl, sh);
+ if (fd >= 0)
+ close(fd);
#ifdef HAVE_IBV_DEVX_ASYNC
mlx5_os_interrupt_handler_destroy(sh->intr_handle_devx,
mlx5_dev_interrupt_handler_devx, sh);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.186725979 +0800
+++ 0041-net-mlx5-fix-Netlink-socket-leak.patch 2025-02-18 19:39:00.558244060 +0800
@@ -1 +1 @@
-From 556a5f4ccd452d9281c3476b120d1306e0093e01 Mon Sep 17 00:00:00 2001
+From e0ddea424190d6214b8b532ef03c1a45c88a1174 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 556a5f4ccd452d9281c3476b120d1306e0093e01 ]
@@ -7 +9,0 @@
-Cc: stable@dpdk.org
@@ -17 +19 @@
-index 4bc9721321..dc3dd9e5a2 100644
+index 60eac79c6b..6984cb9940 100644
@@ -20 +22 @@
-@@ -1036,6 +1036,7 @@ Mike Stolarchuk <mike.stolarchuk@bigswitch.com>
+@@ -982,6 +982,7 @@ Mike Stolarchuk <mike.stolarchuk@bigswitch.com>
@@ -29 +31 @@
-index 996c97a6a9..169c229172 100644
+index 9dcdc8581a..fdc4dc1cf8 100644
@@ -32 +34 @@
-@@ -3070,10 +3070,15 @@ mlx5_os_dev_shared_handler_install(struct mlx5_dev_ctx_shared *sh)
+@@ -2968,10 +2968,15 @@ mlx5_os_dev_shared_handler_install(struct mlx5_dev_ctx_shared *sh)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/mlx5: adjust actions per rule limitation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (40 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/mlx5: fix Netlink socket leak' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/mlx5: fix flush of non-template flow rules' " Xueming Li
` (45 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Maayan Kashani; +Cc: xuemingl, Dariusz Sosnowski, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=191a7d7a4979262752fb5213c9027de86a34f36a
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 191a7d7a4979262752fb5213c9027de86a34f36a Mon Sep 17 00:00:00 2001
From: Maayan Kashani <mkashani@nvidia.com>
Date: Tue, 28 Jan 2025 09:54:03 +0200
Subject: [PATCH] net/mlx5: adjust actions per rule limitation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit ab54e17fe2f5207d7b988d568344570e156551ad ]
HWS implementation added a limitation of 16 actions per rule,
which was incompatible with SWS limitation of 32 actions per rule.
Changing the hard coded limitation in PMD to 32.
Fixes: f13fab23922b ("net/mlx5: add flow jump action")
Signed-off-by: Maayan Kashani <mkashani@nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
---
drivers/net/mlx5/mlx5_flow.h | 2 +-
drivers/net/mlx5/mlx5_flow_hw.c | 3 ---
2 files changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/net/mlx5/mlx5_flow.h b/drivers/net/mlx5/mlx5_flow.h
index 01f0eab1fa..9d18a576ae 100644
--- a/drivers/net/mlx5/mlx5_flow.h
+++ b/drivers/net/mlx5/mlx5_flow.h
@@ -1422,7 +1422,7 @@ struct mlx5_hw_modify_header_action {
};
/* The maximum actions support in the flow. */
-#define MLX5_HW_MAX_ACTS 16
+#define MLX5_HW_MAX_ACTS 32
/* DR action set struct. */
struct mlx5_hw_actions {
diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index 3dc26d5a0b..54f264a03c 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -14,9 +14,6 @@
#if defined(HAVE_IBV_FLOW_DV_SUPPORT) || !defined(HAVE_INFINIBAND_VERBS_H)
#include "mlx5_hws_cnt.h"
-/* The maximum actions support in the flow. */
-#define MLX5_HW_MAX_ACTS 16
-
/*
* The default ipool threshold value indicates which per_core_cache
* value to set.
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.222995573 +0800
+++ 0042-net-mlx5-adjust-actions-per-rule-limitation.patch 2025-02-18 19:39:00.578244056 +0800
@@ -1 +1 @@
-From ab54e17fe2f5207d7b988d568344570e156551ad Mon Sep 17 00:00:00 2001
+From 191a7d7a4979262752fb5213c9027de86a34f36a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit ab54e17fe2f5207d7b988d568344570e156551ad ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +24 @@
-index 93c2406abc..445c9cdb4b 100644
+index 01f0eab1fa..9d18a576ae 100644
@@ -25 +27 @@
-@@ -1583,7 +1583,7 @@ struct mlx5_hw_modify_header_action {
+@@ -1422,7 +1422,7 @@ struct mlx5_hw_modify_header_action {
@@ -35 +37 @@
-index 2b62711413..501bf33f94 100644
+index 3dc26d5a0b..54f264a03c 100644
@@ -38,3 +40,3 @@
-@@ -21,9 +21,6 @@
- /** Fast path async flow API functions. */
- static struct rte_flow_fp_ops mlx5_flow_hw_fp_ops;
+@@ -14,9 +14,6 @@
+ #if defined(HAVE_IBV_FLOW_DV_SUPPORT) || !defined(HAVE_INFINIBAND_VERBS_H)
+ #include "mlx5_hws_cnt.h"
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/mlx5: fix flush of non-template flow rules' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (41 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/mlx5: adjust actions per rule limitation' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/mlx5: fix GRE flow match with SWS' " Xueming Li
` (44 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Maayan Kashani; +Cc: xuemingl, Bing Zhao, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=ef46fae0d4f7dd2cba8356f2700725d868d56b87
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From ef46fae0d4f7dd2cba8356f2700725d868d56b87 Mon Sep 17 00:00:00 2001
From: Maayan Kashani <mkashani@nvidia.com>
Date: Tue, 28 Jan 2025 09:54:05 +0200
Subject: [PATCH] net/mlx5: fix flush of non-template flow rules
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 716929be9456b78875d0eb20bc54c13acf99efc0 ]
Fix flow flush for non template flows on top of HWS,
in another fix it was added return after releasing template flows.
Need to drop the return in order to release non template list of flows.
Fixes: 1ea333d2de22 ("net/mlx5: fix Rx queue reference count in flushing flows")
Signed-off-by: Maayan Kashani <mkashani@nvidia.com>
Acked-by: Bing Zhao <bingz@nvidia.com>
---
drivers/net/mlx5/mlx5_flow.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c
index 1e9484f372..97f678ff4e 100644
--- a/drivers/net/mlx5/mlx5_flow.c
+++ b/drivers/net/mlx5/mlx5_flow.c
@@ -8104,7 +8104,6 @@ mlx5_flow_list_flush(struct rte_eth_dev *dev, enum mlx5_flow_type type,
priv->hws_rule_flushing = true;
flow_hw_q_flow_flush(dev, NULL);
priv->hws_rule_flushing = false;
- return;
}
#endif
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.270644365 +0800
+++ 0043-net-mlx5-fix-flush-of-non-template-flow-rules.patch 2025-02-18 19:39:00.588244055 +0800
@@ -1 +1 @@
-From 716929be9456b78875d0eb20bc54c13acf99efc0 Mon Sep 17 00:00:00 2001
+From ef46fae0d4f7dd2cba8356f2700725d868d56b87 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 716929be9456b78875d0eb20bc54c13acf99efc0 ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -20 +22 @@
-index bfc44f25bf..a2ee237841 100644
+index 1e9484f372..97f678ff4e 100644
@@ -23 +25 @@
-@@ -8118,7 +8118,6 @@ mlx5_flow_list_flush(struct rte_eth_dev *dev, enum mlx5_flow_type type,
+@@ -8104,7 +8104,6 @@ mlx5_flow_list_flush(struct rte_eth_dev *dev, enum mlx5_flow_type type,
@@ -30 +32 @@
- MLX5_IPOOL_FOREACH(priv->flows[type], fidx, flow) {
+
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/mlx5: fix GRE flow match with SWS' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (42 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/mlx5: fix flush of non-template flow rules' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix deadlock when writing i225 register' " Xueming Li
` (43 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Maayan Kashani; +Cc: xuemingl, Bing Zhao, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=b81990ea04c23689ce76df612e7ada1eb9c6de76
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From b81990ea04c23689ce76df612e7ada1eb9c6de76 Mon Sep 17 00:00:00 2001
From: Maayan Kashani <mkashani@nvidia.com>
Date: Tue, 28 Jan 2025 09:59:30 +0200
Subject: [PATCH] net/mlx5: fix GRE flow match with SWS
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 05db99c117e36c0cd28cda8f558309efd20055da ]
The previous GRE fix was meant to handle HWS behavior
and changed the behavior for SWS causing degradation.
After the previous fix, in case of an empty GRE match,
GRE mask was initialized with protocol full mask,
Instead of the empty mask with protocol mask equals zero.
The current fix handles the SWS case as before the GRE fix,
and HWS according to the latest fix.
Also, combined common logic.
Fixes: 25ab2cbba31d ("net/mlx5: fix GRE flow item translation for root table")
Signed-off-by: Maayan Kashani <mkashani@nvidia.com>
Acked-by: Bing Zhao <bingz@nvidia.com>
---
drivers/net/mlx5/mlx5_flow_dv.c | 27 +++++++++++++++------------
1 file changed, 15 insertions(+), 12 deletions(-)
diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c
index 09c7068339..80edb4e966 100644
--- a/drivers/net/mlx5/mlx5_flow_dv.c
+++ b/drivers/net/mlx5/mlx5_flow_dv.c
@@ -9476,23 +9476,26 @@ flow_dv_translate_item_gre(void *key, const struct rte_flow_item *item,
} gre_crks_rsvd0_ver_m, gre_crks_rsvd0_ver_v;
uint16_t protocol_m, protocol_v;
- if (key_type & MLX5_SET_MATCHER_M) {
+ /* Common logic to SWS/HWS */
+ if (key_type & MLX5_SET_MATCHER_M)
MLX5_SET(fte_match_set_lyr_2_4, headers_v, ip_protocol, 0xff);
+ else
+ MLX5_SET(fte_match_set_lyr_2_4, headers_v, ip_protocol,
+ IPPROTO_GRE);
+ /* HWS mask logic only */
+ if (key_type & MLX5_SET_MATCHER_HS_M) {
if (!gre_m)
gre_m = &rte_flow_item_gre_mask;
gre_v = gre_m;
- } else {
- MLX5_SET(fte_match_set_lyr_2_4, headers_v, ip_protocol,
- IPPROTO_GRE);
- if (!gre_v) {
- gre_v = &empty_gre;
- gre_m = &empty_gre;
- } else if (!gre_m) {
- gre_m = &rte_flow_item_gre_mask;
- }
- if (key_type == MLX5_SET_MATCHER_HS_V)
- gre_m = gre_v;
+ } else if (!gre_v) {
+ gre_v = &empty_gre;
+ gre_m = &empty_gre;
+ } else if (!gre_m) {
+ gre_m = &rte_flow_item_gre_mask;
}
+ /* SWS logic only */
+ if (key_type & MLX5_SET_MATCHER_SW_M)
+ gre_v = gre_m;
gre_crks_rsvd0_ver_m.value = rte_be_to_cpu_16(gre_m->c_rsvd0_ver);
gre_crks_rsvd0_ver_v.value = rte_be_to_cpu_16(gre_v->c_rsvd0_ver);
MLX5_SET(fte_match_set_misc, misc_v, gre_c_present,
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.306600159 +0800
+++ 0044-net-mlx5-fix-GRE-flow-match-with-SWS.patch 2025-02-18 19:39:00.608244051 +0800
@@ -1 +1 @@
-From 05db99c117e36c0cd28cda8f558309efd20055da Mon Sep 17 00:00:00 2001
+From b81990ea04c23689ce76df612e7ada1eb9c6de76 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 05db99c117e36c0cd28cda8f558309efd20055da ]
@@ -18 +20,0 @@
-Cc: stable@dpdk.org
@@ -27 +29 @@
-index 41ebe0b61a..633c41e358 100644
+index 09c7068339..80edb4e966 100644
@@ -30 +32 @@
-@@ -9839,23 +9839,26 @@ flow_dv_translate_item_gre(void *key, const struct rte_flow_item *item,
+@@ -9476,23 +9476,26 @@ flow_dv_translate_item_gre(void *key, const struct rte_flow_item *item,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix deadlock when writing i225 register' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (43 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/mlx5: fix GRE flow match with SWS' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix infinite loop' " Xueming Li
` (42 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Dima Ruinskiy; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c18541adee3de649ebd672acc4166fcb499ab608
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From c18541adee3de649ebd672acc4166fcb499ab608 Mon Sep 17 00:00:00 2001
From: Dima Ruinskiy <dima.ruinskiy@intel.com>
Date: Thu, 6 Feb 2025 16:08:24 +0000
Subject: [PATCH] net/igc/base: fix deadlock when writing i225 register
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit f05363dceac78694638f86a8af1acd173ca9e3e0 ]
Currently, when writing GPY PHY registers, semaphore is acquired before
writing. However, if writing fails, semaphore is not released, causing a
deadlock down the line. Fix the issue by removing the premature return.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
.mailmap | 1 +
drivers/net/igc/base/igc_phy.c | 4 ----
2 files changed, 1 insertion(+), 4 deletions(-)
diff --git a/.mailmap b/.mailmap
index 6984cb9940..acf910ab3b 100644
--- a/.mailmap
+++ b/.mailmap
@@ -337,6 +337,7 @@ Dheemanth Mallikarjun <dheemanthm@vmware.com>
Diana Wang <na.wang@corigine.com>
Didier Pallard <didier.pallard@6wind.com>
Dilshod Urazov <dilshod.urazov@oktetlabs.ru>
+Dima Ruinskiy <dima.ruinskiy@intel.com>
Ding Zhi <zhi.ding@6wind.com>
Diogo Behrens <diogo.behrens@huawei.com>
Dirk-Holger Lenz <dirk.lenz@ng4t.com>
diff --git a/drivers/net/igc/base/igc_phy.c b/drivers/net/igc/base/igc_phy.c
index 2906bae21a..ddc2b6ecc1 100644
--- a/drivers/net/igc/base/igc_phy.c
+++ b/drivers/net/igc/base/igc_phy.c
@@ -4148,8 +4148,6 @@ s32 igc_write_phy_reg_gpy(struct igc_hw *hw, u32 offset, u16 data)
if (ret_val)
return ret_val;
ret_val = igc_write_phy_reg_mdic(hw, offset, data);
- if (ret_val)
- return ret_val;
hw->phy.ops.release(hw);
} else {
ret_val = igc_write_xmdio_reg(hw, (u16)offset, dev_addr,
@@ -4182,8 +4180,6 @@ s32 igc_read_phy_reg_gpy(struct igc_hw *hw, u32 offset, u16 *data)
if (ret_val)
return ret_val;
ret_val = igc_read_phy_reg_mdic(hw, offset, data);
- if (ret_val)
- return ret_val;
hw->phy.ops.release(hw);
} else {
ret_val = igc_read_xmdio_reg(hw, (u16)offset, dev_addr,
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.350614651 +0800
+++ 0045-net-igc-base-fix-deadlock-when-writing-i225-register.patch 2025-02-18 19:39:00.618244049 +0800
@@ -1 +1 @@
-From f05363dceac78694638f86a8af1acd173ca9e3e0 Mon Sep 17 00:00:00 2001
+From c18541adee3de649ebd672acc4166fcb499ab608 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit f05363dceac78694638f86a8af1acd173ca9e3e0 ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -17,2 +19,2 @@
- .mailmap | 1 +
- drivers/net/intel/igc/base/igc_phy.c | 4 ----
+ .mailmap | 1 +
+ drivers/net/igc/base/igc_phy.c | 4 ----
@@ -22 +24 @@
-index dc3dd9e5a2..9ea6bd1df3 100644
+index 6984cb9940..acf910ab3b 100644
@@ -25 +27 @@
-@@ -358,6 +358,7 @@ Dhruv Tripathi <dhruv.tripathi@arm.com>
+@@ -337,6 +337,7 @@ Dheemanth Mallikarjun <dheemanthm@vmware.com>
@@ -33 +35 @@
-diff --git a/drivers/net/intel/igc/base/igc_phy.c b/drivers/net/intel/igc/base/igc_phy.c
+diff --git a/drivers/net/igc/base/igc_phy.c b/drivers/net/igc/base/igc_phy.c
@@ -35,2 +37,2 @@
---- a/drivers/net/intel/igc/base/igc_phy.c
-+++ b/drivers/net/intel/igc/base/igc_phy.c
+--- a/drivers/net/igc/base/igc_phy.c
++++ b/drivers/net/igc/base/igc_phy.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix infinite loop' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (44 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix deadlock when writing i225 register' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix bitwise operation type' " Xueming Li
` (41 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Dima Ruinskiy; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=5509313e7a3a1f7649f9ea6e4b0f03023c221e02
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 5509313e7a3a1f7649f9ea6e4b0f03023c221e02 Mon Sep 17 00:00:00 2001
From: Dima Ruinskiy <dima.ruinskiy@intel.com>
Date: Thu, 6 Feb 2025 16:08:25 +0000
Subject: [PATCH] net/igc/base: fix infinite loop
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 532e495e4a20cf09e1f42d01bcbe782f7e2bb03f ]
When the driver fails to acquire HW semaphore, there is nothing that can
be done to address it, so just leave to avoid an infinite loop.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_i225.c | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
index 17a1573064..8f01f8d918 100644
--- a/drivers/net/igc/base/igc_i225.c
+++ b/drivers/net/igc/base/igc_i225.c
@@ -333,8 +333,15 @@ void igc_release_swfw_sync_i225(struct igc_hw *hw, u16 mask)
DEBUGFUNC("igc_release_swfw_sync_i225");
- while (igc_get_hw_semaphore_i225(hw) != IGC_SUCCESS)
- ; /* Empty */
+ /* Releasing the resource requires first getting the HW semaphore.
+ * If we fail to get the semaphore, there is nothing we can do,
+ * except log an error and quit. We are not allowed to hang here
+ * indefinitely, as it may cause denial of service or system crash.
+ */
+ if (igc_get_hw_semaphore_i225(hw) != IGC_SUCCESS) {
+ DEBUGOUT("Failed to release SW_FW_SYNC.\n");
+ return;
+ }
swfw_sync = IGC_READ_REG(hw, IGC_SW_FW_SYNC);
swfw_sync &= ~mask;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.385297545 +0800
+++ 0046-net-igc-base-fix-infinite-loop.patch 2025-02-18 19:39:00.628244048 +0800
@@ -1 +1 @@
-From 532e495e4a20cf09e1f42d01bcbe782f7e2bb03f Mon Sep 17 00:00:00 2001
+From 5509313e7a3a1f7649f9ea6e4b0f03023c221e02 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 532e495e4a20cf09e1f42d01bcbe782f7e2bb03f ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/igc/base/igc_i225.c | 11 +++++++++--
+ drivers/net/igc/base/igc_i225.c | 11 +++++++++--
@@ -19 +21 @@
-diff --git a/drivers/net/intel/igc/base/igc_i225.c b/drivers/net/intel/igc/base/igc_i225.c
+diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/igc/base/igc_i225.c
-+++ b/drivers/net/intel/igc/base/igc_i225.c
+--- a/drivers/net/igc/base/igc_i225.c
++++ b/drivers/net/igc/base/igc_i225.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix bitwise operation type' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (45 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix infinite loop' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: increase PHY power up delay' " Xueming Li
` (40 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Przemyslaw Ciesielski
Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=db6aeefc21daa8e53e2e35defbf11db8347b8081
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From db6aeefc21daa8e53e2e35defbf11db8347b8081 Mon Sep 17 00:00:00 2001
From: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Date: Thu, 6 Feb 2025 16:08:26 +0000
Subject: [PATCH] net/igc/base: fix bitwise operation type
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit bf51125b75b18a3a43439edb2c6e1f0b14793d51 ]
Static analysis has found type mismatch between mask and register value.
Fix the bitwise operation type to avoid potential issues.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_i225.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
index 8f01f8d918..1277f59885 100644
--- a/drivers/net/igc/base/igc_i225.c
+++ b/drivers/net/igc/base/igc_i225.c
@@ -344,7 +344,7 @@ void igc_release_swfw_sync_i225(struct igc_hw *hw, u16 mask)
}
swfw_sync = IGC_READ_REG(hw, IGC_SW_FW_SYNC);
- swfw_sync &= ~mask;
+ swfw_sync &= ~(u32)mask;
IGC_WRITE_REG(hw, IGC_SW_FW_SYNC, swfw_sync);
igc_put_hw_semaphore_generic(hw);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.417389739 +0800
+++ 0047-net-igc-base-fix-bitwise-operation-type.patch 2025-02-18 19:39:00.628244048 +0800
@@ -1 +1 @@
-From bf51125b75b18a3a43439edb2c6e1f0b14793d51 Mon Sep 17 00:00:00 2001
+From db6aeefc21daa8e53e2e35defbf11db8347b8081 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit bf51125b75b18a3a43439edb2c6e1f0b14793d51 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/igc/base/igc_i225.c | 2 +-
+ drivers/net/igc/base/igc_i225.c | 2 +-
@@ -19 +21 @@
-diff --git a/drivers/net/intel/igc/base/igc_i225.c b/drivers/net/intel/igc/base/igc_i225.c
+diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/igc/base/igc_i225.c
-+++ b/drivers/net/intel/igc/base/igc_i225.c
+--- a/drivers/net/igc/base/igc_i225.c
++++ b/drivers/net/igc/base/igc_i225.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: increase PHY power up delay' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (46 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix bitwise operation type' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: reset loop variable' " Xueming Li
` (39 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Sasha Neftin; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=57259a101251c4a56d155628f77f5c357dbce621
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 57259a101251c4a56d155628f77f5c357dbce621 Mon Sep 17 00:00:00 2001
From: Sasha Neftin <sasha.neftin@intel.com>
Date: Thu, 6 Feb 2025 16:08:27 +0000
Subject: [PATCH] net/igc/base: increase PHY power up delay
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit a8a4acb46fa6bbe0a669b4eca0f73f112a7646ac ]
PHY specification for i225 requires 300 microsecond delay after power up
sequence, so increase the delay after power up to 300 microseconds.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_phy.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/igc/base/igc_phy.c b/drivers/net/igc/base/igc_phy.c
index ddc2b6ecc1..706f037f0e 100644
--- a/drivers/net/igc/base/igc_phy.c
+++ b/drivers/net/igc/base/igc_phy.c
@@ -3523,6 +3523,7 @@ void igc_power_up_phy_copper(struct igc_hw *hw)
hw->phy.ops.read_reg(hw, PHY_CONTROL, &mii_reg);
mii_reg &= ~MII_CR_POWER_DOWN;
hw->phy.ops.write_reg(hw, PHY_CONTROL, mii_reg);
+ usec_delay(300);
}
/**
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.447288334 +0800
+++ 0048-net-igc-base-increase-PHY-power-up-delay.patch 2025-02-18 19:39:00.628244048 +0800
@@ -1 +1 @@
-From a8a4acb46fa6bbe0a669b4eca0f73f112a7646ac Mon Sep 17 00:00:00 2001
+From 57259a101251c4a56d155628f77f5c357dbce621 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit a8a4acb46fa6bbe0a669b4eca0f73f112a7646ac ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/igc/base/igc_phy.c | 1 +
+ drivers/net/igc/base/igc_phy.c | 1 +
@@ -19 +21 @@
-diff --git a/drivers/net/intel/igc/base/igc_phy.c b/drivers/net/intel/igc/base/igc_phy.c
+diff --git a/drivers/net/igc/base/igc_phy.c b/drivers/net/igc/base/igc_phy.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/igc/base/igc_phy.c
-+++ b/drivers/net/intel/igc/base/igc_phy.c
+--- a/drivers/net/igc/base/igc_phy.c
++++ b/drivers/net/igc/base/igc_phy.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: reset loop variable' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (47 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: increase PHY power up delay' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix LTR for i225' " Xueming Li
` (38 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Sasha Neftin; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=d50c5a9ace9d836d20e57b1ed41c87a54bbdeb01
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From d50c5a9ace9d836d20e57b1ed41c87a54bbdeb01 Mon Sep 17 00:00:00 2001
From: Sasha Neftin <sasha.neftin@intel.com>
Date: Thu, 6 Feb 2025 16:08:28 +0000
Subject: [PATCH] net/igc/base: reset loop variable
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 60dca8e0f6b2d8526dc9dc8b54e59b5d68964e8e ]
When writing to Shadow RAM, we set rev_val on success, but since the
value is already set to success initially, it is possible for none of
the writes to be successful, yet ret_val will still be set to success.
Fix it by resetting the ret_val to failure before every loop iteration.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_i225.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
index 1277f59885..003c060215 100644
--- a/drivers/net/igc/base/igc_i225.c
+++ b/drivers/net/igc/base/igc_i225.c
@@ -565,6 +565,7 @@ static s32 __igc_write_nvm_srwr(struct igc_hw *hw, u16 offset, u16 words,
}
for (i = 0; i < words; i++) {
+ ret_val = -IGC_ERR_NVM;
eewr = ((offset + i) << IGC_NVM_RW_ADDR_SHIFT) |
(data[i] << IGC_NVM_RW_REG_DATA) |
IGC_NVM_RW_REG_START;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.481714328 +0800
+++ 0049-net-igc-base-reset-loop-variable.patch 2025-02-18 19:39:00.628244048 +0800
@@ -1 +1 @@
-From 60dca8e0f6b2d8526dc9dc8b54e59b5d68964e8e Mon Sep 17 00:00:00 2001
+From d50c5a9ace9d836d20e57b1ed41c87a54bbdeb01 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 60dca8e0f6b2d8526dc9dc8b54e59b5d68964e8e ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -18 +20 @@
- drivers/net/intel/igc/base/igc_i225.c | 1 +
+ drivers/net/igc/base/igc_i225.c | 1 +
@@ -21 +23 @@
-diff --git a/drivers/net/intel/igc/base/igc_i225.c b/drivers/net/intel/igc/base/igc_i225.c
+diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
@@ -23,2 +25,2 @@
---- a/drivers/net/intel/igc/base/igc_i225.c
-+++ b/drivers/net/intel/igc/base/igc_i225.c
+--- a/drivers/net/igc/base/igc_i225.c
++++ b/drivers/net/igc/base/igc_i225.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix LTR for i225' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (48 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: reset loop variable' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix typo in LTR calculation' " Xueming Li
` (37 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Sasha Neftin; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c6cf6d3f9760c8788b2fb76f4eff1f42b41aace7
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From c6cf6d3f9760c8788b2fb76f4eff1f42b41aace7 Mon Sep 17 00:00:00 2001
From: Sasha Neftin <sasha.neftin@intel.com>
Date: Thu, 6 Feb 2025 16:08:29 +0000
Subject: [PATCH] net/igc/base: fix LTR for i225
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 6a304bc65269cfd86193663e9b94c73299b54d00 ]
i225 specification recommends minus 1 microsecond from a value
calculated for a LTR. Fix the calculation to match spec.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_i225.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
index 003c060215..e701d00f80 100644
--- a/drivers/net/igc/base/igc_i225.c
+++ b/drivers/net/igc/base/igc_i225.c
@@ -1071,7 +1071,9 @@ static s32 igc_set_ltr_i225(struct igc_hw *hw, bool link)
scale_max = (ltr_max / 1024) < 1024 ? IGC_LTRMAXV_SCALE_1024 :
IGC_LTRMAXV_SCALE_32768;
ltr_min /= scale_min == IGC_LTRMINV_SCALE_1024 ? 1024 : 32768;
+ ltr_min -= 1;
ltr_max /= scale_max == IGC_LTRMAXV_SCALE_1024 ? 1024 : 32768;
+ ltr_max -= 1;
/* Only write the LTR thresholds if they differ from before. */
ltrv = IGC_READ_REG(hw, IGC_LTRMINV);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.512308323 +0800
+++ 0050-net-igc-base-fix-LTR-for-i225.patch 2025-02-18 19:39:00.638244046 +0800
@@ -1 +1 @@
-From 6a304bc65269cfd86193663e9b94c73299b54d00 Mon Sep 17 00:00:00 2001
+From c6cf6d3f9760c8788b2fb76f4eff1f42b41aace7 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 6a304bc65269cfd86193663e9b94c73299b54d00 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/igc/base/igc_i225.c | 2 ++
+ drivers/net/igc/base/igc_i225.c | 2 ++
@@ -19 +21 @@
-diff --git a/drivers/net/intel/igc/base/igc_i225.c b/drivers/net/intel/igc/base/igc_i225.c
+diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/igc/base/igc_i225.c
-+++ b/drivers/net/intel/igc/base/igc_i225.c
+--- a/drivers/net/igc/base/igc_i225.c
++++ b/drivers/net/igc/base/igc_i225.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix typo in LTR calculation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (49 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix LTR for i225' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix unused value' " Xueming Li
` (36 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Dima Ruinskiy; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=705c1170bc39b4fa436aefd91fd705179f549c94
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 705c1170bc39b4fa436aefd91fd705179f549c94 Mon Sep 17 00:00:00 2001
From: Dima Ruinskiy <dima.ruinskiy@intel.com>
Date: Thu, 6 Feb 2025 16:08:30 +0000
Subject: [PATCH] net/igc/base: fix typo in LTR calculation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit ce11274c5c7188322cc141cdce8cd0680e76f79f ]
The LTR maximum value was incorrectly written using the scale from the
LTR minimum value. This would cause incorrect values to be sent, in
cases where the initial calculation leads to different min/max scales.
Fix the typo to correctly calculate the LTR maximum value.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_i225.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
index e701d00f80..c7c2ec8ffe 100644
--- a/drivers/net/igc/base/igc_i225.c
+++ b/drivers/net/igc/base/igc_i225.c
@@ -1086,7 +1086,7 @@ static s32 igc_set_ltr_i225(struct igc_hw *hw, bool link)
ltrv = IGC_READ_REG(hw, IGC_LTRMAXV);
if (ltr_max != (ltrv & IGC_LTRMAXV_LTRV_MASK)) {
ltrv = IGC_LTRMAXV_LSNP_REQ | ltr_max |
- (scale_min << IGC_LTRMAXV_SCALE_SHIFT);
+ (scale_max << IGC_LTRMAXV_SCALE_SHIFT);
IGC_WRITE_REG(hw, IGC_LTRMAXV, ltrv);
}
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.543004918 +0800
+++ 0051-net-igc-base-fix-typo-in-LTR-calculation.patch 2025-02-18 19:39:00.638244046 +0800
@@ -1 +1 @@
-From ce11274c5c7188322cc141cdce8cd0680e76f79f Mon Sep 17 00:00:00 2001
+From 705c1170bc39b4fa436aefd91fd705179f549c94 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit ce11274c5c7188322cc141cdce8cd0680e76f79f ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -18 +20 @@
- drivers/net/intel/igc/base/igc_i225.c | 2 +-
+ drivers/net/igc/base/igc_i225.c | 2 +-
@@ -21 +23 @@
-diff --git a/drivers/net/intel/igc/base/igc_i225.c b/drivers/net/intel/igc/base/igc_i225.c
+diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
@@ -23,2 +25,2 @@
---- a/drivers/net/intel/igc/base/igc_i225.c
-+++ b/drivers/net/intel/igc/base/igc_i225.c
+--- a/drivers/net/igc/base/igc_i225.c
++++ b/drivers/net/igc/base/igc_i225.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix unused value' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (50 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix typo in LTR calculation' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix semaphore timeout " Xueming Li
` (35 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Dima Ruinskiy; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=ef2e66caed01481bea22fcb5f75a2dc2fa4ef12c
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From ef2e66caed01481bea22fcb5f75a2dc2fa4ef12c Mon Sep 17 00:00:00 2001
From: Dima Ruinskiy <dima.ruinskiy@intel.com>
Date: Thu, 6 Feb 2025 16:08:31 +0000
Subject: [PATCH] net/igc/base: fix unused value
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit c506cc8305b4ca17bae903a54daaeaf5b7005038 ]
Static analysis has reported that when there is no get link status
callback function, the value set in the if condition is not used and
gets overwritten in the "out" section of the code. Fix by not setting
the variable.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_i225.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
index c7c2ec8ffe..23c68a3948 100644
--- a/drivers/net/igc/base/igc_i225.c
+++ b/drivers/net/igc/base/igc_i225.c
@@ -1114,10 +1114,8 @@ s32 igc_check_for_link_i225(struct igc_hw *hw)
* changed. The get_link_status flag is set upon receiving
* a Link Status Change or Rx Sequence Error interrupt.
*/
- if (!mac->get_link_status) {
- ret_val = IGC_SUCCESS;
+ if (!mac->get_link_status)
goto out;
- }
/* First we want to see if the MII Status Register reports
* link. If so, then we want to get the current speed/duplex
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.574924312 +0800
+++ 0052-net-igc-base-fix-unused-value.patch 2025-02-18 19:39:00.638244046 +0800
@@ -1 +1 @@
-From c506cc8305b4ca17bae903a54daaeaf5b7005038 Mon Sep 17 00:00:00 2001
+From ef2e66caed01481bea22fcb5f75a2dc2fa4ef12c Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit c506cc8305b4ca17bae903a54daaeaf5b7005038 ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -18 +20 @@
- drivers/net/intel/igc/base/igc_i225.c | 4 +---
+ drivers/net/igc/base/igc_i225.c | 4 +---
@@ -21 +23 @@
-diff --git a/drivers/net/intel/igc/base/igc_i225.c b/drivers/net/intel/igc/base/igc_i225.c
+diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
@@ -23,2 +25,2 @@
---- a/drivers/net/intel/igc/base/igc_i225.c
-+++ b/drivers/net/intel/igc/base/igc_i225.c
+--- a/drivers/net/igc/base/igc_i225.c
++++ b/drivers/net/igc/base/igc_i225.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix semaphore timeout value' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (51 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix unused value' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix iterator type' " Xueming Li
` (34 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Pawel Malinowski; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=1bede44e32af68399255b39b605f8af624d33f29
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 1bede44e32af68399255b39b605f8af624d33f29 Mon Sep 17 00:00:00 2001
From: Pawel Malinowski <pawel.malinowski@intel.com>
Date: Thu, 6 Feb 2025 16:08:32 +0000
Subject: [PATCH] net/igc/base: fix semaphore timeout value
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 7caabb9834bc9596190c03279eae8980b1c24800 ]
According to datasheet, software ownership of SWSM.SWESMBI bit should
not exceed 100ms. Current implementation caused incorrect timeout
counter values, where each iteration equals 50us delay. Because of that,
driver was allowed to wait for semaphore even for 1.5s. This might
trigger DPC timeout.
This implementation hardcodes value to 2000, which multiplied by 50us,
gives 100ms of possible wait time.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Pawel Malinowski <pawel.malinowski@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_defines.h | 1 +
drivers/net/igc/base/igc_i225.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/igc/base/igc_defines.h b/drivers/net/igc/base/igc_defines.h
index 280570b157..3cb2f430c5 100644
--- a/drivers/net/igc/base/igc_defines.h
+++ b/drivers/net/igc/base/igc_defines.h
@@ -525,6 +525,7 @@
/* SW Semaphore Register */
#define IGC_SWSM_SMBI 0x00000001 /* Driver Semaphore bit */
#define IGC_SWSM_SWESMBI 0x00000002 /* FW Semaphore bit */
+#define IGC_SWSM_TIMEOUT 2000 /* Driver Semaphore max timeout counter */
#define IGC_SWSM_DRV_LOAD 0x00000008 /* Driver Loaded Bit */
#define IGC_SWSM2_LOCK 0x00000002 /* Secondary driver semaphore bit */
diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
index 23c68a3948..7352ba240a 100644
--- a/drivers/net/igc/base/igc_i225.c
+++ b/drivers/net/igc/base/igc_i225.c
@@ -388,7 +388,7 @@ s32 igc_setup_copper_link_i225(struct igc_hw *hw)
static s32 igc_get_hw_semaphore_i225(struct igc_hw *hw)
{
u32 swsm;
- s32 timeout = hw->nvm.word_size + 1;
+ s32 timeout = IGC_SWSM_TIMEOUT;
s32 i = 0;
DEBUGFUNC("igc_get_hw_semaphore_i225");
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.606733607 +0800
+++ 0053-net-igc-base-fix-semaphore-timeout-value.patch 2025-02-18 19:39:00.638244046 +0800
@@ -1 +1 @@
-From 7caabb9834bc9596190c03279eae8980b1c24800 Mon Sep 17 00:00:00 2001
+From 1bede44e32af68399255b39b605f8af624d33f29 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 7caabb9834bc9596190c03279eae8980b1c24800 ]
@@ -16 +18,0 @@
-Cc: stable@dpdk.org
@@ -22,2 +24,2 @@
- drivers/net/intel/igc/base/igc_defines.h | 1 +
- drivers/net/intel/igc/base/igc_i225.c | 2 +-
+ drivers/net/igc/base/igc_defines.h | 1 +
+ drivers/net/igc/base/igc_i225.c | 2 +-
@@ -26 +28 @@
-diff --git a/drivers/net/intel/igc/base/igc_defines.h b/drivers/net/intel/igc/base/igc_defines.h
+diff --git a/drivers/net/igc/base/igc_defines.h b/drivers/net/igc/base/igc_defines.h
@@ -28,2 +30,2 @@
---- a/drivers/net/intel/igc/base/igc_defines.h
-+++ b/drivers/net/intel/igc/base/igc_defines.h
+--- a/drivers/net/igc/base/igc_defines.h
++++ b/drivers/net/igc/base/igc_defines.h
@@ -38 +40 @@
-diff --git a/drivers/net/intel/igc/base/igc_i225.c b/drivers/net/intel/igc/base/igc_i225.c
+diff --git a/drivers/net/igc/base/igc_i225.c b/drivers/net/igc/base/igc_i225.c
@@ -40,2 +42,2 @@
---- a/drivers/net/intel/igc/base/igc_i225.c
-+++ b/drivers/net/intel/igc/base/igc_i225.c
+--- a/drivers/net/igc/base/igc_i225.c
++++ b/drivers/net/igc/base/igc_i225.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix iterator type' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (52 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix semaphore timeout " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix MAC address hash bit shift' " Xueming Li
` (33 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Amir Avivi; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=6268d4391b5c00a1b43c5f5ab7e106bf0b80ce9e
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 6268d4391b5c00a1b43c5f5ab7e106bf0b80ce9e Mon Sep 17 00:00:00 2001
From: Amir Avivi <amir.avivi@intel.com>
Date: Thu, 6 Feb 2025 16:08:33 +0000
Subject: [PATCH] net/igc/base: fix iterator type
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit c7da9dab82190564d68f0d928ba3e381dcc74d9f ]
Fix static analysis warning about comparison between types of
incompatible width, which might lead to an infinite loop due to
overflow.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Amir Avivi <amir.avivi@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
.mailmap | 1 +
drivers/net/igc/base/igc_phy.c | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/.mailmap b/.mailmap
index acf910ab3b..b479ac34a0 100644
--- a/.mailmap
+++ b/.mailmap
@@ -80,6 +80,7 @@ Amaranath Somalapuram <asomalap@amd.com>
Amine Kherbouche <amine.kherbouche@6wind.com>
Amin Tootoonchian <amint@icsi.berkeley.edu>
Ami Sabo <amis@radware.com>
+Amir Avivi <amir.avivi@intel.com>
Amit Bernstein <amitbern@amazon.com>
Amit Gupta <agupta3@marvell.com>
Amit Prakash Shukla <amitprakashs@marvell.com>
diff --git a/drivers/net/igc/base/igc_phy.c b/drivers/net/igc/base/igc_phy.c
index 706f037f0e..dd56b994af 100644
--- a/drivers/net/igc/base/igc_phy.c
+++ b/drivers/net/igc/base/igc_phy.c
@@ -2366,7 +2366,8 @@ s32 igc_phy_has_link_generic(struct igc_hw *hw, u32 iterations,
u32 usec_interval, bool *success)
{
s32 ret_val = IGC_SUCCESS;
- u16 i, phy_status;
+ u16 phy_status;
+ u32 i;
DEBUGFUNC("igc_phy_has_link_generic");
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.639875401 +0800
+++ 0054-net-igc-base-fix-iterator-type.patch 2025-02-18 19:39:00.648244044 +0800
@@ -1 +1 @@
-From c7da9dab82190564d68f0d928ba3e381dcc74d9f Mon Sep 17 00:00:00 2001
+From 6268d4391b5c00a1b43c5f5ab7e106bf0b80ce9e Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit c7da9dab82190564d68f0d928ba3e381dcc74d9f ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -17,2 +19,2 @@
- .mailmap | 1 +
- drivers/net/intel/igc/base/igc_phy.c | 3 ++-
+ .mailmap | 1 +
+ drivers/net/igc/base/igc_phy.c | 3 ++-
@@ -22 +24 @@
-index 9ea6bd1df3..ab03985acd 100644
+index acf910ab3b..b479ac34a0 100644
@@ -25 +27 @@
-@@ -84,6 +84,7 @@ Amaranath Somalapuram <asomalap@amd.com>
+@@ -80,6 +80,7 @@ Amaranath Somalapuram <asomalap@amd.com>
@@ -33 +35 @@
-diff --git a/drivers/net/intel/igc/base/igc_phy.c b/drivers/net/intel/igc/base/igc_phy.c
+diff --git a/drivers/net/igc/base/igc_phy.c b/drivers/net/igc/base/igc_phy.c
@@ -35,2 +37,2 @@
---- a/drivers/net/intel/igc/base/igc_phy.c
-+++ b/drivers/net/intel/igc/base/igc_phy.c
+--- a/drivers/net/igc/base/igc_phy.c
++++ b/drivers/net/igc/base/igc_phy.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix MAC address hash bit shift' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (53 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix iterator type' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix data type in MAC hash' " Xueming Li
` (32 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Aleksandr Loktionov
Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=a9583ad550e01cef45cf1e0b18c36665f8a964fe
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From a9583ad550e01cef45cf1e0b18c36665f8a964fe Mon Sep 17 00:00:00 2001
From: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Date: Thu, 6 Feb 2025 16:08:34 +0000
Subject: [PATCH] net/igc/base: fix MAC address hash bit shift
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit bccccacfb6f6f2e84a24c6733c7e3d4af05f73b5 ]
In e1000_hash_mc_addr_generic() the expression:
"mc_addr[4] >> 8 - bit_shift", right shifting "mc_addr[4]"
shift by more than 7 bits always yields zero, so hash becomes not so
different. Add initialization with bit_shift = 1, and add a loop
condition to ensure bit_shift will be always in [1..8] range.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_mac.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/igc/base/igc_mac.c b/drivers/net/igc/base/igc_mac.c
index 3cd6506e5e..c69f8ac73b 100644
--- a/drivers/net/igc/base/igc_mac.c
+++ b/drivers/net/igc/base/igc_mac.c
@@ -486,7 +486,7 @@ static int igc_rar_set_generic(struct igc_hw *hw, u8 *addr, u32 index)
u32 igc_hash_mc_addr_generic(struct igc_hw *hw, u8 *mc_addr)
{
u32 hash_value, hash_mask;
- u8 bit_shift = 0;
+ u8 bit_shift = 1;
DEBUGFUNC("igc_hash_mc_addr_generic");
@@ -496,7 +496,7 @@ u32 igc_hash_mc_addr_generic(struct igc_hw *hw, u8 *mc_addr)
/* For a mc_filter_type of 0, bit_shift is the number of left-shifts
* where 0xFF would still fall within the hash mask.
*/
- while (hash_mask >> bit_shift != 0xFF)
+ while (hash_mask >> bit_shift != 0xFF && bit_shift < 4)
bit_shift++;
/* The portion of the address that is used for the hash table
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.673692295 +0800
+++ 0055-net-igc-base-fix-MAC-address-hash-bit-shift.patch 2025-02-18 19:39:00.648244044 +0800
@@ -1 +1 @@
-From bccccacfb6f6f2e84a24c6733c7e3d4af05f73b5 Mon Sep 17 00:00:00 2001
+From a9583ad550e01cef45cf1e0b18c36665f8a964fe Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit bccccacfb6f6f2e84a24c6733c7e3d4af05f73b5 ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -21 +23 @@
- drivers/net/intel/igc/base/igc_mac.c | 4 ++--
+ drivers/net/igc/base/igc_mac.c | 4 ++--
@@ -24 +26 @@
-diff --git a/drivers/net/intel/igc/base/igc_mac.c b/drivers/net/intel/igc/base/igc_mac.c
+diff --git a/drivers/net/igc/base/igc_mac.c b/drivers/net/igc/base/igc_mac.c
@@ -26,2 +28,2 @@
---- a/drivers/net/intel/igc/base/igc_mac.c
-+++ b/drivers/net/intel/igc/base/igc_mac.c
+--- a/drivers/net/igc/base/igc_mac.c
++++ b/drivers/net/igc/base/igc_mac.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix data type in MAC hash' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (54 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix MAC address hash bit shift' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/igc/base: fix NVM data type in bit shift' " Xueming Li
` (31 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Barbara Skobiej; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=e5a7115f56331726dbfdc910e5b333ac8ff12c5a
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From e5a7115f56331726dbfdc910e5b333ac8ff12c5a Mon Sep 17 00:00:00 2001
From: Barbara Skobiej <barbara.skobiej@intel.com>
Date: Thu, 6 Feb 2025 16:08:35 +0000
Subject: [PATCH] net/igc/base: fix data type in MAC hash
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit cad5c51ec3a0e965d6d4bb98166890499597f23a ]
One of the bit shifts in MAC hash calculation triggers a static analysis
warning about a potential overflow. Fix the data type to avoid this.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Barbara Skobiej <barbara.skobiej@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_mac.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/net/igc/base/igc_mac.c b/drivers/net/igc/base/igc_mac.c
index c69f8ac73b..cfb74a6443 100644
--- a/drivers/net/igc/base/igc_mac.c
+++ b/drivers/net/igc/base/igc_mac.c
@@ -539,8 +539,10 @@ u32 igc_hash_mc_addr_generic(struct igc_hw *hw, u8 *mc_addr)
break;
}
- hash_value = hash_mask & (((mc_addr[4] >> (8 - bit_shift)) |
- (((u16)mc_addr[5]) << bit_shift)));
+ hash_value = (u32)mc_addr[4];
+ hash_value = hash_value >> (8 - bit_shift);
+ hash_value |= (((u32)mc_addr[5]) << bit_shift);
+ hash_value &= hash_mask;
return hash_value;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.705312790 +0800
+++ 0056-net-igc-base-fix-data-type-in-MAC-hash.patch 2025-02-18 19:39:00.648244044 +0800
@@ -1 +1 @@
-From cad5c51ec3a0e965d6d4bb98166890499597f23a Mon Sep 17 00:00:00 2001
+From e5a7115f56331726dbfdc910e5b333ac8ff12c5a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit cad5c51ec3a0e965d6d4bb98166890499597f23a ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/igc/base/igc_mac.c | 6 ++++--
+ drivers/net/igc/base/igc_mac.c | 6 ++++--
@@ -19 +21 @@
-diff --git a/drivers/net/intel/igc/base/igc_mac.c b/drivers/net/intel/igc/base/igc_mac.c
+diff --git a/drivers/net/igc/base/igc_mac.c b/drivers/net/igc/base/igc_mac.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/igc/base/igc_mac.c
-+++ b/drivers/net/intel/igc/base/igc_mac.c
+--- a/drivers/net/igc/base/igc_mac.c
++++ b/drivers/net/igc/base/igc_mac.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/igc/base: fix NVM data type in bit shift' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (55 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix data type in MAC hash' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/e1000/base: fix semaphore timeout value' " Xueming Li
` (30 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Przemyslaw Ciesielski
Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=fed480fbadeab2f9284a22535016d365f9530994
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From fed480fbadeab2f9284a22535016d365f9530994 Mon Sep 17 00:00:00 2001
From: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Date: Thu, 6 Feb 2025 16:08:36 +0000
Subject: [PATCH] net/igc/base: fix NVM data type in bit shift
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit d6ad4cdad361558bfb2c04112bd6650debbc9c7f ]
There is a static analysis warning due to wrong data types being used
for NVM read data shifts. Fix it via explicit type cast.
Fixes: 8cb7c57d9b3c ("net/igc: support device initialization")
Signed-off-by: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/igc/base/igc_nvm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/igc/base/igc_nvm.c b/drivers/net/igc/base/igc_nvm.c
index a7c901ab56..d37a3ffb0e 100644
--- a/drivers/net/igc/base/igc_nvm.c
+++ b/drivers/net/igc/base/igc_nvm.c
@@ -926,14 +926,14 @@ s32 igc_read_pba_num_generic(struct igc_hw *hw, u32 *pba_num)
DEBUGOUT("NVM Not Supported\n");
return -IGC_NOT_IMPLEMENTED;
}
- *pba_num = (u32)(nvm_data << 16);
+ *pba_num = ((u32)nvm_data << 16);
ret_val = hw->nvm.ops.read(hw, NVM_PBA_OFFSET_1, 1, &nvm_data);
if (ret_val) {
DEBUGOUT("NVM Read Error\n");
return ret_val;
}
- *pba_num |= nvm_data;
+ *pba_num |= (u32)nvm_data;
return IGC_SUCCESS;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.740686284 +0800
+++ 0057-net-igc-base-fix-NVM-data-type-in-bit-shift.patch 2025-02-18 19:39:00.648244044 +0800
@@ -1 +1 @@
-From d6ad4cdad361558bfb2c04112bd6650debbc9c7f Mon Sep 17 00:00:00 2001
+From fed480fbadeab2f9284a22535016d365f9530994 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit d6ad4cdad361558bfb2c04112bd6650debbc9c7f ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/igc/base/igc_nvm.c | 4 ++--
+ drivers/net/igc/base/igc_nvm.c | 4 ++--
@@ -19 +21 @@
-diff --git a/drivers/net/intel/igc/base/igc_nvm.c b/drivers/net/intel/igc/base/igc_nvm.c
+diff --git a/drivers/net/igc/base/igc_nvm.c b/drivers/net/igc/base/igc_nvm.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/igc/base/igc_nvm.c
-+++ b/drivers/net/intel/igc/base/igc_nvm.c
+--- a/drivers/net/igc/base/igc_nvm.c
++++ b/drivers/net/igc/base/igc_nvm.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix semaphore timeout value' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (56 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/igc/base: fix NVM data type in bit shift' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/e1000/base: correct mPHY access logic' " Xueming Li
` (29 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Pawel Malinowski; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=7379e53203fa403e448a13b26253767eba721731
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 7379e53203fa403e448a13b26253767eba721731 Mon Sep 17 00:00:00 2001
From: Pawel Malinowski <pawel.malinowski@intel.com>
Date: Thu, 6 Feb 2025 16:08:37 +0000
Subject: [PATCH] net/e1000/base: fix semaphore timeout value
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit c8bcaf0f2a02995b447c121e860fd550b9c55114 ]
According to datasheet, software ownership of SWSM.SWESMBI bit should
not exceed 100ms. Current implementation caused incorrect timeout
counter values, where each iteration equals 50us delay. Because of that
driver was allowed to wait for semaphore even for 1.5s. This might
trigger DPC timeout.
This implementation hardcodes value to 2000, which multiplied by 50us,
gives 100ms of possible wait time.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Pawel Malinowski <pawel.malinowski@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_defines.h | 1 +
drivers/net/e1000/base/e1000_mac.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/e1000/base/e1000_defines.h b/drivers/net/e1000/base/e1000_defines.h
index 3fbb6c8ea4..97cc2797b2 100644
--- a/drivers/net/e1000/base/e1000_defines.h
+++ b/drivers/net/e1000/base/e1000_defines.h
@@ -504,6 +504,7 @@
/* SW Semaphore Register */
#define E1000_SWSM_SMBI 0x00000001 /* Driver Semaphore bit */
#define E1000_SWSM_SWESMBI 0x00000002 /* FW Semaphore bit */
+#define E1000_SWSM_TIMEOUT 2000 /* Driver Semaphore max timeout counter */
#define E1000_SWSM_DRV_LOAD 0x00000008 /* Driver Loaded Bit */
#define E1000_SWSM2_LOCK 0x00000002 /* Secondary driver semaphore bit */
diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
index d3b3a6bac9..cf0a9f21e1 100644
--- a/drivers/net/e1000/base/e1000_mac.c
+++ b/drivers/net/e1000/base/e1000_mac.c
@@ -1688,7 +1688,7 @@ s32 e1000_get_speed_and_duplex_fiber_serdes_generic(struct e1000_hw E1000_UNUSED
s32 e1000_get_hw_semaphore_generic(struct e1000_hw *hw)
{
u32 swsm;
- s32 timeout = hw->nvm.word_size + 1;
+ s32 timeout = E1000_SWSM_TIMEOUT;
s32 i = 0;
DEBUGFUNC("e1000_get_hw_semaphore_generic");
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.772001278 +0800
+++ 0058-net-e1000-base-fix-semaphore-timeout-value.patch 2025-02-18 19:39:00.658244042 +0800
@@ -1 +1 @@
-From c8bcaf0f2a02995b447c121e860fd550b9c55114 Mon Sep 17 00:00:00 2001
+From 7379e53203fa403e448a13b26253767eba721731 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit c8bcaf0f2a02995b447c121e860fd550b9c55114 ]
@@ -16 +18,0 @@
-Cc: stable@dpdk.org
@@ -22,2 +24,2 @@
- drivers/net/intel/e1000/base/e1000_defines.h | 1 +
- drivers/net/intel/e1000/base/e1000_mac.c | 2 +-
+ drivers/net/e1000/base/e1000_defines.h | 1 +
+ drivers/net/e1000/base/e1000_mac.c | 2 +-
@@ -26 +28 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_defines.h b/drivers/net/intel/e1000/base/e1000_defines.h
+diff --git a/drivers/net/e1000/base/e1000_defines.h b/drivers/net/e1000/base/e1000_defines.h
@@ -28,2 +30,2 @@
---- a/drivers/net/intel/e1000/base/e1000_defines.h
-+++ b/drivers/net/intel/e1000/base/e1000_defines.h
+--- a/drivers/net/e1000/base/e1000_defines.h
++++ b/drivers/net/e1000/base/e1000_defines.h
@@ -38 +40 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_mac.c b/drivers/net/intel/e1000/base/e1000_mac.c
+diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
@@ -40,2 +42,2 @@
---- a/drivers/net/intel/e1000/base/e1000_mac.c
-+++ b/drivers/net/intel/e1000/base/e1000_mac.c
+--- a/drivers/net/e1000/base/e1000_mac.c
++++ b/drivers/net/e1000/base/e1000_mac.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: correct mPHY access logic' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (57 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/e1000/base: fix semaphore timeout value' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/e1000/base: fix iterator type' " Xueming Li
` (28 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Anatoly Burakov; +Cc: xuemingl, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=5ea60d834c1800358f8f050b34321c3df7388693
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 5ea60d834c1800358f8f050b34321c3df7388693 Mon Sep 17 00:00:00 2001
From: Anatoly Burakov <anatoly.burakov@intel.com>
Date: Thu, 6 Feb 2025 16:08:38 +0000
Subject: [PATCH] net/e1000/base: correct mPHY access logic
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 62adddef81d4ddb9789e9f0e5a0899b399bd5d8d ]
The original code had incorrect indentation, and the fix was applied to
follow the indentation, i.e. adding brackets making the indentation
valid. However, the actual issue was incorrect indentation and not
missing braces, so the fix was incorrect.
This fix restores the original logic and corrects indentation.
Fixes: d5e39d1ca460 ("net/e1000/base: fix build with gcc 6")
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_phy.c | 22 ++++++++++------------
1 file changed, 10 insertions(+), 12 deletions(-)
diff --git a/drivers/net/e1000/base/e1000_phy.c b/drivers/net/e1000/base/e1000_phy.c
index 62d0be5080..208fb3f81b 100644
--- a/drivers/net/e1000/base/e1000_phy.c
+++ b/drivers/net/e1000/base/e1000_phy.c
@@ -4134,13 +4134,12 @@ s32 e1000_read_phy_reg_mphy(struct e1000_hw *hw, u32 address, u32 *data)
*data = E1000_READ_REG(hw, E1000_MPHY_DATA);
/* Disable access to mPHY if it was originally disabled */
- if (locked) {
+ if (locked)
ready = e1000_is_mphy_ready(hw);
- if (!ready)
- return -E1000_ERR_PHY;
- E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL,
- E1000_MPHY_DIS_ACCESS);
- }
+ if (!ready)
+ return -E1000_ERR_PHY;
+ E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL,
+ E1000_MPHY_DIS_ACCESS);
return E1000_SUCCESS;
}
@@ -4200,13 +4199,12 @@ s32 e1000_write_phy_reg_mphy(struct e1000_hw *hw, u32 address, u32 data,
E1000_WRITE_REG(hw, E1000_MPHY_DATA, data);
/* Disable access to mPHY if it was originally disabled */
- if (locked) {
+ if (locked)
ready = e1000_is_mphy_ready(hw);
- if (!ready)
- return -E1000_ERR_PHY;
- E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL,
- E1000_MPHY_DIS_ACCESS);
- }
+ if (!ready)
+ return -E1000_ERR_PHY;
+ E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL,
+ E1000_MPHY_DIS_ACCESS);
return E1000_SUCCESS;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.805349973 +0800
+++ 0059-net-e1000-base-correct-mPHY-access-logic.patch 2025-02-18 19:39:00.658244042 +0800
@@ -1 +1 @@
-From 62adddef81d4ddb9789e9f0e5a0899b399bd5d8d Mon Sep 17 00:00:00 2001
+From 5ea60d834c1800358f8f050b34321c3df7388693 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 62adddef81d4ddb9789e9f0e5a0899b399bd5d8d ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
- drivers/net/intel/e1000/base/e1000_phy.c | 22 ++++++++++------------
+ drivers/net/e1000/base/e1000_phy.c | 22 ++++++++++------------
@@ -22 +24 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_phy.c b/drivers/net/intel/e1000/base/e1000_phy.c
+diff --git a/drivers/net/e1000/base/e1000_phy.c b/drivers/net/e1000/base/e1000_phy.c
@@ -24,2 +26,2 @@
---- a/drivers/net/intel/e1000/base/e1000_phy.c
-+++ b/drivers/net/intel/e1000/base/e1000_phy.c
+--- a/drivers/net/e1000/base/e1000_phy.c
++++ b/drivers/net/e1000/base/e1000_phy.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix iterator type' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (58 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/e1000/base: correct mPHY access logic' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/e1000/base: fix MAC address hash bit shift' " Xueming Li
` (27 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Amir Avivi; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=44d281ffbcc3d8dba59210851bb6d8a030facbb3
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 44d281ffbcc3d8dba59210851bb6d8a030facbb3 Mon Sep 17 00:00:00 2001
From: Amir Avivi <amir.avivi@intel.com>
Date: Thu, 6 Feb 2025 16:08:39 +0000
Subject: [PATCH] net/e1000/base: fix iterator type
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 3d3605399170d5871ba80448de236f7acbbe8f98 ]
Fix static analysis warning about comparison between types of
incompatible width, which might lead to an infinite loop due to
overflow.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Amir Avivi <amir.avivi@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_phy.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/e1000/base/e1000_phy.c b/drivers/net/e1000/base/e1000_phy.c
index 208fb3f81b..b4aba9e4e3 100644
--- a/drivers/net/e1000/base/e1000_phy.c
+++ b/drivers/net/e1000/base/e1000_phy.c
@@ -2333,7 +2333,8 @@ s32 e1000_phy_has_link_generic(struct e1000_hw *hw, u32 iterations,
u32 usec_interval, bool *success)
{
s32 ret_val = E1000_SUCCESS;
- u16 i, phy_status;
+ u16 phy_status;
+ u32 i;
DEBUGFUNC("e1000_phy_has_link_generic");
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.838044567 +0800
+++ 0060-net-e1000-base-fix-iterator-type.patch 2025-02-18 19:39:00.658244042 +0800
@@ -1 +1 @@
-From 3d3605399170d5871ba80448de236f7acbbe8f98 Mon Sep 17 00:00:00 2001
+From 44d281ffbcc3d8dba59210851bb6d8a030facbb3 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 3d3605399170d5871ba80448de236f7acbbe8f98 ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -17 +19 @@
- drivers/net/intel/e1000/base/e1000_phy.c | 3 ++-
+ drivers/net/e1000/base/e1000_phy.c | 3 ++-
@@ -20 +22 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_phy.c b/drivers/net/intel/e1000/base/e1000_phy.c
+diff --git a/drivers/net/e1000/base/e1000_phy.c b/drivers/net/e1000/base/e1000_phy.c
@@ -22,2 +24,2 @@
---- a/drivers/net/intel/e1000/base/e1000_phy.c
-+++ b/drivers/net/intel/e1000/base/e1000_phy.c
+--- a/drivers/net/e1000/base/e1000_phy.c
++++ b/drivers/net/e1000/base/e1000_phy.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix MAC address hash bit shift' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (59 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/e1000/base: fix iterator type' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/e1000/base: fix data type in MAC hash' " Xueming Li
` (26 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Aleksandr Loktionov
Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=5b1825dc24c291cd19f94bcb92c7947c5cc11e54
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 5b1825dc24c291cd19f94bcb92c7947c5cc11e54 Mon Sep 17 00:00:00 2001
From: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Date: Thu, 6 Feb 2025 16:08:40 +0000
Subject: [PATCH] net/e1000/base: fix MAC address hash bit shift
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 1749e662f68ba6571ed81cd264cffd1107abc307 ]
In e1000_hash_mc_addr_generic() the expression:
"mc_addr[4] >> 8 - bit_shift", right shifting "mc_addr[4]"
shift by more than 7 bits always yields zero, so hash becomes not so
different. Add initialization with bit_shift = 1, and add a loop
condition to ensure bit_shift will be always in [1..8] range.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_mac.c | 4 ++--
drivers/net/e1000/base/e1000_vf.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
index cf0a9f21e1..2b8482e114 100644
--- a/drivers/net/e1000/base/e1000_mac.c
+++ b/drivers/net/e1000/base/e1000_mac.c
@@ -488,7 +488,7 @@ int e1000_rar_set_generic(struct e1000_hw *hw, u8 *addr, u32 index)
u32 e1000_hash_mc_addr_generic(struct e1000_hw *hw, u8 *mc_addr)
{
u32 hash_value, hash_mask;
- u8 bit_shift = 0;
+ u8 bit_shift = 1;
DEBUGFUNC("e1000_hash_mc_addr_generic");
@@ -498,7 +498,7 @@ u32 e1000_hash_mc_addr_generic(struct e1000_hw *hw, u8 *mc_addr)
/* For a mc_filter_type of 0, bit_shift is the number of left-shifts
* where 0xFF would still fall within the hash mask.
*/
- while (hash_mask >> bit_shift != 0xFF)
+ while (hash_mask >> bit_shift != 0xFF && bit_shift < 4)
bit_shift++;
/* The portion of the address that is used for the hash table
diff --git a/drivers/net/e1000/base/e1000_vf.c b/drivers/net/e1000/base/e1000_vf.c
index 44ebe07ee4..3d0383fcbb 100644
--- a/drivers/net/e1000/base/e1000_vf.c
+++ b/drivers/net/e1000/base/e1000_vf.c
@@ -331,7 +331,7 @@ STATIC int e1000_rar_set_vf(struct e1000_hw *hw, u8 *addr,
STATIC u32 e1000_hash_mc_addr_vf(struct e1000_hw *hw, u8 *mc_addr)
{
u32 hash_value, hash_mask;
- u8 bit_shift = 0;
+ u8 bit_shift = 1;
DEBUGFUNC("e1000_hash_mc_addr_generic");
@@ -342,7 +342,7 @@ STATIC u32 e1000_hash_mc_addr_vf(struct e1000_hw *hw, u8 *mc_addr)
* The bit_shift is the number of left-shifts
* where 0xFF would still fall within the hash mask.
*/
- while (hash_mask >> bit_shift != 0xFF)
+ while (hash_mask >> bit_shift != 0xFF && bit_shift < 4)
bit_shift++;
hash_value = hash_mask & (((mc_addr[4] >> (8 - bit_shift)) |
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.870345661 +0800
+++ 0061-net-e1000-base-fix-MAC-address-hash-bit-shift.patch 2025-02-18 19:39:00.668244041 +0800
@@ -1 +1 @@
-From 1749e662f68ba6571ed81cd264cffd1107abc307 Mon Sep 17 00:00:00 2001
+From 5b1825dc24c291cd19f94bcb92c7947c5cc11e54 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 1749e662f68ba6571ed81cd264cffd1107abc307 ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -21,2 +23,2 @@
- drivers/net/intel/e1000/base/e1000_mac.c | 4 ++--
- drivers/net/intel/e1000/base/e1000_vf.c | 4 ++--
+ drivers/net/e1000/base/e1000_mac.c | 4 ++--
+ drivers/net/e1000/base/e1000_vf.c | 4 ++--
@@ -25 +27 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_mac.c b/drivers/net/intel/e1000/base/e1000_mac.c
+diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
@@ -27,2 +29,2 @@
---- a/drivers/net/intel/e1000/base/e1000_mac.c
-+++ b/drivers/net/intel/e1000/base/e1000_mac.c
+--- a/drivers/net/e1000/base/e1000_mac.c
++++ b/drivers/net/e1000/base/e1000_mac.c
@@ -47 +49 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_vf.c b/drivers/net/intel/e1000/base/e1000_vf.c
+diff --git a/drivers/net/e1000/base/e1000_vf.c b/drivers/net/e1000/base/e1000_vf.c
@@ -49,2 +51,2 @@
---- a/drivers/net/intel/e1000/base/e1000_vf.c
-+++ b/drivers/net/intel/e1000/base/e1000_vf.c
+--- a/drivers/net/e1000/base/e1000_vf.c
++++ b/drivers/net/e1000/base/e1000_vf.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix data type in MAC hash' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (60 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/e1000/base: fix MAC address hash bit shift' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/e1000/base: fix uninitialized variable' " Xueming Li
` (25 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Barbara Skobiej; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=aa5d1f8824a72dfc6217232c7f372d9c8c985893
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From aa5d1f8824a72dfc6217232c7f372d9c8c985893 Mon Sep 17 00:00:00 2001
From: Barbara Skobiej <barbara.skobiej@intel.com>
Date: Thu, 6 Feb 2025 16:08:41 +0000
Subject: [PATCH] net/e1000/base: fix data type in MAC hash
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 458734aaac3225d98aeee5f4c45b3d39a7d82949 ]
One of the bit shifts in MAC hash calculation triggers a static analysis
warning about a potential overflow. Fix the data type to avoid this.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Barbara Skobiej <barbara.skobiej@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_mac.c | 6 ++++--
drivers/net/e1000/base/e1000_vf.c | 6 ++++--
2 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
index 2b8482e114..5bb77d9e09 100644
--- a/drivers/net/e1000/base/e1000_mac.c
+++ b/drivers/net/e1000/base/e1000_mac.c
@@ -541,8 +541,10 @@ u32 e1000_hash_mc_addr_generic(struct e1000_hw *hw, u8 *mc_addr)
break;
}
- hash_value = hash_mask & (((mc_addr[4] >> (8 - bit_shift)) |
- (((u16) mc_addr[5]) << bit_shift)));
+ hash_value = (u32)mc_addr[4];
+ hash_value = hash_value >> (8 - bit_shift);
+ hash_value |= (((u32)mc_addr[5]) << bit_shift);
+ hash_value &= hash_mask;
return hash_value;
}
diff --git a/drivers/net/e1000/base/e1000_vf.c b/drivers/net/e1000/base/e1000_vf.c
index 3d0383fcbb..fc30357c17 100644
--- a/drivers/net/e1000/base/e1000_vf.c
+++ b/drivers/net/e1000/base/e1000_vf.c
@@ -345,8 +345,10 @@ STATIC u32 e1000_hash_mc_addr_vf(struct e1000_hw *hw, u8 *mc_addr)
while (hash_mask >> bit_shift != 0xFF && bit_shift < 4)
bit_shift++;
- hash_value = hash_mask & (((mc_addr[4] >> (8 - bit_shift)) |
- (((u16) mc_addr[5]) << bit_shift)));
+ hash_value = (u32)mc_addr[4];
+ hash_value = hash_value >> (8 - bit_shift);
+ hash_value |= (((u32)mc_addr[5]) << bit_shift);
+ hash_value &= hash_mask;
return hash_value;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.901986456 +0800
+++ 0062-net-e1000-base-fix-data-type-in-MAC-hash.patch 2025-02-18 19:39:00.668244041 +0800
@@ -1 +1 @@
-From 458734aaac3225d98aeee5f4c45b3d39a7d82949 Mon Sep 17 00:00:00 2001
+From aa5d1f8824a72dfc6217232c7f372d9c8c985893 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 458734aaac3225d98aeee5f4c45b3d39a7d82949 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16,2 +18,2 @@
- drivers/net/intel/e1000/base/e1000_mac.c | 6 ++++--
- drivers/net/intel/e1000/base/e1000_vf.c | 6 ++++--
+ drivers/net/e1000/base/e1000_mac.c | 6 ++++--
+ drivers/net/e1000/base/e1000_vf.c | 6 ++++--
@@ -20 +22 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_mac.c b/drivers/net/intel/e1000/base/e1000_mac.c
+diff --git a/drivers/net/e1000/base/e1000_mac.c b/drivers/net/e1000/base/e1000_mac.c
@@ -22,2 +24,2 @@
---- a/drivers/net/intel/e1000/base/e1000_mac.c
-+++ b/drivers/net/intel/e1000/base/e1000_mac.c
+--- a/drivers/net/e1000/base/e1000_mac.c
++++ b/drivers/net/e1000/base/e1000_mac.c
@@ -37 +39 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_vf.c b/drivers/net/intel/e1000/base/e1000_vf.c
+diff --git a/drivers/net/e1000/base/e1000_vf.c b/drivers/net/e1000/base/e1000_vf.c
@@ -39,2 +41,2 @@
---- a/drivers/net/intel/e1000/base/e1000_vf.c
-+++ b/drivers/net/intel/e1000/base/e1000_vf.c
+--- a/drivers/net/e1000/base/e1000_vf.c
++++ b/drivers/net/e1000/base/e1000_vf.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix uninitialized variable' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (61 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/e1000/base: fix data type in MAC hash' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:34 ` patch 'net/e1000/base: fix bitwise operation type' " Xueming Li
` (24 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Jakub Buchocki; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=ab2ad1b126e0eedf153583c78e87ced7ac03b699
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From ab2ad1b126e0eedf153583c78e87ced7ac03b699 Mon Sep 17 00:00:00 2001
From: Jakub Buchocki <jakubx.buchocki@intel.com>
Date: Thu, 6 Feb 2025 16:08:42 +0000
Subject: [PATCH] net/e1000/base: fix uninitialized variable
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 4be9a7008efe063fbd326fea9965f946c8969039 ]
Static analysis has detected potential usage of uninitialized values
inside the array. Fix the warning by initializing array.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Jakub Buchocki <jakubx.buchocki@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
.mailmap | 1 +
drivers/net/e1000/base/e1000_vf.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/.mailmap b/.mailmap
index b479ac34a0..90b3d473b7 100644
--- a/.mailmap
+++ b/.mailmap
@@ -585,6 +585,7 @@ Jacek Naczyk <jacek.naczyk@intel.com>
Jacek Piasecki <jacekx.piasecki@intel.com>
Jacek Siuda <jck@semihalf.com>
Jacob Keller <jacob.e.keller@intel.com>
+Jakub Buchocki <jakubx.buchocki@intel.com>
Jakub Chylkowski <jakubx.chylkowski@intel.com>
Jakub Grajciar <jgrajcia@cisco.com>
Jakub Neruda <neruda@netcope.com>
diff --git a/drivers/net/e1000/base/e1000_vf.c b/drivers/net/e1000/base/e1000_vf.c
index fc30357c17..472b921b6f 100644
--- a/drivers/net/e1000/base/e1000_vf.c
+++ b/drivers/net/e1000/base/e1000_vf.c
@@ -376,7 +376,7 @@ STATIC void e1000_write_msg_read_ack(struct e1000_hw *hw,
void e1000_update_mc_addr_list_vf(struct e1000_hw *hw,
u8 *mc_addr_list, u32 mc_addr_count)
{
- u32 msgbuf[E1000_VFMAILBOX_SIZE];
+ u32 msgbuf[E1000_VFMAILBOX_SIZE] = {0};
u16 *hash_list = (u16 *)&msgbuf[1];
u32 hash_value;
u32 i;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.935028950 +0800
+++ 0063-net-e1000-base-fix-uninitialized-variable.patch 2025-02-18 19:39:00.668244041 +0800
@@ -1 +1 @@
-From 4be9a7008efe063fbd326fea9965f946c8969039 Mon Sep 17 00:00:00 2001
+From ab2ad1b126e0eedf153583c78e87ced7ac03b699 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 4be9a7008efe063fbd326fea9965f946c8969039 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16,2 +18,2 @@
- .mailmap | 1 +
- drivers/net/intel/e1000/base/e1000_vf.c | 2 +-
+ .mailmap | 1 +
+ drivers/net/e1000/base/e1000_vf.c | 2 +-
@@ -21 +23 @@
-index ab03985acd..af83b4e129 100644
+index b479ac34a0..90b3d473b7 100644
@@ -24 +26,2 @@
-@@ -620,6 +620,7 @@ Jacek Piasecki <jacekx.piasecki@intel.com>
+@@ -585,6 +585,7 @@ Jacek Naczyk <jacek.naczyk@intel.com>
+ Jacek Piasecki <jacekx.piasecki@intel.com>
@@ -26 +28,0 @@
- Jack Bond-Preston <jack.bond-preston@foss.arm.com> <jack.bond-preston@arm.com>
@@ -32 +34 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_vf.c b/drivers/net/intel/e1000/base/e1000_vf.c
+diff --git a/drivers/net/e1000/base/e1000_vf.c b/drivers/net/e1000/base/e1000_vf.c
@@ -34,2 +36,2 @@
---- a/drivers/net/intel/e1000/base/e1000_vf.c
-+++ b/drivers/net/intel/e1000/base/e1000_vf.c
+--- a/drivers/net/e1000/base/e1000_vf.c
++++ b/drivers/net/e1000/base/e1000_vf.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix bitwise operation type' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (62 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/e1000/base: fix uninitialized variable' " Xueming Li
@ 2025-02-18 12:34 ` Xueming Li
2025-02-18 12:35 ` patch 'net/e1000/base: fix NVM data type in bit shift' " Xueming Li
` (23 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:34 UTC (permalink / raw)
To: Przemyslaw Ciesielski
Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=e9e13a7032e5230e382c336cc55303220505878a
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From e9e13a7032e5230e382c336cc55303220505878a Mon Sep 17 00:00:00 2001
From: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Date: Thu, 6 Feb 2025 16:08:43 +0000
Subject: [PATCH] net/e1000/base: fix bitwise operation type
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit c848457b38851f175893488c0be713995cb19bf2 ]
There is a static analysis warning due to wrong data types being used
for SW/FW semaphore masking. Fix it via explicit type cast.
Fixes: 5a32a257f957 ("e1000: more NICs in base driver")
Signed-off-by: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_80003es2lan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/e1000/base/e1000_80003es2lan.c b/drivers/net/e1000/base/e1000_80003es2lan.c
index 243bc6fe3e..3516ff2246 100644
--- a/drivers/net/e1000/base/e1000_80003es2lan.c
+++ b/drivers/net/e1000/base/e1000_80003es2lan.c
@@ -426,7 +426,7 @@ STATIC void e1000_release_swfw_sync_80003es2lan(struct e1000_hw *hw, u16 mask)
; /* Empty */
swfw_sync = E1000_READ_REG(hw, E1000_SW_FW_SYNC);
- swfw_sync &= ~mask;
+ swfw_sync &= ~(u32)mask;
E1000_WRITE_REG(hw, E1000_SW_FW_SYNC, swfw_sync);
e1000_put_hw_semaphore_generic(hw);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.967446245 +0800
+++ 0064-net-e1000-base-fix-bitwise-operation-type.patch 2025-02-18 19:39:00.668244041 +0800
@@ -1 +1 @@
-From c848457b38851f175893488c0be713995cb19bf2 Mon Sep 17 00:00:00 2001
+From e9e13a7032e5230e382c336cc55303220505878a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit c848457b38851f175893488c0be713995cb19bf2 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/e1000/base/e1000_80003es2lan.c | 2 +-
+ drivers/net/e1000/base/e1000_80003es2lan.c | 2 +-
@@ -19 +21 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_80003es2lan.c b/drivers/net/intel/e1000/base/e1000_80003es2lan.c
+diff --git a/drivers/net/e1000/base/e1000_80003es2lan.c b/drivers/net/e1000/base/e1000_80003es2lan.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/e1000/base/e1000_80003es2lan.c
-+++ b/drivers/net/intel/e1000/base/e1000_80003es2lan.c
+--- a/drivers/net/e1000/base/e1000_80003es2lan.c
++++ b/drivers/net/e1000/base/e1000_80003es2lan.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix NVM data type in bit shift' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (63 preceding siblings ...)
2025-02-18 12:34 ` patch 'net/e1000/base: fix bitwise operation type' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/e1000/base: fix reset for 82580' " Xueming Li
` (22 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Przemyslaw Ciesielski
Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=7b701f1df0774ec43b248b48c2f1d4cf99c596ff
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 7b701f1df0774ec43b248b48c2f1d4cf99c596ff Mon Sep 17 00:00:00 2001
From: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Date: Thu, 6 Feb 2025 16:08:44 +0000
Subject: [PATCH] net/e1000/base: fix NVM data type in bit shift
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit b932270c66d0179824118afbfd7cfb347ddf07d2 ]
There is a static analysis warning due to wrong data types being used
for NVM read data shifts. Fix it via explicit type cast.
Fixes: 38db3f7f50bd ("e1000: update base driver")
Signed-off-by: Przemyslaw Ciesielski <przemyslaw.ciesielski@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_nvm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/e1000/base/e1000_nvm.c b/drivers/net/e1000/base/e1000_nvm.c
index 430fecaf6d..d171bea649 100644
--- a/drivers/net/e1000/base/e1000_nvm.c
+++ b/drivers/net/e1000/base/e1000_nvm.c
@@ -935,14 +935,14 @@ s32 e1000_read_pba_num_generic(struct e1000_hw *hw, u32 *pba_num)
DEBUGOUT("NVM Not Supported\n");
return -E1000_NOT_IMPLEMENTED;
}
- *pba_num = (u32)(nvm_data << 16);
+ *pba_num = ((u32)nvm_data << 16);
ret_val = hw->nvm.ops.read(hw, NVM_PBA_OFFSET_1, 1, &nvm_data);
if (ret_val) {
DEBUGOUT("NVM Read Error\n");
return ret_val;
}
- *pba_num |= nvm_data;
+ *pba_num |= (u32)nvm_data;
return E1000_SUCCESS;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:02.998587839 +0800
+++ 0065-net-e1000-base-fix-NVM-data-type-in-bit-shift.patch 2025-02-18 19:39:00.678244039 +0800
@@ -1 +1 @@
-From b932270c66d0179824118afbfd7cfb347ddf07d2 Mon Sep 17 00:00:00 2001
+From 7b701f1df0774ec43b248b48c2f1d4cf99c596ff Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit b932270c66d0179824118afbfd7cfb347ddf07d2 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/e1000/base/e1000_nvm.c | 4 ++--
+ drivers/net/e1000/base/e1000_nvm.c | 4 ++--
@@ -19 +21 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_nvm.c b/drivers/net/intel/e1000/base/e1000_nvm.c
+diff --git a/drivers/net/e1000/base/e1000_nvm.c b/drivers/net/e1000/base/e1000_nvm.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/e1000/base/e1000_nvm.c
-+++ b/drivers/net/intel/e1000/base/e1000_nvm.c
+--- a/drivers/net/e1000/base/e1000_nvm.c
++++ b/drivers/net/e1000/base/e1000_nvm.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix reset for 82580' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (64 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/e1000/base: fix NVM data type in bit shift' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/e1000/base: fix unchecked return' " Xueming Li
` (21 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Barbara Skobiej; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c1bf1797d4abd42b94ae697d0436bc452cdf42bc
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From c1bf1797d4abd42b94ae697d0436bc452cdf42bc Mon Sep 17 00:00:00 2001
From: Barbara Skobiej <barbara.skobiej@intel.com>
Date: Thu, 6 Feb 2025 16:08:45 +0000
Subject: [PATCH] net/e1000/base: fix reset for 82580
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 88a1eb79ef08d309af58ad4921db7200fa7c5073 ]
Fix setting device reset status bit in e1000_reset_hw_82580() function
for 82580 by first reading the register value, and then setting the
device reset bit.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Barbara Skobiej <barbara.skobiej@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_82575.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/net/e1000/base/e1000_82575.c b/drivers/net/e1000/base/e1000_82575.c
index 53900cf8f1..948c80f2fa 100644
--- a/drivers/net/e1000/base/e1000_82575.c
+++ b/drivers/net/e1000/base/e1000_82575.c
@@ -2280,7 +2280,7 @@ STATIC s32 e1000_reset_hw_82580(struct e1000_hw *hw)
s32 ret_val = E1000_SUCCESS;
/* BH SW mailbox bit in SW_FW_SYNC */
u16 swmbsw_mask = E1000_SW_SYNCH_MB;
- u32 ctrl;
+ u32 ctrl, status;
bool global_device_reset = hw->dev_spec._82575.global_device_reset;
DEBUGFUNC("e1000_reset_hw_82580");
@@ -2345,7 +2345,8 @@ STATIC s32 e1000_reset_hw_82580(struct e1000_hw *hw)
}
/* clear global device reset status bit */
- E1000_WRITE_REG(hw, E1000_STATUS, E1000_STAT_DEV_RST_SET);
+ status = E1000_READ_REG(hw, E1000_STATUS);
+ E1000_WRITE_REG(hw, E1000_STATUS, status | E1000_STAT_DEV_RST_SET);
/* Clear any pending interrupt events. */
E1000_WRITE_REG(hw, E1000_IMC, 0xffffffff);
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.026714635 +0800
+++ 0066-net-e1000-base-fix-reset-for-82580.patch 2025-02-18 19:39:00.678244039 +0800
@@ -1 +1 @@
-From 88a1eb79ef08d309af58ad4921db7200fa7c5073 Mon Sep 17 00:00:00 2001
+From c1bf1797d4abd42b94ae697d0436bc452cdf42bc Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 88a1eb79ef08d309af58ad4921db7200fa7c5073 ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -17 +19 @@
- drivers/net/intel/e1000/base/e1000_82575.c | 5 +++--
+ drivers/net/e1000/base/e1000_82575.c | 5 +++--
@@ -20 +22 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_82575.c b/drivers/net/intel/e1000/base/e1000_82575.c
+diff --git a/drivers/net/e1000/base/e1000_82575.c b/drivers/net/e1000/base/e1000_82575.c
@@ -22,2 +24,2 @@
---- a/drivers/net/intel/e1000/base/e1000_82575.c
-+++ b/drivers/net/intel/e1000/base/e1000_82575.c
+--- a/drivers/net/e1000/base/e1000_82575.c
++++ b/drivers/net/e1000/base/e1000_82575.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: fix unchecked return' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (65 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/e1000/base: fix reset for 82580' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/e1000/base: skip management check for 82575' " Xueming Li
` (20 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Dima Ruinskiy; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=5e89940b48fea2192a3d213f9b67b43d3642a9ae
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 5e89940b48fea2192a3d213f9b67b43d3642a9ae Mon Sep 17 00:00:00 2001
From: Dima Ruinskiy <dima.ruinskiy@intel.com>
Date: Thu, 6 Feb 2025 16:08:46 +0000
Subject: [PATCH] net/e1000/base: fix unchecked return
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit b0b6b50c20b03170c83985194fd9acef9467ded6 ]
Static analysis has detected a write that is not checked for errors,
leading to ignored error return value. Add a check.
Fixes: edcdb3c5f71b ("e1000/base: fix link flap on 82579")
Signed-off-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_ich8lan.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/e1000/base/e1000_ich8lan.c b/drivers/net/e1000/base/e1000_ich8lan.c
index 14f86b7bdc..f5f91a148c 100644
--- a/drivers/net/e1000/base/e1000_ich8lan.c
+++ b/drivers/net/e1000/base/e1000_ich8lan.c
@@ -962,6 +962,8 @@ s32 e1000_set_eee_pchlan(struct e1000_hw *hw)
data &= ~I82579_LPI_100_PLL_SHUT;
ret_val = e1000_write_emi_reg_locked(hw, I82579_LPI_PLL_SHUT,
data);
+ if (ret_val)
+ goto release;
}
/* R/Clr IEEE MMD 3.1 bits 11:10 - Tx/Rx LPI Received */
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.058190129 +0800
+++ 0067-net-e1000-base-fix-unchecked-return.patch 2025-02-18 19:39:00.678244039 +0800
@@ -1 +1 @@
-From b0b6b50c20b03170c83985194fd9acef9467ded6 Mon Sep 17 00:00:00 2001
+From 5e89940b48fea2192a3d213f9b67b43d3642a9ae Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit b0b6b50c20b03170c83985194fd9acef9467ded6 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/e1000/base/e1000_ich8lan.c | 2 ++
+ drivers/net/e1000/base/e1000_ich8lan.c | 2 ++
@@ -19 +21 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_ich8lan.c b/drivers/net/intel/e1000/base/e1000_ich8lan.c
+diff --git a/drivers/net/e1000/base/e1000_ich8lan.c b/drivers/net/e1000/base/e1000_ich8lan.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/e1000/base/e1000_ich8lan.c
-+++ b/drivers/net/intel/e1000/base/e1000_ich8lan.c
+--- a/drivers/net/e1000/base/e1000_ich8lan.c
++++ b/drivers/net/e1000/base/e1000_ich8lan.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/e1000/base: skip management check for 82575' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (66 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/e1000/base: fix unchecked return' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'common/idpf: fix void function returning a value' " Xueming Li
` (19 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Carolyn Wyborny; +Cc: xuemingl, Anatoly Burakov, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=79196f75abaa248cadbe9dee500bd12dd78acb50
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 79196f75abaa248cadbe9dee500bd12dd78acb50 Mon Sep 17 00:00:00 2001
From: Carolyn Wyborny <carolyn.wyborny@intel.com>
Date: Thu, 6 Feb 2025 16:08:47 +0000
Subject: [PATCH] net/e1000/base: skip management check for 82575
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit d107a23f60c6a8b9543c386ecc48abc4f92f50d3 ]
On 82575, driver is not supposed to check if management control is
enabled, and flush the Rx FIFO unconditionally.
Fixes: 44dddd14059f ("net/e1000/base: remove duplicated codes")
Signed-off-by: Carolyn Wyborny <carolyn.wyborny@intel.com>
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/e1000/base/e1000_base.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/e1000/base/e1000_base.c b/drivers/net/e1000/base/e1000_base.c
index 3ec32e7240..e10bc6907a 100644
--- a/drivers/net/e1000/base/e1000_base.c
+++ b/drivers/net/e1000/base/e1000_base.c
@@ -132,7 +132,8 @@ void e1000_rx_fifo_flush_base(struct e1000_hw *hw)
rfctl |= E1000_RFCTL_IPV6_EX_DIS;
E1000_WRITE_REG(hw, E1000_RFCTL, rfctl);
- if (!(E1000_READ_REG(hw, E1000_MANC) & E1000_MANC_RCV_TCO_EN))
+ if (hw->mac.type != e1000_82575 ||
+ !(E1000_READ_REG(hw, E1000_MANC) & E1000_MANC_RCV_TCO_EN))
return;
/* Disable all Rx queues */
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.091666723 +0800
+++ 0068-net-e1000-base-skip-management-check-for-82575.patch 2025-02-18 19:39:00.678244039 +0800
@@ -1 +1 @@
-From d107a23f60c6a8b9543c386ecc48abc4f92f50d3 Mon Sep 17 00:00:00 2001
+From 79196f75abaa248cadbe9dee500bd12dd78acb50 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit d107a23f60c6a8b9543c386ecc48abc4f92f50d3 ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/e1000/base/e1000_base.c | 3 ++-
+ drivers/net/e1000/base/e1000_base.c | 3 ++-
@@ -19 +21 @@
-diff --git a/drivers/net/intel/e1000/base/e1000_base.c b/drivers/net/intel/e1000/base/e1000_base.c
+diff --git a/drivers/net/e1000/base/e1000_base.c b/drivers/net/e1000/base/e1000_base.c
@@ -21,2 +23,2 @@
---- a/drivers/net/intel/e1000/base/e1000_base.c
-+++ b/drivers/net/intel/e1000/base/e1000_base.c
+--- a/drivers/net/e1000/base/e1000_base.c
++++ b/drivers/net/e1000/base/e1000_base.c
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'common/idpf: fix void function returning a value' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (67 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/e1000/base: skip management check for 82575' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/intel: fix void functions " Xueming Li
` (18 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Andre Muezerie; +Cc: xuemingl, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=b60a546487237f2b2c011d921db850c71ba6c5e0
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From b60a546487237f2b2c011d921db850c71ba6c5e0 Mon Sep 17 00:00:00 2001
From: Andre Muezerie <andremue@linux.microsoft.com>
Date: Wed, 22 Jan 2025 07:20:43 -0800
Subject: [PATCH] common/idpf: fix void function returning a value
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit c39e89b467c510923295a73e5b76a6a44c72dd1b ]
This patch avoids warnings like the one below emitted by MSVC:
../drivers/common/idpf/idpf_common_rxtx_avx512.c(139):
warning C4098: 'idpf_singleq_rearm':
'void' function returning a value
Fixes: 5bf87b45b2c8 ("net/idpf: add AVX512 data path for single queue model")
Fixes: e528d7c74819 ("common/idpf: add AVX512 data path for split queue model")
Signed-off-by: Andre Muezerie <andremue@linux.microsoft.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/common/idpf/idpf_common_rxtx_avx512.c | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/drivers/common/idpf/idpf_common_rxtx_avx512.c b/drivers/common/idpf/idpf_common_rxtx_avx512.c
index 5abafc729b..617ef092d1 100644
--- a/drivers/common/idpf/idpf_common_rxtx_avx512.c
+++ b/drivers/common/idpf/idpf_common_rxtx_avx512.c
@@ -137,8 +137,10 @@ idpf_singleq_rearm(struct idpf_rx_queue *rxq)
rxdp += rxq->rxrearm_start;
- if (unlikely(cache == NULL))
- return idpf_singleq_rearm_common(rxq);
+ if (unlikely(cache == NULL)) {
+ idpf_singleq_rearm_common(rxq);
+ return;
+ }
/* We need to pull 'n' more MBUFs into the software ring from mempool
* We inline the mempool function here, so we can vectorize the copy
@@ -607,8 +609,10 @@ idpf_splitq_rearm(struct idpf_rx_queue *rx_bufq)
rxdp += rx_bufq->rxrearm_start;
- if (unlikely(!cache))
- return idpf_splitq_rearm_common(rx_bufq);
+ if (unlikely(!cache)) {
+ idpf_splitq_rearm_common(rx_bufq);
+ return;
+ }
/* We need to pull 'n' more MBUFs into the software ring from mempool
* We inline the mempool function here, so we can vectorize the copy
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.120612718 +0800
+++ 0069-common-idpf-fix-void-function-returning-a-value.patch 2025-02-18 19:39:00.688244037 +0800
@@ -1 +1 @@
-From c39e89b467c510923295a73e5b76a6a44c72dd1b Mon Sep 17 00:00:00 2001
+From b60a546487237f2b2c011d921db850c71ba6c5e0 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit c39e89b467c510923295a73e5b76a6a44c72dd1b ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
@@ -23 +25 @@
-index 6fbfee1b2d..b630d1fcd9 100644
+index 5abafc729b..617ef092d1 100644
@@ -26 +28 @@
-@@ -133,8 +133,10 @@ idpf_singleq_rearm(struct idpf_rx_queue *rxq)
+@@ -137,8 +137,10 @@ idpf_singleq_rearm(struct idpf_rx_queue *rxq)
@@ -39 +41 @@
-@@ -603,8 +605,10 @@ idpf_splitq_rearm(struct idpf_rx_queue *rx_bufq)
+@@ -607,8 +609,10 @@ idpf_splitq_rearm(struct idpf_rx_queue *rx_bufq)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/intel: fix void functions returning a value' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (68 preceding siblings ...)
2025-02-18 12:35 ` patch 'common/idpf: fix void function returning a value' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/intel: fix build with icx' " Xueming Li
` (17 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Andre Muezerie; +Cc: xuemingl, Bruce Richardson, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=774b751b986957a586dbf4f3305021f8c62be09e
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 774b751b986957a586dbf4f3305021f8c62be09e Mon Sep 17 00:00:00 2001
From: Andre Muezerie <andremue@linux.microsoft.com>
Date: Wed, 22 Jan 2025 07:20:44 -0800
Subject: [PATCH] net/intel: fix void functions returning a value
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit bc64580a631ee4ad67d7a2a9ae96a63e8d4a02b1 ]
This patch avoids warnings like the one below emitted by MSVC:
../drivers/common/idpf/idpf_common_rxtx_avx512.c(139):
warning C4098: 'idpf_singleq_rearm':
'void' function returning a value
Fixes: 0604b1f2208f ("net/i40e: fix crash in AVX512")
Fixes: 4eb3dcce7c5d ("net/iavf: fix crash in AVX512")
Fixes: 20daa1c978b7 ("net/ice: fix crash in AVX512")
Signed-off-by: Andre Muezerie <andremue@linux.microsoft.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
drivers/net/i40e/i40e_rxtx_vec_avx2.c | 2 +-
drivers/net/i40e/i40e_rxtx_vec_avx512.c | 2 +-
drivers/net/iavf/iavf_rxtx_vec_avx2.c | 2 +-
drivers/net/ice/ice_rxtx_vec_avx2.c | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/net/i40e/i40e_rxtx_vec_avx2.c b/drivers/net/i40e/i40e_rxtx_vec_avx2.c
index 19cf0ac718..3e95a6a1df 100644
--- a/drivers/net/i40e/i40e_rxtx_vec_avx2.c
+++ b/drivers/net/i40e/i40e_rxtx_vec_avx2.c
@@ -22,7 +22,7 @@
static __rte_always_inline void
i40e_rxq_rearm(struct i40e_rx_queue *rxq)
{
- return i40e_rxq_rearm_common(rxq, false);
+ i40e_rxq_rearm_common(rxq, false);
}
#ifndef RTE_LIBRTE_I40E_16BYTE_RX_DESC
diff --git a/drivers/net/i40e/i40e_rxtx_vec_avx512.c b/drivers/net/i40e/i40e_rxtx_vec_avx512.c
index 62fce19dc4..3bf0faf066 100644
--- a/drivers/net/i40e/i40e_rxtx_vec_avx512.c
+++ b/drivers/net/i40e/i40e_rxtx_vec_avx512.c
@@ -24,7 +24,7 @@
static __rte_always_inline void
i40e_rxq_rearm(struct i40e_rx_queue *rxq)
{
- return i40e_rxq_rearm_common(rxq, true);
+ i40e_rxq_rearm_common(rxq, true);
}
#ifndef RTE_LIBRTE_I40E_16BYTE_RX_DESC
diff --git a/drivers/net/iavf/iavf_rxtx_vec_avx2.c b/drivers/net/iavf/iavf_rxtx_vec_avx2.c
index 49d41af953..cdb48438da 100644
--- a/drivers/net/iavf/iavf_rxtx_vec_avx2.c
+++ b/drivers/net/iavf/iavf_rxtx_vec_avx2.c
@@ -13,7 +13,7 @@
static __rte_always_inline void
iavf_rxq_rearm(struct iavf_rx_queue *rxq)
{
- return iavf_rxq_rearm_common(rxq, false);
+ iavf_rxq_rearm_common(rxq, false);
}
#define PKTLEN_SHIFT 10
diff --git a/drivers/net/ice/ice_rxtx_vec_avx2.c b/drivers/net/ice/ice_rxtx_vec_avx2.c
index d6e88dbb29..02bfb9b15d 100644
--- a/drivers/net/ice/ice_rxtx_vec_avx2.c
+++ b/drivers/net/ice/ice_rxtx_vec_avx2.c
@@ -14,7 +14,7 @@
static __rte_always_inline void
ice_rxq_rearm(struct ice_rx_queue *rxq)
{
- return ice_rxq_rearm_common(rxq, false);
+ ice_rxq_rearm_common(rxq, false);
}
static __rte_always_inline __m256i
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.153662913 +0800
+++ 0070-net-intel-fix-void-functions-returning-a-value.patch 2025-02-18 19:39:00.688244037 +0800
@@ -1 +1 @@
-From bc64580a631ee4ad67d7a2a9ae96a63e8d4a02b1 Mon Sep 17 00:00:00 2001
+From 774b751b986957a586dbf4f3305021f8c62be09e Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit bc64580a631ee4ad67d7a2a9ae96a63e8d4a02b1 ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -20,4 +22,4 @@
- drivers/net/intel/i40e/i40e_rxtx_vec_avx2.c | 2 +-
- drivers/net/intel/i40e/i40e_rxtx_vec_avx512.c | 2 +-
- drivers/net/intel/iavf/iavf_rxtx_vec_avx2.c | 2 +-
- drivers/net/intel/ice/ice_rxtx_vec_avx2.c | 2 +-
+ drivers/net/i40e/i40e_rxtx_vec_avx2.c | 2 +-
+ drivers/net/i40e/i40e_rxtx_vec_avx512.c | 2 +-
+ drivers/net/iavf/iavf_rxtx_vec_avx2.c | 2 +-
+ drivers/net/ice/ice_rxtx_vec_avx2.c | 2 +-
@@ -26,5 +28,5 @@
-diff --git a/drivers/net/intel/i40e/i40e_rxtx_vec_avx2.c b/drivers/net/intel/i40e/i40e_rxtx_vec_avx2.c
-index 504015de6e..9c406e7a6f 100644
---- a/drivers/net/intel/i40e/i40e_rxtx_vec_avx2.c
-+++ b/drivers/net/intel/i40e/i40e_rxtx_vec_avx2.c
-@@ -18,7 +18,7 @@
+diff --git a/drivers/net/i40e/i40e_rxtx_vec_avx2.c b/drivers/net/i40e/i40e_rxtx_vec_avx2.c
+index 19cf0ac718..3e95a6a1df 100644
+--- a/drivers/net/i40e/i40e_rxtx_vec_avx2.c
++++ b/drivers/net/i40e/i40e_rxtx_vec_avx2.c
+@@ -22,7 +22,7 @@
@@ -39,5 +41,5 @@
-diff --git a/drivers/net/intel/i40e/i40e_rxtx_vec_avx512.c b/drivers/net/intel/i40e/i40e_rxtx_vec_avx512.c
-index c10ae050d3..d8244556c0 100644
---- a/drivers/net/intel/i40e/i40e_rxtx_vec_avx512.c
-+++ b/drivers/net/intel/i40e/i40e_rxtx_vec_avx512.c
-@@ -20,7 +20,7 @@
+diff --git a/drivers/net/i40e/i40e_rxtx_vec_avx512.c b/drivers/net/i40e/i40e_rxtx_vec_avx512.c
+index 62fce19dc4..3bf0faf066 100644
+--- a/drivers/net/i40e/i40e_rxtx_vec_avx512.c
++++ b/drivers/net/i40e/i40e_rxtx_vec_avx512.c
+@@ -24,7 +24,7 @@
@@ -52,5 +54,5 @@
-diff --git a/drivers/net/intel/iavf/iavf_rxtx_vec_avx2.c b/drivers/net/intel/iavf/iavf_rxtx_vec_avx2.c
-index 3571835c5b..88e35dc3e9 100644
---- a/drivers/net/intel/iavf/iavf_rxtx_vec_avx2.c
-+++ b/drivers/net/intel/iavf/iavf_rxtx_vec_avx2.c
-@@ -9,7 +9,7 @@
+diff --git a/drivers/net/iavf/iavf_rxtx_vec_avx2.c b/drivers/net/iavf/iavf_rxtx_vec_avx2.c
+index 49d41af953..cdb48438da 100644
+--- a/drivers/net/iavf/iavf_rxtx_vec_avx2.c
++++ b/drivers/net/iavf/iavf_rxtx_vec_avx2.c
+@@ -13,7 +13,7 @@
@@ -65,5 +67,5 @@
-diff --git a/drivers/net/intel/ice/ice_rxtx_vec_avx2.c b/drivers/net/intel/ice/ice_rxtx_vec_avx2.c
-index 8dc9b51c5c..0c54b325c6 100644
---- a/drivers/net/intel/ice/ice_rxtx_vec_avx2.c
-+++ b/drivers/net/intel/ice/ice_rxtx_vec_avx2.c
-@@ -10,7 +10,7 @@
+diff --git a/drivers/net/ice/ice_rxtx_vec_avx2.c b/drivers/net/ice/ice_rxtx_vec_avx2.c
+index d6e88dbb29..02bfb9b15d 100644
+--- a/drivers/net/ice/ice_rxtx_vec_avx2.c
++++ b/drivers/net/ice/ice_rxtx_vec_avx2.c
+@@ -14,7 +14,7 @@
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/intel: fix build with icx' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (69 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/intel: fix void functions " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/hns3: fix copper port initialization' " Xueming Li
` (16 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Bruce Richardson; +Cc: xuemingl, Ian Stokes, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=9c13d0d07a36076a1fd7a4fd25b46afcdf70c841
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 9c13d0d07a36076a1fd7a4fd25b46afcdf70c841 Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Mon, 10 Feb 2025 17:19:57 +0000
Subject: [PATCH] net/intel: fix build with icx
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 2641704664267dd3ebe4ad77784ae28440dfaf60 ]
The Intel oneAPI DPC++/C++ Compiler (icx), issues warnings on build when
the "-march=native", or other configured global "-march" flag, is
overridden to "skylake-avx512", when compiling AVX-512 code.
Allow building with icx with warnings-as-errors flag (werror) enabled by
disabling the warning for the cases where we pass that extra "-march"
flag.
Fixes: e6a6a138919f ("net/i40e: add AVX512 vector path")
Fixes: 31737f2b66fb ("net/iavf: enable AVX512 for legacy Rx")
Fixes: 7f85d5ebcfe1 ("net/ice: add AVX512 vector path")
Fixes: 0fac6a1c44d5 ("common/idpf: add AVX512 for single queue model")
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Ian Stokes <ian.stokes@intel.com>
---
drivers/net/i40e/meson.build | 3 +++
drivers/net/iavf/meson.build | 3 +++
drivers/net/ice/meson.build | 3 +++
3 files changed, 9 insertions(+)
diff --git a/drivers/net/i40e/meson.build b/drivers/net/i40e/meson.build
index 80171b9dc6..e3b19e60a1 100644
--- a/drivers/net/i40e/meson.build
+++ b/drivers/net/i40e/meson.build
@@ -71,6 +71,9 @@ if arch_subdir == 'x86'
avx512_args = [cflags, '-mavx512f', '-mavx512bw']
if cc.has_argument('-march=skylake-avx512')
avx512_args += '-march=skylake-avx512'
+ if cc.has_argument('-Wno-overriding-option')
+ avx512_args += '-Wno-overriding-option'
+ endif
endif
i40e_avx512_lib = static_library('i40e_avx512_lib',
'i40e_rxtx_vec_avx512.c',
diff --git a/drivers/net/iavf/meson.build b/drivers/net/iavf/meson.build
index a6ce2725c3..982ac2707b 100644
--- a/drivers/net/iavf/meson.build
+++ b/drivers/net/iavf/meson.build
@@ -50,6 +50,9 @@ if arch_subdir == 'x86'
avx512_args = [cflags, '-mavx512f', '-mavx512bw']
if cc.has_argument('-march=skylake-avx512')
avx512_args += '-march=skylake-avx512'
+ if cc.has_argument('-Wno-overriding-option')
+ avx512_args += '-Wno-overriding-option'
+ endif
endif
iavf_avx512_lib = static_library('iavf_avx512_lib',
'iavf_rxtx_vec_avx512.c',
diff --git a/drivers/net/ice/meson.build b/drivers/net/ice/meson.build
index a957fc5d3a..4016ee976b 100644
--- a/drivers/net/ice/meson.build
+++ b/drivers/net/ice/meson.build
@@ -51,6 +51,9 @@ if arch_subdir == 'x86'
avx512_args = [cflags, '-mavx512f', '-mavx512bw']
if cc.has_argument('-march=skylake-avx512')
avx512_args += '-march=skylake-avx512'
+ if cc.has_argument('-Wno-overriding-option')
+ avx512_args += '-Wno-overriding-option'
+ endif
endif
ice_avx512_lib = static_library('ice_avx512_lib',
'ice_rxtx_vec_avx512.c',
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.187417707 +0800
+++ 0071-net-intel-fix-build-with-icx.patch 2025-02-18 19:39:00.688244037 +0800
@@ -1 +1 @@
-From 2641704664267dd3ebe4ad77784ae28440dfaf60 Mon Sep 17 00:00:00 2001
+From 9c13d0d07a36076a1fd7a4fd25b46afcdf70c841 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 2641704664267dd3ebe4ad77784ae28440dfaf60 ]
@@ -18 +20,0 @@
-Cc: stable@dpdk.org
@@ -23,12 +25,11 @@
- drivers/net/intel/i40e/meson.build | 3 +++
- drivers/net/intel/iavf/meson.build | 3 +++
- drivers/net/intel/ice/meson.build | 3 +++
- drivers/net/intel/idpf/meson.build | 3 +++
- 4 files changed, 12 insertions(+)
-
-diff --git a/drivers/net/intel/i40e/meson.build b/drivers/net/intel/i40e/meson.build
-index 5c93493124..ffa40c5d64 100644
---- a/drivers/net/intel/i40e/meson.build
-+++ b/drivers/net/intel/i40e/meson.build
-@@ -57,6 +57,9 @@ if arch_subdir == 'x86'
- avx512_args = cflags + cc_avx512_flags
+ drivers/net/i40e/meson.build | 3 +++
+ drivers/net/iavf/meson.build | 3 +++
+ drivers/net/ice/meson.build | 3 +++
+ 3 files changed, 9 insertions(+)
+
+diff --git a/drivers/net/i40e/meson.build b/drivers/net/i40e/meson.build
+index 80171b9dc6..e3b19e60a1 100644
+--- a/drivers/net/i40e/meson.build
++++ b/drivers/net/i40e/meson.build
+@@ -71,6 +71,9 @@ if arch_subdir == 'x86'
+ avx512_args = [cflags, '-mavx512f', '-mavx512bw']
@@ -43,6 +44,6 @@
-diff --git a/drivers/net/intel/iavf/meson.build b/drivers/net/intel/iavf/meson.build
-index c823d618e3..19cd1cfbc8 100644
---- a/drivers/net/intel/iavf/meson.build
-+++ b/drivers/net/intel/iavf/meson.build
-@@ -45,6 +45,9 @@ if arch_subdir == 'x86'
- avx512_args = cflags + cc_avx512_flags
+diff --git a/drivers/net/iavf/meson.build b/drivers/net/iavf/meson.build
+index a6ce2725c3..982ac2707b 100644
+--- a/drivers/net/iavf/meson.build
++++ b/drivers/net/iavf/meson.build
+@@ -50,6 +50,9 @@ if arch_subdir == 'x86'
+ avx512_args = [cflags, '-mavx512f', '-mavx512bw']
@@ -57,4 +58,4 @@
-diff --git a/drivers/net/intel/ice/meson.build b/drivers/net/intel/ice/meson.build
-index ff7f84597a..a34b7c966a 100644
---- a/drivers/net/intel/ice/meson.build
-+++ b/drivers/net/intel/ice/meson.build
+diff --git a/drivers/net/ice/meson.build b/drivers/net/ice/meson.build
+index a957fc5d3a..4016ee976b 100644
+--- a/drivers/net/ice/meson.build
++++ b/drivers/net/ice/meson.build
@@ -62 +63 @@
- avx512_args = cflags + cc_avx512_flags
+ avx512_args = [cflags, '-mavx512f', '-mavx512bw']
@@ -71,14 +71,0 @@
-diff --git a/drivers/net/intel/idpf/meson.build b/drivers/net/intel/idpf/meson.build
-index f82c16746d..802b13035b 100644
---- a/drivers/net/intel/idpf/meson.build
-+++ b/drivers/net/intel/idpf/meson.build
-@@ -31,6 +31,9 @@ if arch_subdir == 'x86' and dpdk_conf.get('RTE_IOVA_IN_MBUF') == 1
- avx512_args = cflags + cc_avx512_flags
- if cc.has_argument('-march=skylake-avx512')
- avx512_args += '-march=skylake-avx512'
-+ if cc.has_argument('-Wno-overriding-option')
-+ avx512_args += '-Wno-overriding-option'
-+ endif
- endif
- idpf_common_avx512_lib = static_library('idpf_common_avx512_lib',
- 'idpf_common_rxtx_avx512.c',
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/hns3: fix copper port initialization' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (70 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/intel: fix build with icx' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/hns3: fix reset timeout' " Xueming Li
` (15 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Dengdui Huang; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=e0999f779484a90d6622ffc2644f029329d6185a
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From e0999f779484a90d6622ffc2644f029329d6185a Mon Sep 17 00:00:00 2001
From: Dengdui Huang <huangdengdui@huawei.com>
Date: Mon, 10 Feb 2025 11:01:12 +0800
Subject: [PATCH] net/hns3: fix copper port initialization
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 763546c33ea9600e76790c470d2921808068eb3d ]
The initialization of copper port contains the following two steps.
1. Configure firmware takeover the PHY. The firmware will start an
asynchronous task to initialize the PHY chip.
2. Configure work speed and duplex.
In earlier versions of the firmware, when the asynchronous task is not
finished, the firmware will return -ENOTBLK in the second step. And this
will lead to driver failed to initialize. Here add retry for this case.
Fixes: 2e4859f3b362 ("net/hns3: support PF device with copper PHYs")
Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
---
drivers/net/hns3/hns3_ethdev.c | 29 ++++++++++++++++++++++++++++-
1 file changed, 28 insertions(+), 1 deletion(-)
diff --git a/drivers/net/hns3/hns3_ethdev.c b/drivers/net/hns3/hns3_ethdev.c
index dde27715c0..dd450cddaa 100644
--- a/drivers/net/hns3/hns3_ethdev.c
+++ b/drivers/net/hns3/hns3_ethdev.c
@@ -4852,7 +4852,7 @@ hns3_get_link_duplex(uint32_t link_speeds)
}
static int
-hns3_set_copper_port_link_speed(struct hns3_hw *hw,
+hns3_copper_port_link_speed_cfg(struct hns3_hw *hw,
struct hns3_set_link_speed_cfg *cfg)
{
struct hns3_cmd_desc desc[HNS3_PHY_PARAM_CFG_BD_NUM];
@@ -4886,6 +4886,33 @@ hns3_set_copper_port_link_speed(struct hns3_hw *hw,
return hns3_cmd_send(hw, desc, HNS3_PHY_PARAM_CFG_BD_NUM);
}
+static int
+hns3_set_copper_port_link_speed(struct hns3_hw *hw,
+ struct hns3_set_link_speed_cfg *cfg)
+{
+#define HNS3_PHY_PARAM_CFG_RETRY_TIMES 10
+#define HNS3_PHY_PARAM_CFG_RETRY_DELAY_MS 100
+ uint32_t retry_cnt = 0;
+ int ret;
+
+ /*
+ * The initialization of copper port contains the following two steps.
+ * 1. Configure firmware takeover the PHY. The firmware will start an
+ * asynchronous task to initialize the PHY chip.
+ * 2. Configure work speed and duplex.
+ * In earlier versions of the firmware, when the asynchronous task is not
+ * finished, the firmware will return -ENOTBLK in the second step. And this
+ * will lead to driver failed to initialize. Here add retry for this case.
+ */
+ ret = hns3_copper_port_link_speed_cfg(hw, cfg);
+ while (ret == -ENOTBLK && retry_cnt++ < HNS3_PHY_PARAM_CFG_RETRY_TIMES) {
+ rte_delay_ms(HNS3_PHY_PARAM_CFG_RETRY_DELAY_MS);
+ ret = hns3_copper_port_link_speed_cfg(hw, cfg);
+ }
+
+ return ret;
+}
+
static int
hns3_set_autoneg(struct hns3_hw *hw, bool enable)
{
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.217410402 +0800
+++ 0072-net-hns3-fix-copper-port-initialization.patch 2025-02-18 19:39:00.698244036 +0800
@@ -1 +1 @@
-From 763546c33ea9600e76790c470d2921808068eb3d Mon Sep 17 00:00:00 2001
+From e0999f779484a90d6622ffc2644f029329d6185a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 763546c33ea9600e76790c470d2921808068eb3d ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -23 +25 @@
-index 72d1c30a7b..9f7119b734 100644
+index dde27715c0..dd450cddaa 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/hns3: fix reset timeout' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (71 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/hns3: fix copper port initialization' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/cpfl: fix representor parsing log' " Xueming Li
` (14 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Dengdui Huang; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=d6d17fcb1e2175c0a6e798c8749b06aa97948e87
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From d6d17fcb1e2175c0a6e798c8749b06aa97948e87 Mon Sep 17 00:00:00 2001
From: Dengdui Huang <huangdengdui@huawei.com>
Date: Mon, 10 Feb 2025 11:01:13 +0800
Subject: [PATCH] net/hns3: fix reset timeout
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 9f7c28c5e98062576dfbf555cd5ede7e33d6624b ]
There is low probability that the driver reset timeout, the root cause is
that the firmware processing take a litter long than normal when process
reset command. This patch fix it by changing the timeout of the reset
command to 100 ms.
Fixes: 737f30e1c3ab ("net/hns3: support command interface with firmware")
Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
---
drivers/net/hns3/hns3_cmd.c | 18 ++++++++++++------
drivers/net/hns3/hns3_cmd.h | 4 ++--
2 files changed, 14 insertions(+), 8 deletions(-)
diff --git a/drivers/net/hns3/hns3_cmd.c b/drivers/net/hns3/hns3_cmd.c
index 2c1664485b..62da6dd160 100644
--- a/drivers/net/hns3/hns3_cmd.c
+++ b/drivers/net/hns3/hns3_cmd.c
@@ -304,8 +304,17 @@ hns3_cmd_get_hardware_reply(struct hns3_hw *hw,
return hns3_cmd_convert_err_code(desc_ret);
}
-static int hns3_cmd_poll_reply(struct hns3_hw *hw)
+static uint32_t hns3_get_cmd_tx_timeout(uint16_t opcode)
{
+ if (opcode == HNS3_OPC_CFG_RST_TRIGGER)
+ return HNS3_COMQ_CFG_RST_TIMEOUT;
+
+ return HNS3_CMDQ_TX_TIMEOUT_DEFAULT;
+}
+
+static int hns3_cmd_poll_reply(struct hns3_hw *hw, uint16_t opcode)
+{
+ uint32_t cmdq_tx_timeout = hns3_get_cmd_tx_timeout(opcode);
struct hns3_adapter *hns = HNS3_DEV_HW_TO_ADAPTER(hw);
uint32_t timeout = 0;
@@ -326,7 +335,7 @@ static int hns3_cmd_poll_reply(struct hns3_hw *hw)
rte_delay_us(1);
timeout++;
- } while (timeout < hw->cmq.tx_timeout);
+ } while (timeout < cmdq_tx_timeout);
hns3_err(hw, "Wait for reply timeout");
return -ETIME;
}
@@ -400,7 +409,7 @@ hns3_cmd_send(struct hns3_hw *hw, struct hns3_cmd_desc *desc, int num)
* if multi descriptors to be sent, use the first one to check.
*/
if (HNS3_CMD_SEND_SYNC(rte_le_to_cpu_16(desc->flag))) {
- retval = hns3_cmd_poll_reply(hw);
+ retval = hns3_cmd_poll_reply(hw, desc->opcode);
if (!retval)
retval = hns3_cmd_get_hardware_reply(hw, desc, num,
ntc);
@@ -611,9 +620,6 @@ hns3_cmd_init_queue(struct hns3_hw *hw)
hw->cmq.csq.desc_num = HNS3_NIC_CMQ_DESC_NUM;
hw->cmq.crq.desc_num = HNS3_NIC_CMQ_DESC_NUM;
- /* Setup Tx write back timeout */
- hw->cmq.tx_timeout = HNS3_CMDQ_TX_TIMEOUT;
-
/* Setup queue rings */
ret = hns3_alloc_cmd_queue(hw, HNS3_TYPE_CSQ);
if (ret) {
diff --git a/drivers/net/hns3/hns3_cmd.h b/drivers/net/hns3/hns3_cmd.h
index 79a8c1edad..4d707c13b2 100644
--- a/drivers/net/hns3/hns3_cmd.h
+++ b/drivers/net/hns3/hns3_cmd.h
@@ -10,7 +10,8 @@
#include <rte_byteorder.h>
#include <rte_spinlock.h>
-#define HNS3_CMDQ_TX_TIMEOUT 30000
+#define HNS3_CMDQ_TX_TIMEOUT_DEFAULT 30000
+#define HNS3_COMQ_CFG_RST_TIMEOUT 100000
#define HNS3_CMDQ_CLEAR_WAIT_TIME 200
#define HNS3_CMDQ_RX_INVLD_B 0
#define HNS3_CMDQ_RX_OUTVLD_B 1
@@ -62,7 +63,6 @@ enum hns3_cmd_return_status {
struct hns3_cmq {
struct hns3_cmq_ring csq;
struct hns3_cmq_ring crq;
- uint16_t tx_timeout;
enum hns3_cmd_return_status last_status;
};
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.254276995 +0800
+++ 0073-net-hns3-fix-reset-timeout.patch 2025-02-18 19:39:00.698244036 +0800
@@ -1 +1 @@
-From 9f7c28c5e98062576dfbf555cd5ede7e33d6624b Mon Sep 17 00:00:00 2001
+From d6d17fcb1e2175c0a6e798c8749b06aa97948e87 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 9f7c28c5e98062576dfbf555cd5ede7e33d6624b ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -21 +23 @@
-index 146444e2fa..398b75384e 100644
+index 2c1664485b..62da6dd160 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/cpfl: fix representor parsing log' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (72 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/hns3: fix reset timeout' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'raw/cnxk_gpio: fix file descriptor leak' " Xueming Li
` (13 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=b72de1a305023ba4c040be69aff2d67593a8414b
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From b72de1a305023ba4c040be69aff2d67593a8414b Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:03 -0800
Subject: [PATCH] net/cpfl: fix representor parsing log
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 7501478b95fc79b178fc525246482215a6018651 ]
The log message would always refer to str variable which
is NULL here. Looks like author intended to print original
parameter.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: 65899b9e6538 ("net/cpfl: parse representor devargs")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/cpfl/cpfl_ethdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/cpfl/cpfl_ethdev.c b/drivers/net/cpfl/cpfl_ethdev.c
index 7697aea0ce..c24dfba575 100644
--- a/drivers/net/cpfl/cpfl_ethdev.c
+++ b/drivers/net/cpfl/cpfl_ethdev.c
@@ -1576,7 +1576,7 @@ parse_repr(const char *key __rte_unused, const char *value, void *args)
RTE_DIM(eth_da->representor_ports));
done:
if (str == NULL) {
- RTE_LOG(ERR, EAL, "wrong representor format: %s\n", str);
+ PMD_DRV_LOG(ERR, "wrong representor format: %s", value);
return -1;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.284908990 +0800
+++ 0074-net-cpfl-fix-representor-parsing-log.patch 2025-02-18 19:39:00.708244034 +0800
@@ -1 +1 @@
-From 7501478b95fc79b178fc525246482215a6018651 Mon Sep 17 00:00:00 2001
+From b72de1a305023ba4c040be69aff2d67593a8414b Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 7501478b95fc79b178fc525246482215a6018651 ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -16 +18 @@
- drivers/net/intel/cpfl/cpfl_ethdev.c | 2 +-
+ drivers/net/cpfl/cpfl_ethdev.c | 2 +-
@@ -19,5 +21,5 @@
-diff --git a/drivers/net/intel/cpfl/cpfl_ethdev.c b/drivers/net/intel/cpfl/cpfl_ethdev.c
-index 6f6707a0bd..1817221652 100644
---- a/drivers/net/intel/cpfl/cpfl_ethdev.c
-+++ b/drivers/net/intel/cpfl/cpfl_ethdev.c
-@@ -1580,7 +1580,7 @@ parse_repr(const char *key __rte_unused, const char *value, void *args)
+diff --git a/drivers/net/cpfl/cpfl_ethdev.c b/drivers/net/cpfl/cpfl_ethdev.c
+index 7697aea0ce..c24dfba575 100644
+--- a/drivers/net/cpfl/cpfl_ethdev.c
++++ b/drivers/net/cpfl/cpfl_ethdev.c
+@@ -1576,7 +1576,7 @@ parse_repr(const char *key __rte_unused, const char *value, void *args)
@@ -27 +29 @@
-- PMD_DRV_LOG(ERR, "wrong representor format: %s", str);
+- RTE_LOG(ERR, EAL, "wrong representor format: %s\n", str);
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'raw/cnxk_gpio: fix file descriptor leak' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (73 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/cpfl: fix representor parsing log' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'eal: fix devargs layers parsing out of bounds' " Xueming Li
` (12 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=377196266e55301379293a097d1b864b5d48819c
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 377196266e55301379293a097d1b864b5d48819c Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:04 -0800
Subject: [PATCH] raw/cnxk_gpio: fix file descriptor leak
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 67f0beaf0f5bf2cf239219c737ed8d93aaaaa673 ]
The function would leak file if fscanf failed.
There is a working version in other file, clone that.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: 0e6557b448fa ("raw/cnxk_gpio: add self test")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/raw/cnxk_gpio/cnxk_gpio_selftest.c | 24 ++++++++++++++--------
1 file changed, 15 insertions(+), 9 deletions(-)
diff --git a/drivers/raw/cnxk_gpio/cnxk_gpio_selftest.c b/drivers/raw/cnxk_gpio/cnxk_gpio_selftest.c
index 10742b5dc4..907535c08e 100644
--- a/drivers/raw/cnxk_gpio/cnxk_gpio_selftest.c
+++ b/drivers/raw/cnxk_gpio/cnxk_gpio_selftest.c
@@ -34,24 +34,30 @@ cnxk_gpio_attr_exists(const char *attr)
static int
cnxk_gpio_read_attr(char *attr, char *val)
{
+ int ret, ret2;
FILE *fp;
- int ret;
fp = fopen(attr, "r");
if (!fp)
return -errno;
ret = fscanf(fp, "%s", val);
- if (ret < 0)
- return -errno;
- if (ret != 1)
- return -EIO;
+ if (ret < 0) {
+ ret = -errno;
+ goto out;
+ }
+ if (ret != 1) {
+ ret = -EIO;
+ goto out;
+ }
- ret = fclose(fp);
- if (ret)
- return -errno;
+ ret = 0;
+out:
+ ret2 = fclose(fp);
+ if (!ret)
+ ret = ret2;
- return 0;
+ return ret;
}
#define CNXK_GPIO_ERR_STR(err, str, ...) do { \
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.319039184 +0800
+++ 0075-raw-cnxk_gpio-fix-file-descriptor-leak.patch 2025-02-18 19:39:00.708244034 +0800
@@ -1 +1 @@
-From 67f0beaf0f5bf2cf239219c737ed8d93aaaaa673 Mon Sep 17 00:00:00 2001
+From 377196266e55301379293a097d1b864b5d48819c Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 67f0beaf0f5bf2cf239219c737ed8d93aaaaa673 ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -20 +22 @@
-index 2f3973a7b5..a0d9942f20 100644
+index 10742b5dc4..907535c08e 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'eal: fix devargs layers parsing out of bounds' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (74 preceding siblings ...)
2025-02-18 12:35 ` patch 'raw/cnxk_gpio: fix file descriptor leak' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/qede: fix debug messages array' " Xueming Li
` (11 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=248cf72eda718248d2f6dc7380e7b4d0cfcdbfa3
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 248cf72eda718248d2f6dc7380e7b4d0cfcdbfa3 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:07 -0800
Subject: [PATCH] eal: fix devargs layers parsing out of bounds
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 42f91490ebc97a816ea11ce9c995f455c169a77a ]
The code for parsing layers in devargs could reference past
the end of layers[] array on stack.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: 9a1a9e4a2ddd ("devargs: support path value with global device syntax")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
lib/eal/common/eal_common_devargs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/eal/common/eal_common_devargs.c b/lib/eal/common/eal_common_devargs.c
index fb5d0a293b..2f1515d7c9 100644
--- a/lib/eal/common/eal_common_devargs.c
+++ b/lib/eal/common/eal_common_devargs.c
@@ -88,7 +88,7 @@ rte_devargs_layers_parse(struct rte_devargs *devargs,
s = devargs->data;
while (s != NULL) {
- if (nblayer > RTE_DIM(layers)) {
+ if (nblayer >= RTE_DIM(layers)) {
ret = -E2BIG;
goto get_out;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.349516179 +0800
+++ 0076-eal-fix-devargs-layers-parsing-out-of-bounds.patch 2025-02-18 19:39:00.708244034 +0800
@@ -1 +1 @@
-From 42f91490ebc97a816ea11ce9c995f455c169a77a Mon Sep 17 00:00:00 2001
+From 248cf72eda718248d2f6dc7380e7b4d0cfcdbfa3 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 42f91490ebc97a816ea11ce9c995f455c169a77a ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -20 +22 @@
-index a64805b268..dd857fc839 100644
+index fb5d0a293b..2f1515d7c9 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/qede: fix debug messages array' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (75 preceding siblings ...)
2025-02-18 12:35 ` patch 'eal: fix devargs layers parsing out of bounds' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/hinic: fix flow type bitmask overflow' " Xueming Li
` (10 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=2ee76ce24899848a129be04a7d77024f64ed340c
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 2ee76ce24899848a129be04a7d77024f64ed340c Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:08 -0800
Subject: [PATCH] net/qede: fix debug messages array
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 60c68da0392e31ea4c163e0be8f1236a00cd350c ]
The array of debug status strings did not match possible enum
values. Add the missing element and a static assert to make sure
the table has all possible values.
For more complete description see.
Link: https://pvs-studio.com/en/blog/posts/cpp/1176/
Fixes: ec55c118792b ("net/qede: add infrastructure for debug data collection")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/qede/qede_debug.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/qede/qede_debug.c b/drivers/net/qede/qede_debug.c
index 18f2d988fb..1d3147b724 100644
--- a/drivers/net/qede/qede_debug.c
+++ b/drivers/net/qede/qede_debug.c
@@ -4,6 +4,7 @@
* www.marvell.com
*/
+#include <assert.h>
#include <rte_common.h>
#include "base/bcm_osal.h"
#include "base/ecore.h"
@@ -82,6 +83,7 @@ static const char * const s_mem_group_names[] = {
"TM_MEM",
"TASK_CFC_MEM",
};
+static_assert(RTE_DIM(s_mem_group_names) == MEM_GROUPS_NUM, "memory group string mismatch");
/* Idle check conditions */
@@ -5614,6 +5616,8 @@ static const char * const s_status_str[] = {
/* DBG_STATUS_INVALID_FILTER_TRIGGER_DWORDS */
"The filter/trigger constraint dword offsets are not enabled for recording",
+ /* DBG_STATUS_NO_MATCHING_FRAMING_MODE */
+ "No matching frame mode",
/* DBG_STATUS_VFC_READ_ERROR */
"Error reading from VFC",
@@ -5759,6 +5763,7 @@ static const char * const s_status_str[] = {
/* DBG_STATUS_MISSING_TRIGGER_STATE_STORM */
"When triggering on Storm data, the Storm to trigger on must be specified"
};
+static_assert(RTE_DIM(s_status_str) == MAX_DBG_STATUS, "status string table mismatch");
/* Idle check severity names array */
static const char * const s_idle_chk_severity_str[] = {
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.380524874 +0800
+++ 0077-net-qede-fix-debug-messages-array.patch 2025-02-18 19:39:00.708244034 +0800
@@ -1 +1 @@
-From 60c68da0392e31ea4c163e0be8f1236a00cd350c Mon Sep 17 00:00:00 2001
+From 2ee76ce24899848a129be04a7d77024f64ed340c Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 60c68da0392e31ea4c163e0be8f1236a00cd350c ]
@@ -14 +16,0 @@
-Cc: stable@dpdk.org
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/hinic: fix flow type bitmask overflow' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (76 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/qede: fix debug messages array' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'crypto/dpaa2_sec: fix bitmask truncation' " Xueming Li
` (9 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c7fe575456e57cd305d332209e0944f664877746
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From c7fe575456e57cd305d332209e0944f664877746 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:12 -0800
Subject: [PATCH] net/hinic: fix flow type bitmask overflow
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit a357d5b703253b5920aba808a24877386a22720e ]
The type mask is 64 bit value, doing a shift of literal 1 (32 bit)
will result in int type (32 bit) and cause truncation.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: f4ca3fd54c4d ("net/hinic: create and destroy flow director filter")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/hinic/hinic_pmd_flow.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/net/hinic/hinic_pmd_flow.c b/drivers/net/hinic/hinic_pmd_flow.c
index d1a564a163..9441525aa2 100644
--- a/drivers/net/hinic/hinic_pmd_flow.c
+++ b/drivers/net/hinic/hinic_pmd_flow.c
@@ -1979,8 +1979,8 @@ static int hinic_lookup_new_filter(struct hinic_5tuple_filter *filter,
return -EINVAL;
}
- if (!(filter_info->type_mask & (1 << type_id))) {
- filter_info->type_mask |= 1 << type_id;
+ if (!(filter_info->type_mask & (UINT64_C(1) << type_id))) {
+ filter_info->type_mask |= UINT64_C(1) << type_id;
filter->index = type_id;
filter_info->pkt_filters[type_id].enable = true;
filter_info->pkt_filters[type_id].pkt_proto =
@@ -2138,7 +2138,7 @@ static void hinic_remove_5tuple_filter(struct rte_eth_dev *dev,
filter_info->pkt_type = 0;
filter_info->qid = 0;
filter_info->pkt_filters[filter->index].qid = 0;
- filter_info->type_mask &= ~(1 << (filter->index));
+ filter_info->type_mask &= ~(UINT64_C(1) << filter->index);
TAILQ_REMOVE(&filter_info->fivetuple_list, filter, entries);
rte_free(filter);
@@ -2268,8 +2268,8 @@ hinic_ethertype_filter_insert(struct hinic_filter_info *filter_info,
if (id < 0)
return -EINVAL;
- if (!(filter_info->type_mask & (1 << id))) {
- filter_info->type_mask |= 1 << id;
+ if (!(filter_info->type_mask & (UINT64_C(1) << id))) {
+ filter_info->type_mask |= UINT64_C(1) << id;
filter_info->pkt_filters[id].pkt_proto =
ethertype_filter->pkt_proto;
filter_info->pkt_filters[id].enable = ethertype_filter->enable;
@@ -2289,7 +2289,7 @@ hinic_ethertype_filter_remove(struct hinic_filter_info *filter_info,
return;
filter_info->pkt_type = 0;
- filter_info->type_mask &= ~(1 << idx);
+ filter_info->type_mask &= ~(UINT64_C(1) << idx);
filter_info->pkt_filters[idx].pkt_proto = (uint16_t)0;
filter_info->pkt_filters[idx].enable = FALSE;
filter_info->pkt_filters[idx].qid = 0;
@@ -2355,7 +2355,7 @@ hinic_add_del_ethertype_filter(struct rte_eth_dev *dev,
if (i < 0)
return -EINVAL;
- if ((filter_info->type_mask & (1 << i))) {
+ if ((filter_info->type_mask & (UINT64_C(1) << i))) {
filter_info->pkt_filters[i].enable = FALSE;
(void)hinic_set_fdir_filter(nic_dev->hwdev,
filter_info->pkt_type,
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.416644567 +0800
+++ 0078-net-hinic-fix-flow-type-bitmask-overflow.patch 2025-02-18 19:39:00.718244032 +0800
@@ -1 +1 @@
-From a357d5b703253b5920aba808a24877386a22720e Mon Sep 17 00:00:00 2001
+From c7fe575456e57cd305d332209e0944f664877746 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit a357d5b703253b5920aba808a24877386a22720e ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
@@ -19 +21 @@
-index 8fdd5a35be..6b1ca6ff88 100644
+index d1a564a163..9441525aa2 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'crypto/dpaa2_sec: fix bitmask truncation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (77 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/hinic: fix flow type bitmask overflow' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'crypto/dpaa_sec: " Xueming Li
` (8 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, Hemant Agrawal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=ea50d3b95bb31fb24e608b3c9bb4811c7c5b2f54
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From ea50d3b95bb31fb24e608b3c9bb4811c7c5b2f54 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:13 -0800
Subject: [PATCH] crypto/dpaa2_sec: fix bitmask truncation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 013ddc85bff5fdb85eb6006315ebdaa0c12eeece ]
The dqrr_held mask is 64 bit but updates were getting truncated
because 1 is of type int (32 bit) and the result shift of int is of
type int (32 bit); therefore any value >= 32 would get truncated.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: a77db24643b7 ("crypto/dpaa2_sec: support atomic queues")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
index bd5590c02d..b9826c4fcf 100644
--- a/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
+++ b/drivers/crypto/dpaa2_sec/dpaa2_sec_dpseci.c
@@ -1461,8 +1461,8 @@ dpaa2_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
if (*dpaa2_seqn((*ops)->sym->m_src)) {
if (*dpaa2_seqn((*ops)->sym->m_src) & QBMAN_ENQUEUE_FLAG_DCA) {
DPAA2_PER_LCORE_DQRR_SIZE--;
- DPAA2_PER_LCORE_DQRR_HELD &= ~(1 <<
- *dpaa2_seqn((*ops)->sym->m_src) &
+ DPAA2_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) <<
+ *dpaa2_seqn((*ops)->sym->m_src) &
QBMAN_EQCR_DCA_IDXMASK);
}
flags[loop] = *dpaa2_seqn((*ops)->sym->m_src);
@@ -1751,7 +1751,7 @@ dpaa2_sec_set_enqueue_descriptor(struct dpaa2_queue *dpaa2_q,
dq_idx = *dpaa2_seqn(m) - 1;
qbman_eq_desc_set_dca(eqdesc, 1, dq_idx, 0);
DPAA2_PER_LCORE_DQRR_SIZE--;
- DPAA2_PER_LCORE_DQRR_HELD &= ~(1 << dq_idx);
+ DPAA2_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << dq_idx);
}
*dpaa2_seqn(m) = DPAA2_INVALID_MBUF_SEQN;
}
@@ -4051,7 +4051,7 @@ dpaa2_sec_process_atomic_event(struct qbman_swp *swp __rte_unused,
dqrr_index = qbman_get_dqrr_idx(dq);
*dpaa2_seqn(crypto_op->sym->m_src) = QBMAN_ENQUEUE_FLAG_DCA | dqrr_index;
DPAA2_PER_LCORE_DQRR_SIZE++;
- DPAA2_PER_LCORE_DQRR_HELD |= 1 << dqrr_index;
+ DPAA2_PER_LCORE_DQRR_HELD |= UINT64_C(1) << dqrr_index;
DPAA2_PER_LCORE_DQRR_MBUF(dqrr_index) = crypto_op->sym->m_src;
ev->event_ptr = crypto_op;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.449900662 +0800
+++ 0079-crypto-dpaa2_sec-fix-bitmask-truncation.patch 2025-02-18 19:39:00.718244032 +0800
@@ -1 +1 @@
-From 013ddc85bff5fdb85eb6006315ebdaa0c12eeece Mon Sep 17 00:00:00 2001
+From ea50d3b95bb31fb24e608b3c9bb4811c7c5b2f54 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 013ddc85bff5fdb85eb6006315ebdaa0c12eeece ]
@@ -12 +14,0 @@
-Cc: stable@dpdk.org
@@ -21 +23 @@
-index ec6577f64c..7ad8fd47dd 100644
+index bd5590c02d..b9826c4fcf 100644
@@ -24 +26 @@
-@@ -1491,8 +1491,8 @@ dpaa2_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
+@@ -1461,8 +1461,8 @@ dpaa2_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
@@ -35 +37 @@
-@@ -1772,7 +1772,7 @@ dpaa2_sec_set_enqueue_descriptor(struct dpaa2_queue *dpaa2_q,
+@@ -1751,7 +1751,7 @@ dpaa2_sec_set_enqueue_descriptor(struct dpaa2_queue *dpaa2_q,
@@ -44 +46 @@
-@@ -4055,7 +4055,7 @@ dpaa2_sec_process_atomic_event(struct qbman_swp *swp __rte_unused,
+@@ -4051,7 +4051,7 @@ dpaa2_sec_process_atomic_event(struct qbman_swp *swp __rte_unused,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'crypto/dpaa_sec: fix bitmask truncation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (78 preceding siblings ...)
2025-02-18 12:35 ` patch 'crypto/dpaa2_sec: fix bitmask truncation' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'event/dpaa: " Xueming Li
` (7 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, Hemant Agrawal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=2327043ff494d807aaaec57f42b2c5d78389c8a7
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 2327043ff494d807aaaec57f42b2c5d78389c8a7 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:14 -0800
Subject: [PATCH] crypto/dpaa_sec: fix bitmask truncation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 7c18f573c1f5368f70e6e956c4ba0c6f97b19cb1 ]
The dqrr_held mask is 64 bit but updates were getting truncated
because 1 is of type int (32 bit) and the result shift of int is of
type int (32 bit); therefore any value >= 32 would get truncated.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: fe3688ba7950 ("crypto/dpaa_sec: support event crypto adapter")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
drivers/crypto/dpaa_sec/dpaa_sec.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/dpaa_sec/dpaa_sec.c b/drivers/crypto/dpaa_sec/dpaa_sec.c
index 131cd90c94..502e4fbed1 100644
--- a/drivers/crypto/dpaa_sec/dpaa_sec.c
+++ b/drivers/crypto/dpaa_sec/dpaa_sec.c
@@ -1903,13 +1903,12 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
op = *(ops++);
if (*dpaa_seqn(op->sym->m_src) != 0) {
index = *dpaa_seqn(op->sym->m_src) - 1;
- if (DPAA_PER_LCORE_DQRR_HELD & (1 << index)) {
+ if (DPAA_PER_LCORE_DQRR_HELD & (UINT64_C(1) << index)) {
/* QM_EQCR_DCA_IDXMASK = 0x0f */
flags[loop] = ((index & 0x0f) << 8);
flags[loop] |= QMAN_ENQUEUE_FLAG_DCA;
DPAA_PER_LCORE_DQRR_SIZE--;
- DPAA_PER_LCORE_DQRR_HELD &=
- ~(1 << index);
+ DPAA_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << index);
}
}
@@ -3447,7 +3446,7 @@ dpaa_sec_process_atomic_event(void *event,
/* Save active dqrr entries */
index = ((uintptr_t)dqrr >> 6) & (16/*QM_DQRR_SIZE*/ - 1);
DPAA_PER_LCORE_DQRR_SIZE++;
- DPAA_PER_LCORE_DQRR_HELD |= 1 << index;
+ DPAA_PER_LCORE_DQRR_HELD |= UINT64_C(1) << index;
DPAA_PER_LCORE_DQRR_MBUF(index) = ctx->op->sym->m_src;
ev->impl_opaque = index + 1;
*dpaa_seqn(ctx->op->sym->m_src) = (uint32_t)index + 1;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.484912756 +0800
+++ 0080-crypto-dpaa_sec-fix-bitmask-truncation.patch 2025-02-18 19:39:00.718244032 +0800
@@ -1 +1 @@
-From 7c18f573c1f5368f70e6e956c4ba0c6f97b19cb1 Mon Sep 17 00:00:00 2001
+From 2327043ff494d807aaaec57f42b2c5d78389c8a7 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 7c18f573c1f5368f70e6e956c4ba0c6f97b19cb1 ]
@@ -13 +15,0 @@
-Cc: stable@dpdk.org
@@ -22 +24 @@
-index 3fa88ca968..e117cd77a6 100644
+index 131cd90c94..502e4fbed1 100644
@@ -25 +27 @@
-@@ -1907,13 +1907,12 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
+@@ -1903,13 +1903,12 @@ dpaa_sec_enqueue_burst(void *qp, struct rte_crypto_op **ops,
@@ -41 +43 @@
-@@ -3500,7 +3499,7 @@ dpaa_sec_process_atomic_event(void *event,
+@@ -3447,7 +3446,7 @@ dpaa_sec_process_atomic_event(void *event,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'event/dpaa: fix bitmask truncation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (79 preceding siblings ...)
2025-02-18 12:35 ` patch 'crypto/dpaa_sec: " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/dpaa: " Xueming Li
` (6 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, Hemant Agrawal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=0c943314f2fb50d446cbe0635816d3f68fc5e3d4
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 0c943314f2fb50d446cbe0635816d3f68fc5e3d4 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:15 -0800
Subject: [PATCH] event/dpaa: fix bitmask truncation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit a82888ed6edc599f82263a1bd067a7edb7cceeee ]
More bitmask truncation from mask computation.
Fixes: 0ee17f79ebd0 ("event/dpaa: add enqueue/dequeue")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
drivers/event/dpaa/dpaa_eventdev.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/event/dpaa/dpaa_eventdev.c b/drivers/event/dpaa/dpaa_eventdev.c
index 46a9b88c73..6b931e8054 100644
--- a/drivers/event/dpaa/dpaa_eventdev.c
+++ b/drivers/event/dpaa/dpaa_eventdev.c
@@ -101,7 +101,7 @@ dpaa_event_enqueue_burst(void *port, const struct rte_event ev[],
qman_dca_index(ev[i].impl_opaque, 0);
mbuf = DPAA_PER_LCORE_DQRR_MBUF(i);
*dpaa_seqn(mbuf) = DPAA_INVALID_MBUF_SEQN;
- DPAA_PER_LCORE_DQRR_HELD &= ~(1 << i);
+ DPAA_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << i);
DPAA_PER_LCORE_DQRR_SIZE--;
break;
default:
@@ -204,11 +204,11 @@ dpaa_event_dequeue_burst(void *port, struct rte_event ev[],
/* Check if there are atomic contexts to be released */
i = 0;
while (DPAA_PER_LCORE_DQRR_SIZE) {
- if (DPAA_PER_LCORE_DQRR_HELD & (1 << i)) {
+ if (DPAA_PER_LCORE_DQRR_HELD & (UINT64_C(1) << i)) {
qman_dca_index(i, 0);
mbuf = DPAA_PER_LCORE_DQRR_MBUF(i);
*dpaa_seqn(mbuf) = DPAA_INVALID_MBUF_SEQN;
- DPAA_PER_LCORE_DQRR_HELD &= ~(1 << i);
+ DPAA_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << i);
DPAA_PER_LCORE_DQRR_SIZE--;
}
i++;
@@ -274,11 +274,11 @@ dpaa_event_dequeue_burst_intr(void *port, struct rte_event ev[],
/* Check if there are atomic contexts to be released */
i = 0;
while (DPAA_PER_LCORE_DQRR_SIZE) {
- if (DPAA_PER_LCORE_DQRR_HELD & (1 << i)) {
+ if (DPAA_PER_LCORE_DQRR_HELD & (UINT64_C(1) << i)) {
qman_dca_index(i, 0);
mbuf = DPAA_PER_LCORE_DQRR_MBUF(i);
*dpaa_seqn(mbuf) = DPAA_INVALID_MBUF_SEQN;
- DPAA_PER_LCORE_DQRR_HELD &= ~(1 << i);
+ DPAA_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << i);
DPAA_PER_LCORE_DQRR_SIZE--;
}
i++;
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.517993150 +0800
+++ 0081-event-dpaa-fix-bitmask-truncation.patch 2025-02-18 19:39:00.728244030 +0800
@@ -1 +1 @@
-From a82888ed6edc599f82263a1bd067a7edb7cceeee Mon Sep 17 00:00:00 2001
+From 0c943314f2fb50d446cbe0635816d3f68fc5e3d4 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit a82888ed6edc599f82263a1bd067a7edb7cceeee ]
@@ -9 +11,0 @@
-Cc: stable@dpdk.org
@@ -18 +20 @@
-index 853cc1ecf9..400e0ecd1c 100644
+index 46a9b88c73..6b931e8054 100644
@@ -21 +23 @@
-@@ -102,7 +102,7 @@ dpaa_event_enqueue_burst(void *port, const struct rte_event ev[],
+@@ -101,7 +101,7 @@ dpaa_event_enqueue_burst(void *port, const struct rte_event ev[],
@@ -30 +32 @@
-@@ -199,11 +199,11 @@ dpaa_event_dequeue_burst(void *port, struct rte_event ev[],
+@@ -204,11 +204,11 @@ dpaa_event_dequeue_burst(void *port, struct rte_event ev[],
@@ -44 +46 @@
-@@ -263,11 +263,11 @@ dpaa_event_dequeue_burst_intr(void *port, struct rte_event ev[],
+@@ -274,11 +274,11 @@ dpaa_event_dequeue_burst_intr(void *port, struct rte_event ev[],
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/dpaa: fix bitmask truncation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (80 preceding siblings ...)
2025-02-18 12:35 ` patch 'event/dpaa: " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/dpaa2: " Xueming Li
` (5 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, Hemant Agrawal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=e32bf2b78128db48cfff0aa83e18a301e649ce5a
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From e32bf2b78128db48cfff0aa83e18a301e649ce5a Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:16 -0800
Subject: [PATCH] net/dpaa: fix bitmask truncation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 8f64c187ad8e4e0b953439b2ce92d8573721eda3 ]
The dqrr_held mask is 64 bit but updates were getting truncated
because 1 is of type int (32 bit) and the result shift of int is of
type int (32 bit); therefore any value >= 32 would get truncated.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: 5e7455931442 ("net/dpaa: support Rx queue configurations with eventdev")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
drivers/net/dpaa/dpaa_rxtx.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/net/dpaa/dpaa_rxtx.c b/drivers/net/dpaa/dpaa_rxtx.c
index 018d55bbdc..31412c0715 100644
--- a/drivers/net/dpaa/dpaa_rxtx.c
+++ b/drivers/net/dpaa/dpaa_rxtx.c
@@ -683,7 +683,7 @@ dpaa_rx_cb_atomic(void *event,
/* Save active dqrr entries */
index = DQRR_PTR2IDX(dqrr);
DPAA_PER_LCORE_DQRR_SIZE++;
- DPAA_PER_LCORE_DQRR_HELD |= 1 << index;
+ DPAA_PER_LCORE_DQRR_HELD |= UINT64_C(1) << index;
DPAA_PER_LCORE_DQRR_MBUF(index) = mbuf;
ev->impl_opaque = index + 1;
*dpaa_seqn(mbuf) = (uint32_t)index + 1;
@@ -1108,13 +1108,12 @@ dpaa_eth_queue_tx(void *q, struct rte_mbuf **bufs, uint16_t nb_bufs)
seqn = *dpaa_seqn(mbuf);
if (seqn != DPAA_INVALID_MBUF_SEQN) {
index = seqn - 1;
- if (DPAA_PER_LCORE_DQRR_HELD & (1 << index)) {
+ if (DPAA_PER_LCORE_DQRR_HELD & (UINT64_C(1) << index)) {
flags[loop] =
((index & QM_EQCR_DCA_IDXMASK) << 8);
flags[loop] |= QMAN_ENQUEUE_FLAG_DCA;
DPAA_PER_LCORE_DQRR_SIZE--;
- DPAA_PER_LCORE_DQRR_HELD &=
- ~(1 << index);
+ DPAA_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << index);
}
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.549323745 +0800
+++ 0082-net-dpaa-fix-bitmask-truncation.patch 2025-02-18 19:39:00.728244030 +0800
@@ -1 +1 @@
-From 8f64c187ad8e4e0b953439b2ce92d8573721eda3 Mon Sep 17 00:00:00 2001
+From e32bf2b78128db48cfff0aa83e18a301e649ce5a Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 8f64c187ad8e4e0b953439b2ce92d8573721eda3 ]
@@ -13 +15,0 @@
-Cc: stable@dpdk.org
@@ -22 +24 @@
-index 247e7b92ba..05bd73becf 100644
+index 018d55bbdc..31412c0715 100644
@@ -25 +27 @@
-@@ -842,7 +842,7 @@ dpaa_rx_cb_atomic(void *event,
+@@ -683,7 +683,7 @@ dpaa_rx_cb_atomic(void *event,
@@ -34 +36 @@
-@@ -1338,13 +1338,12 @@ dpaa_eth_queue_tx(void *q, struct rte_mbuf **bufs, uint16_t nb_bufs)
+@@ -1108,13 +1108,12 @@ dpaa_eth_queue_tx(void *q, struct rte_mbuf **bufs, uint16_t nb_bufs)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/dpaa2: fix bitmask truncation' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (81 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/dpaa: " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'net/qede: fix nested loops' " Xueming Li
` (4 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, Hemant Agrawal, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=6fc5a6901a4ee4a9ccb5ce242c20e4fc4b7a0c36
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 6fc5a6901a4ee4a9ccb5ce242c20e4fc4b7a0c36 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:17 -0800
Subject: [PATCH] net/dpaa2: fix bitmask truncation
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit e4591c38b50e23fc6ac6b73803e78d49142ecf57 ]
The dqrr_held mask is 64 bit but updates were getting truncated
because 1 is of type int (32 bit) and the result shift of int is of
type int (32 bit); therefore any value >= 32 would get truncated.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: 2d3788631862 ("net/dpaa2: support atomic queues")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
drivers/net/dpaa2/dpaa2_rxtx.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/net/dpaa2/dpaa2_rxtx.c b/drivers/net/dpaa2/dpaa2_rxtx.c
index b64232b88f..f65603aa09 100644
--- a/drivers/net/dpaa2/dpaa2_rxtx.c
+++ b/drivers/net/dpaa2/dpaa2_rxtx.c
@@ -923,7 +923,7 @@ dpaa2_dev_process_atomic_event(struct qbman_swp *swp __rte_unused,
dqrr_index = qbman_get_dqrr_idx(dq);
*dpaa2_seqn(ev->mbuf) = dqrr_index + 1;
DPAA2_PER_LCORE_DQRR_SIZE++;
- DPAA2_PER_LCORE_DQRR_HELD |= 1 << dqrr_index;
+ DPAA2_PER_LCORE_DQRR_HELD |= UINT64_C(1) << dqrr_index;
DPAA2_PER_LCORE_DQRR_MBUF(dqrr_index) = ev->mbuf;
}
@@ -1304,7 +1304,7 @@ dpaa2_dev_tx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
flags[loop] = QBMAN_ENQUEUE_FLAG_DCA |
dqrr_index;
DPAA2_PER_LCORE_DQRR_SIZE--;
- DPAA2_PER_LCORE_DQRR_HELD &= ~(1 << dqrr_index);
+ DPAA2_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << dqrr_index);
*dpaa2_seqn(*bufs) = DPAA2_INVALID_MBUF_SEQN;
}
@@ -1543,7 +1543,7 @@ dpaa2_set_enqueue_descriptor(struct dpaa2_queue *dpaa2_q,
dq_idx = *dpaa2_seqn(m) - 1;
qbman_eq_desc_set_dca(eqdesc, 1, dq_idx, 0);
DPAA2_PER_LCORE_DQRR_SIZE--;
- DPAA2_PER_LCORE_DQRR_HELD &= ~(1 << dq_idx);
+ DPAA2_PER_LCORE_DQRR_HELD &= ~(UINT64_C(1) << dq_idx);
}
*dpaa2_seqn(m) = DPAA2_INVALID_MBUF_SEQN;
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.581705839 +0800
+++ 0083-net-dpaa2-fix-bitmask-truncation.patch 2025-02-18 19:39:00.728244030 +0800
@@ -1 +1 @@
-From e4591c38b50e23fc6ac6b73803e78d49142ecf57 Mon Sep 17 00:00:00 2001
+From 6fc5a6901a4ee4a9ccb5ce242c20e4fc4b7a0c36 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit e4591c38b50e23fc6ac6b73803e78d49142ecf57 ]
@@ -13 +15,0 @@
-Cc: stable@dpdk.org
@@ -22 +24 @@
-index bfb5542bbc..cad15d8f75 100644
+index b64232b88f..f65603aa09 100644
@@ -25 +27 @@
-@@ -933,7 +933,7 @@ dpaa2_dev_process_atomic_event(struct qbman_swp *swp __rte_unused,
+@@ -923,7 +923,7 @@ dpaa2_dev_process_atomic_event(struct qbman_swp *swp __rte_unused,
@@ -34 +36 @@
-@@ -1317,7 +1317,7 @@ dpaa2_dev_tx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
+@@ -1304,7 +1304,7 @@ dpaa2_dev_tx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
@@ -43 +45 @@
-@@ -1575,7 +1575,7 @@ dpaa2_set_enqueue_descriptor(struct dpaa2_queue *dpaa2_q,
+@@ -1543,7 +1543,7 @@ dpaa2_set_enqueue_descriptor(struct dpaa2_queue *dpaa2_q,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'net/qede: fix nested loops' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (82 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/dpaa2: " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'examples/l3fwd: fix socket ID check' " Xueming Li
` (3 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=14ee2e354918873110f7d602138c08fceff0f485
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 14ee2e354918873110f7d602138c08fceff0f485 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:18 -0800
Subject: [PATCH] net/qede: fix nested loops
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit c8b3833965dc84914e94776cadfc8fb48c34459b ]
Using variable in outer loop, and inner loop is obvious bug.
This bug is in base code, so likely on other platforms as well.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: 81dba2b2ff61 ("net/qede/base: add LLDP support")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/qede/base/ecore_dcbx.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/net/qede/base/ecore_dcbx.c b/drivers/net/qede/base/ecore_dcbx.c
index 31234f18cf..72bbedd65a 100644
--- a/drivers/net/qede/base/ecore_dcbx.c
+++ b/drivers/net/qede/base/ecore_dcbx.c
@@ -1363,7 +1363,7 @@ ecore_lldp_mib_update_event(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt)
struct ecore_dcbx_mib_meta_data data;
enum _ecore_status_t rc = ECORE_SUCCESS;
struct lldp_received_tlvs_s tlvs;
- int i;
+ int i, j;
for (i = 0; i < LLDP_MAX_LLDP_AGENTS; i++) {
OSAL_MEM_ZERO(&data, sizeof(data));
@@ -1381,9 +1381,9 @@ ecore_lldp_mib_update_event(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt)
if (!tlvs.length)
continue;
- for (i = 0; i < MAX_TLV_BUFFER; i++)
- tlvs.tlvs_buffer[i] =
- OSAL_CPU_TO_BE32(tlvs.tlvs_buffer[i]);
+ for (j = 0; j < MAX_TLV_BUFFER; j++)
+ tlvs.tlvs_buffer[j] =
+ OSAL_CPU_TO_BE32(tlvs.tlvs_buffer[j]);
OSAL_LLDP_RX_TLVS(p_hwfn, tlvs.tlvs_buffer, tlvs.length);
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.613071934 +0800
+++ 0084-net-qede-fix-nested-loops.patch 2025-02-18 19:39:00.728244030 +0800
@@ -1 +1 @@
-From c8b3833965dc84914e94776cadfc8fb48c34459b Mon Sep 17 00:00:00 2001
+From 14ee2e354918873110f7d602138c08fceff0f485 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit c8b3833965dc84914e94776cadfc8fb48c34459b ]
@@ -11 +13,0 @@
-Cc: stable@dpdk.org
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'examples/l3fwd: fix socket ID check' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (83 preceding siblings ...)
2025-02-18 12:35 ` patch 'net/qede: fix nested loops' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'common/cnxk: fix null " Xueming Li
` (2 subsequent siblings)
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=69dc0d8ed261b364449f78cb1ad2e727e0c3fc10
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 69dc0d8ed261b364449f78cb1ad2e727e0c3fc10 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:19 -0800
Subject: [PATCH] examples/l3fwd: fix socket ID check
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit a7216f081767c7259dd3fba5eda0ca7b0bcb4595 ]
The expression:
if ((socketid = rte_lcore_to_socket_id(lcore) != 0) &&
gets evaluated as socketid = (rte_lcore_to_socket_id(lcore) != 0)
which is not what was intended. This is goes all the way back
to first release.
Link: https://pvs-studio.com/en/blog/posts/cpp/1183/
Fixes: af75078fece3 ("first public release")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
examples/l3fwd-power/main.c | 4 ++--
examples/l3fwd/main.c | 5 +++--
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/examples/l3fwd-power/main.c b/examples/l3fwd-power/main.c
index 7640b5a9a3..b11336e0b9 100644
--- a/examples/l3fwd-power/main.c
+++ b/examples/l3fwd-power/main.c
@@ -1411,8 +1411,8 @@ check_lcore_params(void)
"mask\n", lcore);
return -1;
}
- if ((socketid = rte_lcore_to_socket_id(lcore) != 0) &&
- (numa_on == 0)) {
+ socketid = rte_lcore_to_socket_id(lcore);
+ if (socketid != 0 && numa_on == 0) {
printf("warning: lcore %u is on socket %d with numa "
"off\n", lcore, socketid);
}
diff --git a/examples/l3fwd/main.c b/examples/l3fwd/main.c
index a239869ada..56d295d76f 100644
--- a/examples/l3fwd/main.c
+++ b/examples/l3fwd/main.c
@@ -307,8 +307,9 @@ check_lcore_params(void)
printf("error: lcore %u is not enabled in lcore mask\n", lcore);
return -1;
}
- if ((socketid = rte_lcore_to_socket_id(lcore) != 0) &&
- (numa_on == 0)) {
+
+ socketid = rte_lcore_to_socket_id(lcore);
+ if (socketid != 0 && numa_on == 0) {
printf("warning: lcore %u is on socket %d with numa off\n",
lcore, socketid);
}
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.643829128 +0800
+++ 0085-examples-l3fwd-fix-socket-ID-check.patch 2025-02-18 19:39:00.738244029 +0800
@@ -1 +1 @@
-From a7216f081767c7259dd3fba5eda0ca7b0bcb4595 Mon Sep 17 00:00:00 2001
+From 69dc0d8ed261b364449f78cb1ad2e727e0c3fc10 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit a7216f081767c7259dd3fba5eda0ca7b0bcb4595 ]
@@ -16 +18,0 @@
-Cc: stable@dpdk.org
@@ -25 +27 @@
-index d279e664b3..e27b8531b5 100644
+index 7640b5a9a3..b11336e0b9 100644
@@ -28 +30 @@
-@@ -1412,8 +1412,8 @@ check_lcore_params(void)
+@@ -1411,8 +1411,8 @@ check_lcore_params(void)
@@ -40 +42 @@
-index 994b7dd8e5..ae3b4f6439 100644
+index a239869ada..56d295d76f 100644
@@ -43 +45 @@
-@@ -311,8 +311,9 @@ check_lcore_params(void)
+@@ -307,8 +307,9 @@ check_lcore_params(void)
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'common/cnxk: fix null check' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (84 preceding siblings ...)
2025-02-18 12:35 ` patch 'examples/l3fwd: fix socket ID check' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'eal/linux: remove useless assignments' " Xueming Li
2025-02-18 12:35 ` patch 'mempool: fix errno in empty create' " Xueming Li
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=b1f0f150ca2f9fc29c9a6f1607fb432deb320869
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From b1f0f150ca2f9fc29c9a6f1607fb432deb320869 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 5 Feb 2025 08:23:20 -0800
Subject: [PATCH] common/cnxk: fix null check
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 1bab0289c6a58c3847ffbde2718b73a9b988deca ]
The pointer mode is used then checked which is a bug reported
by PVS studio.
Fixes: bd2fd34ab86f ("common/cnxk: sync eth mode change command with firmware")
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/common/cnxk/roc_bphy_cgx.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/common/cnxk/roc_bphy_cgx.c b/drivers/common/cnxk/roc_bphy_cgx.c
index e966494e21..3d674dbe84 100644
--- a/drivers/common/cnxk/roc_bphy_cgx.c
+++ b/drivers/common/cnxk/roc_bphy_cgx.c
@@ -364,20 +364,20 @@ roc_bphy_cgx_set_link_mode(struct roc_bphy_cgx *roc_cgx, unsigned int lmac,
{
uint64_t scr1, scr0;
+ if (!mode)
+ return -EINVAL;
+
+ if (!roc_cgx)
+ return -EINVAL;
+
if (roc_model_is_cn9k() &&
(mode->use_portm_idx || mode->portm_idx || mode->mode_group_idx)) {
return -ENOTSUP;
}
- if (!roc_cgx)
- return -EINVAL;
-
if (!roc_bphy_cgx_lmac_exists(roc_cgx, lmac))
return -ENODEV;
- if (!mode)
- return -EINVAL;
-
scr1 = FIELD_PREP(SCR1_ETH_CMD_ID, ETH_CMD_MODE_CHANGE) |
FIELD_PREP(SCR1_ETH_MODE_CHANGE_ARGS_SPEED, mode->speed) |
FIELD_PREP(SCR1_ETH_MODE_CHANGE_ARGS_DUPLEX, mode->full_duplex) |
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.674812223 +0800
+++ 0086-common-cnxk-fix-null-check.patch 2025-02-18 19:39:00.738244029 +0800
@@ -1 +1 @@
-From 1bab0289c6a58c3847ffbde2718b73a9b988deca Mon Sep 17 00:00:00 2001
+From b1f0f150ca2f9fc29c9a6f1607fb432deb320869 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 1bab0289c6a58c3847ffbde2718b73a9b988deca ]
@@ -10 +12,0 @@
-Cc: stable@dpdk.org
@@ -18 +20 @@
-index 882cf65474..db70bafd9b 100644
+index e966494e21..3d674dbe84 100644
@@ -21 +23 @@
-@@ -366,20 +366,20 @@ roc_bphy_cgx_set_link_mode(struct roc_bphy_cgx *roc_cgx, unsigned int lmac,
+@@ -364,20 +364,20 @@ roc_bphy_cgx_set_link_mode(struct roc_bphy_cgx *roc_cgx, unsigned int lmac,
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'eal/linux: remove useless assignments' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (85 preceding siblings ...)
2025-02-18 12:35 ` patch 'common/cnxk: fix null " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
2025-02-18 12:35 ` patch 'mempool: fix errno in empty create' " Xueming Li
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Ariel Otilibili; +Cc: xuemingl, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=2a8873d4ce501d6c623ed204b04d34f54d8c91a9
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 2a8873d4ce501d6c623ed204b04d34f54d8c91a9 Mon Sep 17 00:00:00 2001
From: Ariel Otilibili <ariel.otilibili@6wind.com>
Date: Mon, 13 Jan 2025 18:19:20 +0100
Subject: [PATCH] eal/linux: remove useless assignments
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit 36128ec5d93591700b72f3fc01bfe6216eaee905 ]
Found by static analysis:
In dev_uev_socket_fd_create(), fd is assigned before a return,
and not used.
The same for the variables buf and i in dev_uev_parse().
Fixes: c2bd9367e18f ("lib: remove direct access to interrupt handle")
Fixes: 0d0f478d0483 ("eal/linux: add uevent parse and process")
Signed-off-by: Ariel Otilibili <ariel.otilibili@6wind.com>
---
lib/eal/linux/eal_dev.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/lib/eal/linux/eal_dev.c b/lib/eal/linux/eal_dev.c
index c0ba98852b..0d9053b409 100644
--- a/lib/eal/linux/eal_dev.c
+++ b/lib/eal/linux/eal_dev.c
@@ -129,7 +129,6 @@ dev_uev_socket_fd_create(void)
return 0;
err:
close(fd);
- fd = -1;
return ret;
}
@@ -165,8 +164,6 @@ dev_uev_parse(const char *buf, struct rte_dev_event *event, int length)
* uevent from udev.
*/
if (!strncmp(buf, "libudev", 7)) {
- buf += 7;
- i += 7;
return -1;
}
if (!strncmp(buf, "ACTION=", 7)) {
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.706393117 +0800
+++ 0087-eal-linux-remove-useless-assignments.patch 2025-02-18 19:39:00.738244029 +0800
@@ -1 +1 @@
-From 36128ec5d93591700b72f3fc01bfe6216eaee905 Mon Sep 17 00:00:00 2001
+From 2a8873d4ce501d6c623ed204b04d34f54d8c91a9 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit 36128ec5d93591700b72f3fc01bfe6216eaee905 ]
@@ -15 +17,0 @@
-Cc: stable@dpdk.org
@@ -23 +25 @@
-index e63f24d108..be97f56424 100644
+index c0ba98852b..0d9053b409 100644
^ permalink raw reply [flat|nested] 89+ messages in thread
* patch 'mempool: fix errno in empty create' has been queued to stable release 23.11.4
2025-02-18 12:33 patch has been queued to stable release 23.11.4 Xueming Li
` (86 preceding siblings ...)
2025-02-18 12:35 ` patch 'eal/linux: remove useless assignments' " Xueming Li
@ 2025-02-18 12:35 ` Xueming Li
87 siblings, 0 replies; 89+ messages in thread
From: Xueming Li @ 2025-02-18 12:35 UTC (permalink / raw)
To: Ariel Otilibili; +Cc: xuemingl, Chengwen Feng, Konstantin Ananyev, dpdk stable
Hi,
FYI, your patch has been queued to stable release 23.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
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=23.11-staging
This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=5a7e0e1cfe70bc32fc87ef7141fac01bc27ae73f
Thanks.
Xueming Li <xuemingl@nvidia.com>
---
From 5a7e0e1cfe70bc32fc87ef7141fac01bc27ae73f Mon Sep 17 00:00:00 2001
From: Ariel Otilibili <ariel.otilibili@6wind.com>
Date: Mon, 20 Jan 2025 13:21:55 +0100
Subject: [PATCH] mempool: fix errno in empty create
Cc: Xueming Li <xuemingl@nvidia.com>
[ upstream commit a81d8ceff4e961995c78df6dbc9353dbbfbd8c32 ]
When returning from rte_mempool_set_ops_byname(), rte_errno is not set
for error exits.
The API requires rte_errno to be set in that case.
Bugzilla ID: 1559
Fixes: c2c6b2f41305 ("mempool: fix default ops for an empty mempool")
Signed-off-by: Ariel Otilibili <ariel.otilibili@6wind.com>
Acked-by: Chengwen Feng <fengchengwen@huawei.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@huawei.com>
---
lib/mempool/rte_mempool.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/lib/mempool/rte_mempool.c b/lib/mempool/rte_mempool.c
index 7a7a9bf6db..038bd967ab 100644
--- a/lib/mempool/rte_mempool.c
+++ b/lib/mempool/rte_mempool.c
@@ -927,8 +927,10 @@ rte_mempool_create_empty(const char *name, unsigned n, unsigned elt_size,
else
ret = rte_mempool_set_ops_byname(mp, "ring_mp_mc", NULL);
- if (ret)
+ if (ret) {
+ rte_errno = -ret;
goto exit_unlock;
+ }
/*
* local_cache pointer is set even if cache_size is zero.
--
2.34.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2025-02-18 19:39:03.739092212 +0800
+++ 0088-mempool-fix-errno-in-empty-create.patch 2025-02-18 19:39:00.738244029 +0800
@@ -1 +1 @@
-From a81d8ceff4e961995c78df6dbc9353dbbfbd8c32 Mon Sep 17 00:00:00 2001
+From 5a7e0e1cfe70bc32fc87ef7141fac01bc27ae73f Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl@nvidia.com>
+
+[ upstream commit a81d8ceff4e961995c78df6dbc9353dbbfbd8c32 ]
@@ -13 +15,0 @@
-Cc: stable@dpdk.org
@@ -23 +25 @@
-index d8e39e5c20..1e4f24783c 100644
+index 7a7a9bf6db..038bd967ab 100644
@@ -26 +28 @@
-@@ -928,8 +928,10 @@ rte_mempool_create_empty(const char *name, unsigned n, unsigned elt_size,
+@@ -927,8 +927,10 @@ rte_mempool_create_empty(const char *name, unsigned n, unsigned elt_size,
^ permalink raw reply [flat|nested] 89+ messages in thread