]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
tcp: fix RFS vs lockless listeners
authorEric Dumazet <edumazet@google.com>
Thu, 8 Oct 2015 18:16:48 +0000 (11:16 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sun, 11 Oct 2015 12:33:15 +0000 (05:33 -0700)
commit6bcfd7f8c28887a4298bc4386b02cb90c9fa0c13
tree34a3fa802965d1c97f5c242b79436bb648fa13c9
parent5010ea59e1b986d89023c0552fa38e32b519a617
tcp: fix RFS vs lockless listeners

Before recent TCP listener patches, we were updating listener
sk->sk_rxhash before the cloning of master socket.

children sk_rxhash was therefore correct after the normal 3WHS.

But with lockless listener, we no longer dirty/change listener sk_rxhash
as it would be racy.

We need to correctly update the child sk_rxhash, otherwise first data
packet wont hit correct cpu if RFS is used.

Fixes: 079096f103fa ("tcp/dccp: install syn_recv requests into ehash table")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Willem de Bruijn <willemb@google.com>
Cc: Tom Herbert <tom@herbertland.com>
Acked-by: Tom Herbert <tom@herbertland.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/syncookies.c
net/ipv4/tcp_minisocks.c