From: Nicolas Dichtel <nicolas.dichtel@6wind•com>
To: Willem de Bruijn <willemb@google•com>
Cc: David Miller <davem@davemloft•net>,
netdev@vger•kernel.org, steffen.klassert@secunet•com,
pshelar@nicira•com, gregkh@linuxfoundation•org,
stable@vger•kernel.org
Subject: Re: [PATCH net 1/2] sit: allow to use rtnl ops on fb tunnel
Date: Tue, 22 Oct 2013 09:34:44 +0200 [thread overview]
Message-ID: <52662A94.9000501@6wind.com> (raw)
In-Reply-To: <CA+FuTScA26dW8bO5YdKTKp9tjSM-xVqkdkq8xzu-wH0cT=Wh8Q@mail.gmail.com>
Le 22/10/2013 01:30, Willem de Bruijn a écrit :
> On Wed, Oct 2, 2013 at 3:15 AM, Nicolas Dichtel
> <nicolas.dichtel@6wind•com> wrote:
>> Le 01/10/2013 18:59, David Miller a écrit :
>>
>>> From: Nicolas Dichtel <nicolas.dichtel@6wind•com>
>>> Date: Tue, 1 Oct 2013 18:04:59 +0200
>>>
>>>> rtnl ops where introduced by ba3e3f50a0e5 ("sit: advertise tunnel param
>>>> via
>>>> rtnl"), but I forget to assign rtnl ops to fb tunnels.
>>>>
>>>> Now that it is done, we must remove the explicit call to
>>>> unregister_netdevice_queue(), because the fallback tunnel is added to
>>>> the queue
>>>> in sit_destroy_tunnels() when checking rtnl_link_ops of all netdevices
>>>> (this
>>>> is valid since commit 5e6700b3bf98 ("sit: add support of x-netns")).
>>>>
>>>> Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind•com>
>>>
>>>
>>> Applied and queued up for -stable.
>>>
>>> But I imagine since the x-netns changes aren't in various -stable
>>> branches this will need to be adjusted a bit?
>>
>> Yes, it's what I've tried to say in the commit log ;-)
>>
>> In fact, before the x-netns changes, we must keep the
>> unregister_netdevice_queue() line.
>
> In 3.11 linux-stable, this patch was merged between 3.11.4 and 3.11.5
> in commit 3783100, after the x-netns changes in commit 5e6700b3bf, but
> the unregister_netdevice_queue was kept.
>
> I think that caused the following bug. In 3.11.6, a simple `modprobe
> sit && rmmod sit` hits the BUG at net/core/dev.c:5039:
>
> BUG_ON(dev->reg_state != NETREG_REGISTERED);
>
> The device is actually NETREG_RELEASED at one point because the device
> is now unregistered twice. The issue goes away by porting the
> remainder of the original commit: the one liner that removes the call
> to unregister_netdevice_queue.
>
> +++ b/net/ipv6/sit.c
> @@ -1708,7 +1708,6 @@ static void __net_exit sit_exit_net(struct net *net)
>
> sit_destroy_tunnels(sitn, &list);
> - unregister_netdevice_queue(sitn->fb_tunnel_dev, &list);
> unregister_netdevice_many(&list);
>
> If correct, let me know if I should send a proper one-line patch
> against 3.11.y. Since I haven't looked at this code before, I found it
> safer to report the issue first.
Yes, this line should be removed, like it was done in the original patch
(x-netns for sit is part of 3.11).
>
> 5e6700b3bf was not applied to 3.10 stable, so that branch is not affected.
Right.
next prev parent reply other threads:[~2013-10-22 7:34 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-01 9:33 [PATCH net v2 1/4] ip_tunnel: Fix a memory corruption in ip_tunnel_xmit Steffen Klassert
2013-10-01 9:34 ` [PATCH net v2 2/4] ip_tunnel: Add fallback tunnels to the hash lists Steffen Klassert
2013-10-01 16:43 ` David Miller
2013-10-01 9:35 ` [PATCH net 3/4] ip_tunnel_core: Change __skb_push back to skb_push Steffen Klassert
2013-10-01 16:43 ` David Miller
2013-10-01 9:37 ` [PATCH net 4/4] ip_tunnel: Remove double unregister of the fallback device Steffen Klassert
2013-10-01 10:00 ` Nicolas Dichtel
2013-10-01 10:40 ` Steffen Klassert
2013-10-01 11:30 ` Nicolas Dichtel
2013-10-01 16:04 ` [PATCH net 1/2] sit: allow to use rtnl ops on fb tunnel Nicolas Dichtel
2013-10-01 16:05 ` [PATCH net 2/2] ip6tnl: " Nicolas Dichtel
2013-10-01 16:59 ` David Miller
2013-10-02 7:16 ` Nicolas Dichtel
2013-10-01 16:59 ` [PATCH net 1/2] sit: " David Miller
2013-10-02 7:15 ` Nicolas Dichtel
2013-10-02 7:36 ` Nicolas Dichtel
2013-10-02 21:08 ` David Miller
2013-10-03 8:06 ` Nicolas Dichtel
2013-10-03 17:37 ` David Miller
2013-10-21 23:30 ` Willem de Bruijn
2013-10-22 7:34 ` Nicolas Dichtel [this message]
2013-10-01 16:43 ` [PATCH net 4/4] ip_tunnel: Remove double unregister of the fallback device David Miller
2013-10-01 16:43 ` [PATCH net v2 1/4] ip_tunnel: Fix a memory corruption in ip_tunnel_xmit 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=52662A94.9000501@6wind.com \
--to=nicolas.dichtel@6wind$(echo .)com \
--cc=davem@davemloft$(echo .)net \
--cc=gregkh@linuxfoundation$(echo .)org \
--cc=netdev@vger$(echo .)kernel.org \
--cc=pshelar@nicira$(echo .)com \
--cc=stable@vger$(echo .)kernel.org \
--cc=steffen.klassert@secunet$(echo .)com \
--cc=willemb@google$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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