netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matt Grant <matt@mattgrant.net.nz>
To: Sabrina Dubroca <sd@queasysnail.net>
Cc: Vlad Yasevich <vyasevic@redhat.com>,
	davem@davemloft.net, netdev@vger.kernel.org
Subject: Re: [PATCH net] ipv6: skip __ipv6_select_ident when there is no skb_dst
Date: Thu, 19 Mar 2015 22:39:50 +1300	[thread overview]
Message-ID: <1426757990.10267.3.camel@mattgrant.net.nz> (raw)
In-Reply-To: <20150318143644.GE1743@kria>

Hi!

This fixes hard lock on 3.19.2 as well. Without it, machine drops dead -
hard locks - pretty quickly after boot.

Will try 4.0-rc4 tomorrow.  4.0-rc3 had same hard crash issues.

Get it out there, this is a IPv6 network Packet of Death!  We need
3.19.3 ASAP I think.  

I'll try and see if I can get a network trace of the cause on Saturday.

Regards,

Matt

On Wed, 2015-03-18 at 15:36 +0100, Sabrina Dubroca wrote:
> 2015-03-18, 10:25:43 -0400, Vlad Yasevich wrote:
> > On 03/18/2015 10:15 AM, Sabrina Dubroca wrote:
> > > 2015-03-18, 10:04:10 -0400, Vlad Yasevich wrote:
> > >> On 03/18/2015 09:52 AM, Sabrina Dubroca wrote:
> > >>> Matt Grant reported frequent crashes in ipv6_select_ident when
> > >>> udp6_ufo_fragment is called from openvswitch on a skb that doesn't
> > >>> have a dst_entry set.
> > >>>
> > >>> Skip __ipv6_select_ident in case of a NULL rt.
> > >>>
> > >>> Fixes: 0508c07f5e0c ("ipv6: Select fragment id during UFO segmentation if not set.")
> > >>> Cc: Vladislav Yasevich <vyasevic@redhat.com>
> > >>> Reported-by: Matt Grant <matt@mattgrant.net.nz>
> > >>> Tested-by: Matt Grant <matt@mattgrant.net.nz>
> > >>> Signed-off-by: Sabrina Dubroca <sd@queasysnail.net>
> > >>> ---
> > >> [...]
> > >>
> > >> Hi Sabrina
> > >>
> > >> This would result in us using id 0 which is not what we want to do.
> > >>
> > >> In this case, udp6_ufo_fragment() should be calling ipv6_proxy_select_ident() so that
> > >> the fragment id is properly generated.
> > > 
> > > Hi Vlad,
> > > 
> > > So, instead, something like this?  Or do you want to use
> > > ipv6_proxy_select_ident even when we have a skb_dst?
> > > 
> > 
> > Yes, this is what I was thinking...
> > 
> > -vlad
> 
> Okay, so:
> 
> diff --git a/net/ipv6/udp_offload.c b/net/ipv6/udp_offload.c
> index ab889bb16b3c..be2c0ba82c85 100644
> --- a/net/ipv6/udp_offload.c
> +++ b/net/ipv6/udp_offload.c
> @@ -112,11 +112,9 @@ static struct sk_buff *udp6_ufo_fragment(struct sk_buff *skb,
>  		fptr = (struct frag_hdr *)(skb_network_header(skb) + unfrag_ip6hlen);
>  		fptr->nexthdr = nexthdr;
>  		fptr->reserved = 0;
> -		if (skb_shinfo(skb)->ip6_frag_id)
> -			fptr->identification = skb_shinfo(skb)->ip6_frag_id;
> -		else
> -			ipv6_select_ident(fptr,
> -					  (struct rt6_info *)skb_dst(skb));
> +		if (!skb_shinfo(skb)->ip6_frag_id)
> +			ipv6_proxy_select_ident(skb);
> +		fptr->identification = skb_shinfo(skb)->ip6_frag_id;
>  
>  		/* Fragment the skb. ipv6 header and the remaining fields of the
>  		 * fragment header are updated in ipv6_gso_segment()
> 
> 

-- 
Matt Grant,  Debian and Linux Systems Administration and Consulting
Mobile: 021 0267 0578
Email: matt@mattgrant.net.nz

  reply	other threads:[~2015-03-19  9:49 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-18 13:52 [PATCH net] ipv6: skip __ipv6_select_ident when there is no skb_dst Sabrina Dubroca
2015-03-18 14:04 ` Vlad Yasevich
2015-03-18 14:15   ` Sabrina Dubroca
2015-03-18 14:25     ` Vlad Yasevich
2015-03-18 14:36       ` Sabrina Dubroca
2015-03-19  9:39         ` Matt Grant [this message]
2015-03-19 10:10           ` Sabrina Dubroca
2015-03-19 10:22             ` [PATCH net] ipv6: call ipv6_proxy_select_ident instead of ipv6_select_ident in udp6_ufo_fragment Sabrina Dubroca
2015-03-19 12:37               ` Vlad Yasevich
2015-03-20 17: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=1426757990.10267.3.camel@mattgrant.net.nz \
    --to=matt@mattgrant.net.nz \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=sd@queasysnail.net \
    --cc=vyasevic@redhat.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).