Skip to content

Commit 45ba3fe

Browse files
authored
expand Zero checksum handling in the v4->v6 path
1 parent e2b1967 commit 45ba3fe

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

nat46/modules/nat46-core.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1766,6 +1766,11 @@ void ip6_update_csum(struct sk_buff * skb, struct ipv6hdr * ip6hdr, int do_atomi
17661766
struct udphdr *udp = udp_hdr(skb);
17671767
unsigned udplen = ntohs(ip6hdr->payload_len) - (do_atomic_frag?8:0); /* UDP hdr + payload */
17681768

1769+
if ((udp->check == 0) && zero_csum_pass) {
1770+
/* zero checksum and the config to pass it is set - do nothing with it */
1771+
break;
1772+
}
1773+
17691774
oldsum = udp->check;
17701775
udp->check = 0;
17711776

0 commit comments

Comments
 (0)