* [PATCH net] ipv4: do not warn on route notification size race
@ 2026-10-07 4:54 Daehyeon Ko
2026-10-07 4:59 ` netdev-bot+sinfo
2026-10-07 11:40 ` Ido Schimmel
0 siblings, 2 replies; 3+ messages in thread
From: Daehyeon Ko @ 2026-10-07 4:54 UTC (permalink / raw)
To: David Ahern, Ido Schimmel
Cc: David S . Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
Simon Horman, Amit Cohen, Roopa Prabhu, netdev, linux-kernel,
Daehyeon Ko
Commit 680aea08e78c ("net: ipv4: Emit notification when fib hardware
flags are changed") added asynchronous route notifications for hardware
flag changes.
fib_alias_hw_flags_set() sizes the skb with fib_nlmsg_size() and later
fills it with fib_dump_info() while holding only RCU. With nexthop
compatibility mode enabled, a concurrent replacement can grow the group
between these independent snapshots. fib_dump_info() can then
legitimately return -EMSGSIZE, so the warning does not prove a sizing bug.
Remove the warning. The existing error path still frees the skb and
reports the error to listeners.
Fixes: 680aea08e78c ("net: ipv4: Emit notification when fib hardware flags are changed")
Reported-by: Ido Schimmel <idosch@nvidia.com>
Link: https://lore.kernel.org/netdev/20261004082043.GB92032@shredder/
Suggested-by: Ido Schimmel <idosch@nvidia.com>
Cc: stable@vger.kernel.org
Assisted-by: LLM
Signed-off-by: Daehyeon Ko <4ncienth@gmail.com>
---
No new build or runtime test was run. This is the exact two-line deletion
suggested in the linked review.
net/ipv4/fib_trie.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/net/ipv4/fib_trie.c b/net/ipv4/fib_trie.c
index acb1e43859143e..248514dce0cdd5 100644
--- a/net/ipv4/fib_trie.c
+++ b/net/ipv4/fib_trie.c
@@ -1079,8 +1079,6 @@ void fib_alias_hw_flags_set(struct net *net, const struct fib_rt_info *fri)
err = fib_dump_info(skb, 0, 0, RTM_NEWROUTE, fri, 0);
if (err < 0) {
- /* -EMSGSIZE implies BUG in fib_nlmsg_size() */
- WARN_ON(err == -EMSGSIZE);
kfree_skb(skb);
goto errout;
}
base-commit: 23609bce9e1de525d1d0e73fc68c6e7971d0b49e
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH net] ipv4: do not warn on route notification size race
2026-10-07 4:54 [PATCH net] ipv4: do not warn on route notification size race Daehyeon Ko
@ 2026-10-07 4:59 ` netdev-bot+sinfo
2026-10-07 11:40 ` Ido Schimmel
1 sibling, 0 replies; 3+ messages in thread
From: netdev-bot+sinfo @ 2026-10-07 4:59 UTC (permalink / raw)
To: Daehyeon Ko
Cc: David Ahern, Ido Schimmel, David S . Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni, Simon Horman, Amit Cohen,
Roopa Prabhu, netdev, linux-kernel
Hi!
This is an automated message. This series looks like a fix, but its
commit messages seem to be missing some information:
- Whether the issue was actually triggered, or is only theoretical
(e.g. found by code inspection). If it was triggered please include
the symptoms, like the stack trace or error messages.
Please do not repost the series just to address the above. Instead,
reply to this email with the missing information, so that reviewers
can take it into account. If the series needs another revision for
other reasons, please include the information in the commit messages
then.
The evaluation is done by an LLM so it may be wrong, if you think
that is the case please reply and explain.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH net] ipv4: do not warn on route notification size race
2026-10-07 4:54 [PATCH net] ipv4: do not warn on route notification size race Daehyeon Ko
2026-10-07 4:59 ` netdev-bot+sinfo
@ 2026-10-07 11:40 ` Ido Schimmel
1 sibling, 0 replies; 3+ messages in thread
From: Ido Schimmel @ 2026-10-07 11:40 UTC (permalink / raw)
To: Daehyeon Ko
Cc: David Ahern, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Simon Horman, Amit Cohen, Roopa Prabhu, netdev,
linux-kernel
On Wed, Oct 07, 2026 at 01:54:10PM +0900, Daehyeon Ko wrote:
> Commit 680aea08e78c ("net: ipv4: Emit notification when fib hardware
> flags are changed") added asynchronous route notifications for hardware
> flag changes.
>
> fib_alias_hw_flags_set() sizes the skb with fib_nlmsg_size() and later
> fills it with fib_dump_info() while holding only RCU. With nexthop
> compatibility mode enabled, a concurrent replacement can grow the group
> between these independent snapshots. fib_dump_info() can then
> legitimately return -EMSGSIZE, so the warning does not prove a sizing bug.
>
> Remove the warning. The existing error path still frees the skb and
> reports the error to listeners.
>
> Fixes: 680aea08e78c ("net: ipv4: Emit notification when fib hardware flags are changed")
> Reported-by: Ido Schimmel <idosch@nvidia.com>
> Link: https://lore.kernel.org/netdev/20261004082043.GB92032@shredder/
> Suggested-by: Ido Schimmel <idosch@nvidia.com>
> Cc: stable@vger.kernel.org
> Assisted-by: LLM
> Signed-off-by: Daehyeon Ko <4ncienth@gmail.com>
> ---
> No new build or runtime test was run. This is the exact two-line deletion
> suggested in the linked review.
The previous series was IPv4-specific and I forgot that
fib6_info_hw_flags_set() has the same problem. Please include the IPv6
fix as patch 2 of v2. Wait 24h before posting per:
https://docs.kernel.org/next/process/maintainer-netdev.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-10-07 11:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-07 4:54 [PATCH net] ipv4: do not warn on route notification size race Daehyeon Ko
2026-10-07 4:59 ` netdev-bot+sinfo
2026-10-07 11:40 ` Ido Schimmel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®