Eric Dumazet 21d1196a35 ipv4: set transport header earlier
commit 45f00f99d6e ("ipv4: tcp: clean up tcp_v4_early_demux()") added a
performance regression for non GRO traffic, basically disabling
IP early demux.

IPv6 stack resets transport header in ip6_rcv() before calling
IP early demux in ip6_rcv_finish(), while IPv4 does this only in
ip_local_deliver_finish(), _after_ IP early demux.

GRO traffic happened to enable IP early demux because transport header
is also set in inet_gro_receive()

Instead of reverting the faulty commit, we can make IPv4/IPv6 behave the
same : transport_header should be set in ip_rcv() instead of
ip_local_deliver_finish()

ip_local_deliver_finish() can also use skb_network_header_len() which is
faster than ip_hdrlen()

Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Neal Cardwell <ncardwell@google.com>
Cc: Tom Herbert <therbert@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2013-07-16 12:59:28 -07:00
..
2013-06-12 15:03:24 -07:00
2013-05-28 13:11:02 -07:00
2013-05-06 11:06:51 -04:00
2013-06-12 14:14:55 -07:00
2013-03-17 14:35:13 -04:00
2012-10-08 17:42:36 -04:00
2013-07-01 23:35:22 -07:00
2013-07-16 12:59:28 -07:00
2013-07-02 01:13:09 -07:00
2013-06-10 21:22:35 -07:00
2012-01-20 14:17:26 -05:00
2012-01-20 14:17:26 -05:00
2012-05-17 14:59:59 -04:00
2013-07-10 17:08:27 -07:00
2011-03-31 11:26:23 -03:00
2013-03-21 11:47:50 -04:00
2013-03-21 11:47:50 -04:00
2011-03-31 11:26:23 -03:00
2012-03-11 23:42:51 -07:00
2012-04-15 12:37:19 -04:00
2013-05-31 17:19:05 -07:00