Netdev List
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: Kevin Wilson <wkevils@gmail.com>
Cc: netdev@vger.kernel.org
Subject: Re: GSO and IPv4 forwarding
Date: Tue, 26 Oct 2010 22:15:14 +0200	[thread overview]
Message-ID: <1288124114.2652.25.camel@edumazet-laptop> (raw)
In-Reply-To: <AANLkTikxNYGFAmyZDit9fTp=-M8wfYp3Ew8rejsjHWHb@mail.gmail.com>

Le mardi 26 octobre 2010 à 22:02 +0200, Kevin Wilson a écrit :
> Hi,
> When we set a netdevice to support forwarding, we disable LRO.
> This is done because we don't want to forward an SKB which has been
> processed by LRO.
> 
> This is done in inet_forward_change() in net/ipv4/devinet.c:
> We call dev_disable_lro(dev) in this method, when setting forwarding
> for the device.
> As a result, in ip_forward(), the packet will be dropped. (because
> skb_warn_if_lro(), called by this method,  returns TRUE)
> 
> My question is:
> dev_disable_lro(dev) disable the LRO feature (NETIF_F_LRO) of the
> device. But suppose I have a device where GRO is enabled (and LRO is
> not). And let's say I set forwarding on this device.
> 
> it seems to me that is such case, calling dev_disable_lro(dev)  in
> net_forward_change() to disable the LRO feature of the device (which
> is already disabled) is not enough, and in such case , GRO packets,
> which want to be forwarded,  will **not** be dropped in ip_forward().
> (since kb_warn_if_lro() will return false in this case)
> 
> Is it so ? I am ready to send a patch fixing it, but I am a newbie in
> kernel, so I want to ask first.

GRO packets can be forwarded just fine.




  reply	other threads:[~2010-10-26 20:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-26 20:02 GSO and IPv4 forwarding Kevin Wilson
2010-10-26 20:15 ` Eric Dumazet [this message]
2010-10-26 20:26   ` Kevin Wilson
2010-10-26 20:43     ` Eric Dumazet
2010-10-26 20:52     ` Stephen Hemminger
2010-10-26 20:19 ` 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=1288124114.2652.25.camel@edumazet-laptop \
    --to=eric.dumazet@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=wkevils@gmail.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