From: Stephen Hemminger <stephen@networkplumber.org>
To: Hannes Frederic Sowa <hannes@stressinduktion.org>
Cc: Cong Wang <xiyou.wangcong@gmail.com>,
Linux Kernel Network Developers <netdev@vger.kernel.org>,
Eric Dumazet <eric.dumazet@gmail.com>,
Jiri Benc <jbenc@redhat.com>,
Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
Subject: Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets
Date: Fri, 15 Apr 2016 13:58:32 -0700 [thread overview]
Message-ID: <20160415135832.773707e3@xeon-e3> (raw)
In-Reply-To: <1460159706.2880965.573380353.39845928@webmail.messagingengine.com>
On Sat, 09 Apr 2016 01:55:06 +0200
Hannes Frederic Sowa <hannes@stressinduktion.org> wrote:
>
>
> On Sat, Apr 9, 2016, at 01:24, Cong Wang wrote:
> > On Fri, Apr 8, 2016 at 1:55 PM, Hannes Frederic Sowa
> > <hannes@stressinduktion.org> wrote:
> > > Due to the fact that the udp socket is destructed asynchronously in a
> > > work queue, we have some nondeterministic behavior during shutdown of
> > > vxlan tunnels and creating new ones. Fix this by keeping the destruction
> > > process synchronous in regards to the user space process so IFF_UP can
> > > be reliably set.
> > >
> > > udp_tunnel_sock_release destroys vs->sock->sk if reference counter
> > > indicates so. We expect to have the same lifetime of vxlan_sock and
> > > vxlan_sock->sock->sk even in fast paths with only rcu locks held. So
> > > only destruct the whole socket after we can be sure it cannot be found
> > > by searching vxlan_net->sock_list.
> > >
> >
> > I am wondering what is the reason why we used work queue from
> > the beginning?
>
> I actually don't know. It was like that from the beginning. I cc'ed
> Stephen, maybe he remembers?
>
> Bye,
> Hannes
The problem was that VXLAN needs to update multicast settings and that
can't be done under RTNL.
next prev parent reply other threads:[~2016-04-15 20:58 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-08 20:55 [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets Hannes Frederic Sowa
2016-04-08 23:24 ` Cong Wang
2016-04-08 23:55 ` Hannes Frederic Sowa
2016-04-15 20:58 ` Stephen Hemminger [this message]
2016-04-15 21:47 ` Marcelo Ricardo Leitner
2016-04-15 20:36 ` David Miller
2016-04-15 21:50 ` Hannes Frederic Sowa
2016-04-16 22:23 ` 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=20160415135832.773707e3@xeon-e3 \
--to=stephen@networkplumber.org \
--cc=eric.dumazet@gmail.com \
--cc=hannes@stressinduktion.org \
--cc=jbenc@redhat.com \
--cc=marcelo.leitner@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=xiyou.wangcong@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