[PATCH net 0/2] ipv4: allow route dump replay with nexthop IDs

From: Yuen Su

Date: Wed Nov 18 2026 - 03:46:11 EST


IPv4 route flush fails when a route dump includes both a nexthop ID
and its expanded compatibility attributes. This series fixes the
IPv4 kernel delete path so that existing iproute2 can reuse the dump.
If a delete supplies RTA_NH_ID, the ID determines the nexthop match.

The first patch limits the mutual exclusion check to operations other
than deletion. The second adds a regression case to the existing IPv4
compatibility test. The route type and IPv6 changes discussed in the
earlier iproute2 thread are outside this series.

In QEMU/KVM, with the same unmodified iproute2, the new flush and
route removal checks failed on the base kernel and passed with the
fix. The three selected kselftests passed all 36 checks with the fix.

Codex helped extract the IPv4 kernel fix from the earlier iproute2
investigation, add the test and run the baseline and patched guests.

Earlier iproute2 discussion
https://lists.openwall.net/netdev/2026/10/26/186

Yuen

Yuen Su (2):
ipv4: accept nexthop dump attributes in route deletes
selftests: net: test flushing IPv4 nexthop routes in compat mode

net/ipv4/fib_frontend.c | 5 ++++-
tools/testing/selftests/net/fib_nexthops.sh | 7 +++++++
2 files changed, 11 insertions(+), 1 deletion(-)


base-commit: 2a324a58a084c5cfd7e5a2f55e0786bee170a4a5