All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, dmitry@broadcom.com, eilong@broadcom.com,
	pshelar@nicira.com, hkchu@google.com, maze@google.com
Subject: Re: [PATCH net-next] gro: relax ID check in inet_gro_receive()
Date: Thu, 21 Mar 2013 09:08:11 -0700	[thread overview]
Message-ID: <1363882091.4431.20.camel@edumazet-glaptop> (raw)
In-Reply-To: <20130321.114616.279859400813363663.davem@davemloft.net>

On Thu, 2013-03-21 at 11:46 -0400, David Miller wrote:
> From: Eric Dumazet <eric.dumazet@gmail.com>
> Date: Wed, 20 Mar 2013 21:52:33 -0700
> 
> > GRE TSO support doesn't increment the ID in the inner IP header.
> 
> Is this a fundamental limitation of doing TSO over GRO or
> were the Broadcom folks just being lazy with their firmware
> implementation?
> 

Well, I suspect this hardware is not capable of doing the proper ID
manipulation twice. (inner and outer header)

Still TSO support permits a single GRE flow going from 3Gbps to 9Gbps on
our hosts. So even if the inner IP id is 'broken', we are going to use
TSO.

Note we are limited by the receiver, as the receiver has to perform the
tcp checksum in software (bnx2x doesnt support CHECKSUM_COMPLETE yet)

Hopefully next firmware or NIC will do the right thing.

> I really don't want to apply this patch, because ipv4 frames
> even with DF set should have an incrementing ID field, in
> order to accomodate various header compression schemes.
> 
> We go out of our way to do this for normal unencapsulated TCP stream
> packets, rather than set the ID field to zero (which we did for some
> time until the compression issue was pointed out to us).

I understand your concern, but this check in GRO brings nothing at all.

Once we receive frames with 'bad IPv4 ID', should we accept them or drop
them ?

TCP stack doesn't care at receive (obviously as this ID is not a concern
for the transport layer), so GRO should do the same, as GRO is a best
effort to reduce cpu load.

I fully understand the 'tos' check because of proper ECN support, but
the ttl check or id check are totally useless and time consuming.

GRO aggregation should roughly work the same than TCP coalescing, and we
don't care of IP ID or ttl in TCP stack.

  reply	other threads:[~2013-03-21 16:08 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-21  4:52 [PATCH net-next] gro: relax ID check in inet_gro_receive() Eric Dumazet
2013-03-21  9:59 ` Maciej Żenczykowski
2013-03-21 10:05   ` Maciej Żenczykowski
2013-03-21 14:56   ` David Miller
2013-03-21 15:46 ` David Miller
2013-03-21 16:08   ` Eric Dumazet [this message]
2013-03-21 16:31     ` David Miller
2013-03-21 18:11     ` Dmitry Kravkov
2013-03-21 18:56       ` David Miller
2013-03-21 20:14         ` Maciej Żenczykowski
2013-03-21 20:20           ` David Miller
2013-03-21 20:47             ` Maciej Żenczykowski
2013-03-21 21:05               ` David Miller
2013-03-21 21:37                 ` Jesse Gross
2013-03-21 21:39                   ` David Miller
     [not found]     ` <CAM8tLiPh=g1+XqhwKQAH7XyTmpT80j5422VXGjLksxtFxYoxRQ@mail.gmail.com>
2013-03-21 20:07       ` Maciej Żenczykowski
2013-03-21 20:13         ` Dmitry Kravkov
2013-03-21 16:20   ` Ben Hutchings
2013-03-21 16:31     ` David Miller

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=1363882091.4431.20.camel@edumazet-glaptop \
    --to=eric.dumazet@gmail.com \
    --cc=davem@davemloft.net \
    --cc=dmitry@broadcom.com \
    --cc=eilong@broadcom.com \
    --cc=hkchu@google.com \
    --cc=maze@google.com \
    --cc=netdev@vger.kernel.org \
    --cc=pshelar@nicira.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.