summaryrefslogtreecommitdiff
path: root/COPYING
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2016-12-06 19:32:50 -0800
committerDavid S. Miller <davem@davemloft.net>2016-12-07 10:47:35 -0500
commit5b8e2f61b9df529ca4af057daf7bfb1de348bdf1 (patch)
treeccd2569b8eb1ab8267667f690370ee79ccf5916f /COPYING
parentd4aea20d889e05575bb331a3dadf176176f7d631 (diff)
downloadlwn-5b8e2f61b9df529ca4af057daf7bfb1de348bdf1.tar.gz
lwn-5b8e2f61b9df529ca4af057daf7bfb1de348bdf1.zip
net: sock_rps_record_flow() is for connected sockets
Paolo noticed a cache line miss in UDP recvmsg() to access sk_rxhash, sharing a cache line with sk_drops. sk_drops might be heavily incremented by cpus handling a flood targeting this socket. We might place sk_drops on a separate cache line, but lets try to avoid wasting 64 bytes per socket just for this, since we have other bottlenecks to take care of. sock_rps_record_flow() should only access sk_rxhash for connected flows. Testing sk_state for TCP_ESTABLISHED covers most of the cases for connected sockets, for a zero cost, since system calls using sock_rps_record_flow() also access sk->sk_prot which is on the same cache line. A follow up patch will provide a static_key (Jump Label) since most hosts do not even use RFS. Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Paolo Abeni <pabeni@redhat.com> Acked-by: Paolo Abeni <pabeni@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'COPYING')
0 files changed, 0 insertions, 0 deletions