]> git.karo-electronics.de Git - karo-tx-linux.git/commit
tcp: avoid two atomic ops for syncookies
authorEric Dumazet <edumazet@google.com>
Mon, 5 Oct 2015 04:08:11 +0000 (21:08 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 5 Oct 2015 09:45:27 +0000 (02:45 -0700)
commita1a5344ddbe8fd3e080013b317ac9a664490cfdf
tree75c793a05dd64db3df05f804e429bae45ead20d1
parent004a5d0140ce1d05c1f5fce5df4baa2717a330e0
tcp: avoid two atomic ops for syncookies

inet_reqsk_alloc() is used to allocate a temporary request
in order to generate a SYNACK with a cookie. Then later,
syncookie validation also uses a temporary request.

These paths already took a reference on listener refcount,
we can avoid a couple of atomic operations.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/inet_sock.h
include/net/request_sock.h
net/dccp/ipv4.c
net/dccp/ipv6.c
net/ipv4/syncookies.c
net/ipv4/tcp_input.c
net/ipv6/syncookies.c