K 10 svn:author V 5 andre K 8 svn:date V 27 2012-11-19T18:04:17.794741Z K 7 svn:log V 1224 Convert IP, IPv6, UDP, TCP and SCTP to the new checksum offloading semantics on the inbound and outbound path. In short for inbound there are two levels the offloading NIC can set: CSUM_L3_CALC for an IP layer 3 checksum calculated by the NIC; CSUM_L3_VALID set when the calculated checksum matches the one in the packet; CSUM_L4_CALC for an UDP/TCP/SCTP layer 4 checksum calculated by the NIC; CSUM_L4_VALID set when the calculated checksum matche the one in the packet. From this follows that a packet failed checksum verification when only *_CALC is set but not *_VALID. The NIC is expected to deliver a failed packet up the stack anyways for capture by BPF and to record protocol specific checksum mismatch statistics. The old approach with CSUM_DATA_VALID and CSUM_PSEUDO_HDR could not signal a failed packet. A failed packet was delivered into the stack and the protocol had to recalculate the checksum for verification every time to detect that as the absence of CSUM_DATA_VALID didn't signal that the packet was broken. It was only saying that the checksum wasn't calculated by the NIC, which actually wasn't the case. Drag the other stack infrastructure, including packet filters, along as well. END