Re: [PATCH net-next] net: use inet_rcv_saddr_any() in udp_tunnel and ping
From: Kuniyuki Iwashima
Date: Thu Nov 19 2026 - 02:39:00 EST
On Mon, 16 Nov 2026 21:08:53 +0100, Antonio Quartulli wrote:
> udp_tunnel_core.c carries its own copy of inet_rcv_saddr_any(),
> sk_saddr_any(), as it can be built as a module while
> inet_rcv_saddr_any() is not exported, and ping_bind() open-codes the
> same check for its AF_INET and AF_INET6 sockets.
>
> Make inet_rcv_saddr_any() a static inline in <net/addrconf.h>, where it
> is already declared, and use it in both places.
>
> Suggested-by: Kuniyuki Iwashima <kuniyu@xxxxxxxxxx>
> Link: https://lore.kernel.org/netdev/avVVzxL3pVZc6yQ5@xxxxxxxxxx/
> Signed-off-by: Antonio Quartulli <antonio@xxxxxxxxxxxxx>
Reviewed-by: Kuniyuki Iwashima <kuniyu@xxxxxxxxxx>