diff options
author | David S. Miller <davem@davemloft.net> | 2014-09-15 14:41:12 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-09-15 14:41:12 -0400 |
commit | 437024067ac1fbda7bb3a795e75922f9034672fb (patch) | |
tree | c0686708da032f9f6f842903163fa6da23ef649f /drivers/net/bonding | |
parent | 13bb5180e82349d9fcfa11cd17b3c1e7b558a902 (diff) | |
parent | b3d6cb92fd190d720a01075c4d20cdca896663fc (diff) |
Merge branch 'tcpflags'
Eric Dumazet says:
====================
tcp: no longer keep around headers in input path
Looking at tcp_try_coalesce() I was wondering why I did :
if (tcp_hdr(from)->fin)
return false;
The answer would be to allow the aggregation, if we simply OR the FIN and PSH
flags eventually present in @from to @to packet. (Note a change is also
needed in skb_try_coalesce() to avoid calling skb_put() with 0 len)
Then, looking at tcp_recvmsg(), I realized we access tcp_hdr(skb)->syn
(and maybe tcp_hdr(skb)->fin) for every packet we process from socket
receive queue.
We have to understand TCP flags are cold in cpu caches most of the time
(assuming TCP timestamps, and that application calls recvmsg() a long
time after incoming packet was processed), and bringing a whole
cache line only to access one bit is not very nice.
It would make sense to use in TCP input path TCP_SKB_CB(skb)->tcp_flags
as we do in output path.
This saves one cache line miss, and TCP tcp_collapse() can avoid dealing
with the headers.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bonding')
0 files changed, 0 insertions, 0 deletions