udp: remove udp_tunnel_gro_init()
Subsystems (2)
PATCH 1/1 udp: remove udp_tunnel_gro_init()
Use DEFINE_MUTEX() to initialize udp_tunnel_gro_type_lock.
Signed-off-by Eric Dumazet <[email protected]>
--- net/ipv4/udp_offload.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-)
net/ipv4/udp_offload.c +1 -9
@@ -44,7 +44,7 @@ struct udp_tunnel_type_entry {DEFINE_STATIC_CALL (udp_tunnel_gro_rcv, dummy_gro_rcv);static DEFINE_STATIC_KEY_FALSE (udp_tunnel_static_call); -static struct mutex udp_tunnel_gro_type_lock; +static DEFINE_MUTEX (udp_tunnel_gro_type_lock);static struct udp_tunnel_type_entry udp_tunnel_gro_types[UDP_MAX_TUNNEL_TYPES ];static unsigned int udp_tunnel_gro_type_nr;static DEFINE_SPINLOCK (udp_tunnel_gro_lock);
@@ -144,11 +144,6 @@ void udp_tunnel_update_gro_rcv(struct sock *sk, bool add) }EXPORT_SYMBOL_GPL (udp_tunnel_update_gro_rcv); -static void udp_tunnel_gro_init (void ) -{ -mutex_init (&udp_tunnel_gro_type_lock); -} -static struct sk_buff *udp_tunnel_gro_rcv (struct sock *sk,struct list_head *head,struct sk_buff *skb)
@@ -165,8 +160,6 @@ static struct sk_buff *udp_tunnel_gro_rcv(struct sock *sk,#else -static void udp_tunnel_gro_init (void ) {} -static struct sk_buff *udp_tunnel_gro_rcv (struct sock *sk,struct list_head *head,struct sk_buff *skb)
@@ -1000,6 +993,5 @@ int __init udpv4_offload_init(void) }, }; -udp_tunnel_gro_init ();return inet_add_offload (&net_hotdata.udpv4_offload,IPPROTO_UDP ); }
Signature · 1 line
2.50.0.727.gbf7dc18ff4-goog
Quoted 3 lines · Eric Dumazet
Use
DEFINE_MUTEX()to initializeudp_tunnel_gro_type_lock.Signed-off-by Eric Dumazet <[email protected]>
Reviewed-by Simon Horman <[email protected]>
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Quoted 6 lines · On Mon, 7 Jul 2025 09:16:34 +0000 you wrote:
Use
DEFINE_MUTEX()to initializeudp_tunnel_gro_type_lock.Signed-off-by Eric Dumazet <[email protected]>--- net/ipv4/udp_offload.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-)
Here is the summary with links:
- [net-next] udp: remove udp_tunnel_gro_init()
https://git.kernel.org/netdev/net-next/c/ea988b450690
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html