On Fri, Mar 25, 2016 at 03:29:24PM -0700, Eric Dumazet wrote: > Tom Herbert would like to avoid touching UDP socket refcnt for encapsulated > traffic. For this to happen, we need to use normal RCU rules, with a grace > period before freeing a socket. UDP sockets are not short lived in the > high usage case, so the added cost of call_rcu() should not be a concern. > > This actually removes a lot of complexity in UDP stack > > Multicast receives no longer need to hold a bucket lock. > > Note that ip early demux still needs to take a reference on the socket. > > Same remark for functions used by xt_socket and xt_PROXY netfilter modules, > but this might be changed later. > > Signed-off-by: Eric Dumazet <eduma...@google.com> > Cc: Tom Herbert <t...@herbertland.com> > --- > include/linux/udp.h | 8 +- > include/net/sock.h | 12 +-- > include/net/udp.h | 2 +- > net/ipv4/udp.c | 290 > +++++++++++++++------------------------------------- > net/ipv4/udp_diag.c | 18 ++-- > net/ipv6/udp.c | 194 +++++++++++------------------------ > 6 files changed, 162 insertions(+), 362 deletions(-)
great stuff!