mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: aduyck@mirantis.com
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	alexander.duyck@gmail.com
Subject: Re: [net-next PATCH 0/3] Fix differences between IPv4 and IPv6 TCP/UDP checksum calculation
Date: Mon, 14 Mar 2016 01:13:46 -0400 (EDT)	[thread overview]
Message-ID: <20160314.011346.677129632153799202.davem@davemloft.net> (raw)
In-Reply-To: <20160311215423.13431.64512.stgit@localhost.localdomain>

From: Alexander Duyck <aduyck@mirantis.com>
Date: Fri, 11 Mar 2016 14:05:28 -0800

> This patch series is meant to address the differences that exist between
> IPv4 and IPv6 in terms of checksum calculation.  Specifically the IPv6
> function csum_ipv6_magic treated length as a value that could be greater
> than 64K, while csum_tcpudp_magic was truncating the length at 16 bits.
> After looking over the code and giving it some thought I decided it would
> be best to update the IPv4 function so that it worked the same way the IPv6
> one did.  This allows us to get the same results given the same inputs for
> both functions.  As a result we can use the same processes to reverse the
> calculation in the event we need to do something like remove the length of
> the pseudo-header checksum.
> 
> I also took the opportunity to standardize things so that the parameters
> for these functions all use the correct types.  IPv4 addresses are __be32,
> length should always be __u32, and protocol is a __u8.
> 
> With this change in place it corrects an issue with UDP tunnels in which we
> were getting a checksum that was off by 1 when performing fragmentation on
> inner UDP packets.

Series applied, thanks Alexander.

      parent reply	other threads:[~2016-03-14  5:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-11 22:05 Alexander Duyck
2016-03-11 22:05 ` [net-next PATCH 1/3] ipv4: Update parameters for csum_tcpudp_magic to their original types Alexander Duyck
2016-03-11 22:05 ` [net-next PATCH 2/3] ipv6: Pass proto to csum_ipv6_magic as __u8 instead of unsigned short Alexander Duyck
2016-03-11 22:05 ` [net-next PATCH 3/3] GSO/UDP: Use skb->len instead of udph->len to determine length of original skb Alexander Duyck
2016-03-14  5:13 ` David Miller [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160314.011346.677129632153799202.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=aduyck@mirantis.com \
    --cc=alexander.duyck@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®