]> git.baikalelectronics.ru Git - kernel.git/commit
net: generalize skb_segment()
authorEric Dumazet <edumazet@google.com>
Sat, 19 Oct 2013 18:42:54 +0000 (11:42 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sat, 19 Oct 2013 23:36:18 +0000 (19:36 -0400)
commit470c821cce8d51c0d9d5517810e334d261fcce13
tree95b56e3692c3f2704d7f41d70fb0627ae812ed2c
parent55f492065b34d02de824692a37d9316c58f7324f
net: generalize skb_segment()

While implementing GSO/TSO support for IPIP, I found skb_segment()
was assuming network header was immediately following mac header.

Its not really true in the case inet_gso_segment() is stacked :
By the time tcp_gso_segment() is called, network header points
to the inner IP header.

Let's instead assume nothing and pick the current offsets found in
original skb, we have skb_headers_offset_update() helper for that.

Also move the csum_start update inside skb_headers_offset_update()

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/skbuff.c