netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: eric.dumazet@gmail.com
Cc: ast@plumgrid.com, edumazet@google.com,
	stephen@networkplumber.org, netdev@vger.kernel.org
Subject: Re: vxlan gso is broken by stackable gso_segment()
Date: Fri, 25 Oct 2013 18:18:09 -0400 (EDT)	[thread overview]
Message-ID: <20131025.181809.348808013109842304.davem@davemloft.net> (raw)
In-Reply-To: <1382692140.7572.79.camel@edumazet-glaptop.roam.corp.google.com>

From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Fri, 25 Oct 2013 02:09:00 -0700

> @@ -1252,6 +1252,7 @@ static struct sk_buff *inet_gso_segment(struct sk_buff *skb,
>  	const struct net_offload *ops;
>  	unsigned int offset = 0;
>  	struct iphdr *iph;
> +	bool udpfrag;
>  	bool tunnel;
>  	int proto;
>  	int nhoff;
> @@ -1306,10 +1307,11 @@ static struct sk_buff *inet_gso_segment(struct sk_buff *skb,
>  	if (IS_ERR_OR_NULL(segs))
>  		goto out;
>  
> +	udpfrag = !!skb->encapsulation && proto == IPPROTO_UDP;
>  	skb = segs;
>  	do {
>  		iph = (struct iphdr *)(skb_mac_header(skb) + nhoff);
> -		if (!tunnel && proto == IPPROTO_UDP) {
> +		if (udpfrag) {
>  			iph->id = htons(id);
>  			iph->frag_off = htons(offset >> 3);
>  			if (skb->next != NULL)
> 

The "tunnel" variable becomes unused once you do this, please remove it.

  reply	other threads:[~2013-10-25 22:18 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-24 23:37 vxlan gso is broken by stackable gso_segment() Alexei Starovoitov
2013-10-25  0:41 ` Eric Dumazet
2013-10-25  1:59   ` Alexei Starovoitov
2013-10-25  4:06     ` Eric Dumazet
2013-10-25  9:09       ` Eric Dumazet
2013-10-25 22:18         ` David Miller [this message]
2013-10-25 22:41           ` Alexei Starovoitov
2013-10-25 23:10             ` David Miller
2013-10-25 23:25             ` Eric Dumazet
2013-10-26  0:26               ` [PATCH net-next] tcp: gso: fix truesize tracking Eric Dumazet
2013-10-26  1:46                 ` Alexei Starovoitov
2013-10-28  4:58                 ` David Miller
2013-10-29  4:05                 ` David Miller
2013-10-26  0:52               ` vxlan gso is broken by stackable gso_segment() Eric Dumazet
2013-10-26  1:25                 ` [PATCH net-next] veth: extend features to support tunneling Eric Dumazet
2013-10-26  2:22                   ` Alexei Starovoitov
2013-10-26  4:13                     ` Eric Dumazet
2013-10-28  4:58                   ` David Miller
2013-10-28  1:18             ` [PATCH net-next] inet: restore gso for vxlan Eric Dumazet
2013-10-28  4:25               ` David Miller
2013-11-07 22:33               ` Eric Dumazet
2013-11-07 23:27                 ` Alexei Starovoitov
2013-11-08  0:44                   ` [PATCH net-next] inet: fix a UFO regression Eric Dumazet
2013-11-08  1:39                     ` Alexei Starovoitov
2013-11-08  2:08                       ` Eric Dumazet
2013-11-08  2:32                     ` [PATCH v2 " Eric Dumazet
2013-11-08  7:08                       ` David Miller
2013-11-16 20:23                   ` [PATCH net-next] inet: restore gso for vxlan Or Gerlitz
2013-11-16 20:50                     ` Eric Dumazet

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=20131025.181809.348808013109842304.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=ast@plumgrid.com \
    --cc=edumazet@google.com \
    --cc=eric.dumazet@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.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;
as well as URLs for NNTP newsgroup(s).