[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CALnjE+po3bQWUWqKQKTV-8sPunT+ZbkY2XXeo5COBPJ_TJB0Ng@mail.gmail.com>
Date: Thu, 14 Feb 2013 19:31:02 -0800
From: Pravin Shelar <pshelar@...ira.com>
To: Michał Mirosław <mirqus@...il.com>
Cc: netdev@...r.kernel.org, edumazet@...gle.com, jesse@...ira.com,
bhutchings@...arflare.com
Subject: Re: [PATCH net-next 3/3] GRE: Add TCP segmentation offload for GRE
On Thu, Feb 14, 2013 at 6:35 PM, Michał Mirosław <mirqus@...il.com> wrote:
> 2013/2/14 Pravin B Shelar <pshelar@...ira.com>:
>> Following patch adds GRE protocol offload handler so that
>> skb_gso_segment() can segment GRE packets.
>> SKB GSO CB is added to keep track of total header length so that
>> skb_segment can push entire header. e.g. in case of GRE, skb_segment
>> need to push inner and outer headers to every segment.
>> New NETIF_F_GRE_GSO feature is added for devices which support HW
>> GRE TSO offload. Currently none of devices support it therefore GRE GSO
>> always fall backs to software GSO.
> [...]
>> @@ -1044,6 +1102,14 @@ static int ipgre_tunnel_bind_dev(struct net_device *dev)
>> mtu = 68;
>>
>> tunnel->hlen = addend;
>> + if (tunnel->parms.o_flags & GRE_SEQ) {
>> + /* TCP offload with GRE SEQ is not supported. */
>> + dev->features &= ~NETIF_F_GSO_SOFTWARE;
>> + dev->hw_features &= ~NETIF_F_GSO_SOFTWARE;
>> + } else {
>> + dev->features |= NETIF_F_GSO_SOFTWARE;
>> + dev->hw_features |= NETIF_F_GSO_SOFTWARE;
>> + }
>
> Feature clipping belongs to ndo_fix_features. Here,
> netdev_update_features() for the tunnel device should be called.
>
Actually no clipping is required. After creating tunnel device
features do not change. In short code above is setting features not
updating it. I will remove GRE_SEQ case since it is not required and
it is less confusing.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists