David S. Miller 2626419ad5 tcp: Set CHECKSUM_UNNECESSARY in tcp_init_nondata_skb
Back in commit 04a0551c87363f100b04d28d7a15a632b70e18e7
("loopback: Drop obsolete ip_summed setting") we stopped
setting CHECKSUM_UNNECESSARY in the loopback xmit.

This is because such a setting was a lie since it implies that the
checksum field of the packet is properly filled in.

Instead what happens normally is that CHECKSUM_PARTIAL is set and
skb->csum is calculated as needed.

But this was only happening for TCP data packets (via the
skb->ip_summed assignment done in tcp_sendmsg()).  It doesn't
happen for non-data packets like ACKs etc.

Fix this by setting skb->ip_summed in the common non-data packet
constructor.  It already is setting skb->csum to zero.

But this reminds us that we still have things like ip_output.c's
ip_dev_loopback_xmit() which sets skb->ip_summed to the value
CHECKSUM_UNNECESSARY, which Herbert's patch teaches us is not
valid.  So we'll have to address that at some point too.

Signed-off-by: David S. Miller <davem@davemloft.net>
2010-04-08 11:32:30 -07:00
..
2010-02-10 12:31:10 -08:00
2010-04-07 21:20:47 -07:00
2010-02-18 14:30:18 -08:00
2009-11-25 15:14:13 -08:00
2009-12-26 20:38:23 -08:00
2010-02-10 12:31:10 -08:00
2010-02-18 14:30:18 -08:00
2009-12-15 08:53:25 -08:00
2010-03-05 13:34:03 -08:00
2010-03-15 16:00:47 -07:00
2010-03-02 14:28:49 -05:00
2010-03-22 09:57:19 -07:00
2010-03-23 13:06:14 -07:00
2010-02-18 14:12:06 -08:00
2009-07-12 12:22:34 -07:00
2010-02-18 14:30:18 -08:00
2010-03-03 01:04:37 -08:00