diff options
author | Tom Herbert <therbert@google.com> | 2014-06-05 02:20:09 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-06-05 07:46:38 +0200 |
commit | e9c3a24b3ace90b428848fdaf772ed264982abcc (patch) | |
tree | f26309bd487abf81f6413e083a58cbecc9ab97d1 /net/ipv4 | |
parent | net: Support for multiple checksums with gso (diff) | |
download | linux-e9c3a24b3ace90b428848fdaf772ed264982abcc.tar.xz linux-e9c3a24b3ace90b428848fdaf772ed264982abcc.zip |
tcp: Call gso_make_checksum
Call common gso_make_checksum when calculating checksum for a
TCP GSO segment.
Signed-off-by: Tom Herbert <therbert@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/tcp_offload.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/net/ipv4/tcp_offload.c b/net/ipv4/tcp_offload.c index b92b81718ca4..d8de7b9e0720 100644 --- a/net/ipv4/tcp_offload.c +++ b/net/ipv4/tcp_offload.c @@ -97,9 +97,7 @@ struct sk_buff *tcp_gso_segment(struct sk_buff *skb, th->check = newcheck; if (skb->ip_summed != CHECKSUM_PARTIAL) - th->check = - csum_fold(csum_partial(skb_transport_header(skb), - thlen, skb->csum)); + th->check = gso_make_checksum(skb, ~th->check); seq += mss; if (copy_destructor) { @@ -133,8 +131,7 @@ struct sk_buff *tcp_gso_segment(struct sk_buff *skb, th->check = ~csum_fold((__force __wsum)((__force u32)th->check + (__force u32)delta)); if (skb->ip_summed != CHECKSUM_PARTIAL) - th->check = csum_fold(csum_partial(skb_transport_header(skb), - thlen, skb->csum)); + th->check = gso_make_checksum(skb, ~th->check); out: return segs; } |