patch 'fib: fix prefix addition handling' has been queued to stable release 23.11.7
Shani Peretz
shperetz at nvidia.com
Tue Mar 31 08:25:02 CEST 2026
Hi,
FYI, your patch has been queued to stable release 23.11.7
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 04/05/26. So please
shout if anyone has objections.
Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.
Queued patches are on a temporary branch at:
https://github.com/shanipr/dpdk-stable
This queued commit can be viewed at:
https://github.com/shanipr/dpdk-stable/commit/5702e0fa0c138dd42fc915554ed34cdb51d9035d
Thanks.
Shani
---
>From 5702e0fa0c138dd42fc915554ed34cdb51d9035d Mon Sep 17 00:00:00 2001
From: Vladimir Medvedkin <vladimir.medvedkin at intel.com>
Date: Wed, 21 Jan 2026 17:57:01 +0000
Subject: [PATCH] fib: fix prefix addition handling
[ upstream commit 3ad9ad9e362b1c114dc6103ee5a1394048fd78c0 ]
When adding a prefix longer than /24 in FIB/FIB6 as a first prefix within
its corresponding /24 supernet with the same next hop as its parent, the
code would incorrectly skip incrementing the number of reserved TBL8 due
to an early return statement. This could lead to integer overflow in
'dp->rsvd_tbl8s'. This commit corrects the logic to ensure that the
reserved TBL8 count is properly incremented in such scenarios.
Bugzilla ID: 1731
Fixes: 7dc7868b200d ("fib: add DIR24-8 dataplane algorithm")
Fixes: c3e12e0f0354 ("fib: add dataplane algorithm for IPv6")
Signed-off-by: Vladimir Medvedkin <vladimir.medvedkin at intel.com>
---
lib/fib/dir24_8.c | 3 ++-
lib/fib/trie.c | 4 ++--
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/lib/fib/dir24_8.c b/lib/fib/dir24_8.c
index 07c324743b..daed2bac95 100644
--- a/lib/fib/dir24_8.c
+++ b/lib/fib/dir24_8.c
@@ -460,13 +460,14 @@ dir24_8_modify(struct rte_fib *fib, uint32_t ip, uint8_t depth,
if (parent != NULL) {
rte_rib_get_nh(parent, &par_nh);
if (par_nh == next_hop)
- return 0;
+ goto successfully_added;
}
ret = modify_fib(dp, rib, ip, depth, next_hop);
if (ret != 0) {
rte_rib_remove(rib, ip, depth);
return ret;
}
+successfully_added:
if ((depth > 24) && (tmp == NULL))
dp->rsvd_tbl8s++;
return 0;
diff --git a/lib/fib/trie.c b/lib/fib/trie.c
index 8937ab46dc..3a169adaa8 100644
--- a/lib/fib/trie.c
+++ b/lib/fib/trie.c
@@ -581,14 +581,14 @@ trie_modify(struct rte_fib6 *fib, const uint8_t ip[RTE_FIB6_IPV6_ADDR_SIZE],
if (parent != NULL) {
rte_rib6_get_nh(parent, &par_nh);
if (par_nh == next_hop)
- return 0;
+ goto successfully_added;
}
ret = modify_dp(dp, rib, ip_masked, depth, next_hop);
if (ret != 0) {
rte_rib6_remove(rib, ip_masked, depth);
return ret;
}
-
+successfully_added:
dp->rsvd_tbl8s += depth_diff;
return 0;
case RTE_FIB6_DEL:
--
2.43.0
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2026-03-31 00:32:37.601970705 +0300
+++ 0103-fib-fix-prefix-addition-handling.patch 2026-03-31 00:32:29.822268000 +0300
@@ -1 +1 @@
-From 3ad9ad9e362b1c114dc6103ee5a1394048fd78c0 Mon Sep 17 00:00:00 2001
+From 5702e0fa0c138dd42fc915554ed34cdb51d9035d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3ad9ad9e362b1c114dc6103ee5a1394048fd78c0 ]
+
@@ -16 +17,0 @@
-Cc: stable at dpdk.org
@@ -25 +26 @@
-index 57594bb561..489d2ef427 100644
+index 07c324743b..daed2bac95 100644
@@ -28 +29 @@
-@@ -516,13 +516,14 @@ dir24_8_modify(struct rte_fib *fib, uint32_t ip, uint8_t depth,
+@@ -460,13 +460,14 @@ dir24_8_modify(struct rte_fib *fib, uint32_t ip, uint8_t depth,
@@ -45 +46 @@
-index 9b56dd9588..fa5d9ec6b0 100644
+index 8937ab46dc..3a169adaa8 100644
@@ -48 +49 @@
-@@ -614,14 +614,14 @@ trie_modify(struct rte_fib6 *fib, const struct rte_ipv6_addr *ip,
+@@ -581,14 +581,14 @@ trie_modify(struct rte_fib6 *fib, const uint8_t ip[RTE_FIB6_IPV6_ADDR_SIZE],
@@ -55 +56 @@
- ret = modify_dp(dp, rib, &ip_masked, depth, next_hop);
+ ret = modify_dp(dp, rib, ip_masked, depth, next_hop);
@@ -57 +58 @@
- rte_rib6_remove(rib, &ip_masked, depth);
+ rte_rib6_remove(rib, ip_masked, depth);
More information about the stable
mailing list