diff options
| author | Daehyeon Ko <4ncienth@gmail.com> | 2026-10-02 13:50:59 +0900 |
|---|---|---|
| committer | Jakub Kicinski <kuba@kernel.org> | 2026-10-06 16:23:09 -0700 |
| commit | 4f4afc07dcb2edd4f9afa36595373f8cdb9b58c2 (patch) | |
| tree | 1b7a2bbc23d8ed307c8ed14abd11bdd5c53c3f6c /tools/perf/scripts/python | |
| parent | 6619e01855e65ef35723685a557e3eb106f4ecf5 (diff) | |
| download | linux-4f4afc07dcb2edd4f9afa36595373f8cdb9b58c2.tar.gz linux-4f4afc07dcb2edd4f9afa36595373f8cdb9b58c2.zip | |
ipv4: stop exception dump when nexthop group shrinks
Commit 4ce5dc9316de ("inet: switch inet_dump_fib() to RCU
protection") allowed IPv4 FIB dumps to run concurrently with nexthop
replacement.
fib_dump_info_fnhe() uses fib_info_num_path() as the loop bound,
then fib_info_nhc() independently reloads nh->nh_grp. If
RTM_NEWNEXTHOP replaces a group with fewer paths between those loads,
fib_info_nhc() returns NULL and the dump dereferences it through
nhc_flags.
Stop the walk when the indexed path is absent. Nexthop groups are
dense, so the current snapshot has no later path.
Fixes: 4ce5dc9316de ("inet: switch inet_dump_fib() to RCU protection")
Reported-by: Ido Schimmel <idosch@nvidia.com>
Link: https://lore.kernel.org/netdev/20261001170513.GA1657889@shredder/
Cc: stable@vger.kernel.org
Signed-off-by: Daehyeon Ko <4ncienth@gmail.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Link: https://patch.msgid.link/5bb7bd97411eb9db454464bf449107395e760f26.1790915964.git.4ncienth@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
