From: David Miller <davem@davemloft.net>
To: therbert@google.com
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH net-next 0/6] net: Checksum offload changes - Part VI
Date: Mon, 01 Sep 2014 21:42:33 -0700 (PDT) [thread overview]
Message-ID: <20140901.214233.2138663914922963186.davem@davemloft.net> (raw)
In-Reply-To: <1409523166-9215-1-git-send-email-therbert@google.com>
From: Tom Herbert <therbert@google.com>
Date: Sun, 31 Aug 2014 15:12:40 -0700
> I am working on overhauling RX checksum offload. Goals of this effort
> are:
>
> - Specify what exactly it means when driver returns CHECKSUM_UNNECESSARY
> - Preserve CHECKSUM_COMPLETE through encapsulation layers
> - Don't do skb_checksum more than once per packet
> - Unify GRO and non-GRO csum verification as much as possible
> - Unify the checksum functions (checksum_init)
> - Simplify code
>
> What is in this seventh patch set:
>
> - Add skb->csum. This allows a device or GRO to indicate that an
> invalid checksum was detected.
> - Checksum unncessary to checksum complete conversions.
>
> With these changes, I believe that the third goal of the overhaul is
> now mostly achieved. In the case of no encapsulation or one layer of
> encapsulation, there should only be at most one skb_checksum over
> each packet (between GRO and normal path). In the case of two layers
> of encapsulation, it is still possible with the right combination of
> non-zero and zero UDP checksums to have >1 skb_checksum. For instance:
> IP>GRE(with csum)>IP>UDP(zero csum)>VXLAN>IP>UDP(non-zero csum),
> would likely necessiate an skb_checksum in GRO and normal path.
> This doesn't seem like a common scenario at all so I'm inclined to
> not address this now, if multiple layers of encapsulation becomes
> popular we can reassess.
>
> Note that checksum conversion shows a nice improvement for RX VXLAN when
> outer UDP checksum is enabled (12.65% CPU compared to 20.94%). This
> is not only from the fact that we don't need checksum calculation on
> the host, but also allows GRO for VXLAN in this case. Checksum
> conversion does not help send side (which still needs to perform
> a checksum on host). For that we will implement remote checksum offload
> in a later patch
> (http://tools.ietf.org/html/draft-herbert-remotecsumoffload-00).
>
> Please review carefully and test if possible, mucking with basic
> checksum functions is always a little precarious :-)
Awesome work, I love watching infrastructure gradually fall into
place like this :-)
Series applied, thanks!
prev parent reply other threads:[~2014-09-02 4:42 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-31 22:12 [PATCH net-next 0/6] net: Checksum offload changes - Part VI Tom Herbert
2014-08-31 22:12 ` [PATCH net-next 1/6] net: Support for csum_bad in skbuff Tom Herbert
2014-08-31 22:12 ` [PATCH net-next 2/6] net: Infrastructure for checksum unnecessary conversions Tom Herbert
2014-08-31 22:12 ` [PATCH net-next 3/6] udp: Add support for doing checksum unnecessary conversion Tom Herbert
2014-08-31 22:12 ` [PATCH net-next 4/6] gre: Add support for checksum unnecessary conversions Tom Herbert
2014-08-31 22:12 ` [PATCH net-next 5/6] vxlan: Enable checksum unnecessary conversions for vxlan/UDP sockets Tom Herbert
2014-08-31 22:12 ` [PATCH net-next 6/6] l2tp: Enable checksum unnecessary conversions for l2tp/UDP sockets Tom Herbert
2014-09-02 4:42 ` 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=20140901.214233.2138663914922963186.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=therbert@google.com \
/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;
as well as URLs for NNTP newsgroup(s).