Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-16 Thread David Miller
From: Hannes Frederic Sowa Date: Fri, 8 Apr 2016 22:55:01 +0200 > 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 syn

Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-15 Thread Hannes Frederic Sowa
On 15.04.2016 22:36, David Miller wrote: From: Hannes Frederic Sowa Date: Fri, 8 Apr 2016 22:55:01 +0200 @@ -1053,7 +1052,9 @@ static void __vxlan_sock_release(struct vxlan_sock *vs) vxlan_notify_del_rx_port(vs); spin_unlock(&vn->sock_lock); - queue_work(vxlan_wq, &vs->

Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-15 Thread Marcelo Ricardo Leitner
Em 15-04-2016 17:58, Stephen Hemminger escreveu: On Sat, 09 Apr 2016 01:55:06 +0200 Hannes Frederic Sowa wrote: On Sat, Apr 9, 2016, at 01:24, Cong Wang wrote: On Fri, Apr 8, 2016 at 1:55 PM, Hannes Frederic Sowa wrote: Due to the fact that the udp socket is destructed asynchronously in a

Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-15 Thread Stephen Hemminger
On Sat, 09 Apr 2016 01:55:06 +0200 Hannes Frederic Sowa wrote: > > > On Sat, Apr 9, 2016, at 01:24, Cong Wang wrote: > > On Fri, Apr 8, 2016 at 1:55 PM, Hannes Frederic Sowa > > wrote: > > > Due to the fact that the udp socket is destructed asynchronously in a > > > work queue, we have some no

Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-15 Thread David Miller
From: Hannes Frederic Sowa Date: Fri, 8 Apr 2016 22:55:01 +0200 > @@ -1053,7 +1052,9 @@ static void __vxlan_sock_release(struct vxlan_sock *vs) > vxlan_notify_del_rx_port(vs); > spin_unlock(&vn->sock_lock); > > - queue_work(vxlan_wq, &vs->del_work); > + synchronize_net(); >

Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-08 Thread Hannes Frederic Sowa
On Sat, Apr 9, 2016, at 01:24, Cong Wang wrote: > On Fri, Apr 8, 2016 at 1:55 PM, Hannes Frederic Sowa > 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 o

Re: [PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-08 Thread Cong Wang
On Fri, Apr 8, 2016 at 1:55 PM, Hannes Frederic Sowa 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 synchrono

[PATCH net-next v2] vxlan: synchronously and race-free destruction of vxlan sockets

2016-04-08 Thread Hannes Frederic Sowa
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