aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/tcp_output.c
diff options
context:
space:
mode:
authorJarek Poplawski <jarkao2@o2.pl>2007-01-24 01:07:12 -0500
committerDavid S. Miller <davem@davemloft.net>2007-01-24 01:07:12 -0500
commit52d570aabe921663a987b2e4bae2bdc411cee480 (patch)
tree2d4aff7efc6be2795894864b5b2043a514c11b55 /net/ipv4/tcp_output.c
parentbf1c1ee88008fd639ebb5c74f0555fd414369bdc (diff)
[TCP]: rare bad TCP checksum with 2.6.19
The patch "Replace CHECKSUM_HW by CHECKSUM_PARTIAL/CHECKSUM_COMPLETE" changed to unconditional copying of ip_summed field from collapsed skb. This patch reverts this change. The majority of substantial work including heavy testing and diagnosing by: Michael Tokarev <mjt@tls.msk.ru> Possible reasons pointed by: Herbert Xu and Patrick McHardy. Signed-off-by: Jarek Poplawski <jarkao2@o2.pl> Acked-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp_output.c')
-rw-r--r--net/ipv4/tcp_output.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c
index 32c1a972fa31..23e32c806916 100644
--- a/net/ipv4/tcp_output.c
+++ b/net/ipv4/tcp_output.c
@@ -1650,7 +1650,8 @@ static void tcp_retrans_try_collapse(struct sock *sk, struct sk_buff *skb, int m
1650 1650
1651 memcpy(skb_put(skb, next_skb_size), next_skb->data, next_skb_size); 1651 memcpy(skb_put(skb, next_skb_size), next_skb->data, next_skb_size);
1652 1652
1653 skb->ip_summed = next_skb->ip_summed; 1653 if (next_skb->ip_summed == CHECKSUM_PARTIAL)
1654 skb->ip_summed = CHECKSUM_PARTIAL;
1654 1655
1655 if (skb->ip_summed != CHECKSUM_PARTIAL) 1656 if (skb->ip_summed != CHECKSUM_PARTIAL)
1656 skb->csum = csum_block_add(skb->csum, next_skb->csum, skb_size); 1657 skb->csum = csum_block_add(skb->csum, next_skb->csum, skb_size);