[PATCH] tipc: ensure skb->lock is initialised

2019-07-07 Thread Chris Packham
tipc_named_node_up() creates a skb list. It passes the list to tipc_node_xmit() which has some code paths that can call skb_queue_purge() which relies on the list->lock being initialised. Ensure tipc_named_node_up() uses skb_queue_head_init() so that the lock is explicitly initialised. Signed-off-

Re: [PATCH] tipc: ensure skb->lock is initialised

2019-07-10 Thread Chris Packham
rg; tipc-discuss...@lists.sourceforge.net; linux- >> ker...@vger.kernel.org >> Subject: Re: [PATCH] tipc: ensure skb->lock is initialised >> >> >> >> On 7/9/19 10:15 PM, Jon Maloy wrote: >>> >>> It is not only for lockdep purposes, -it is essent

RE: [PATCH] tipc: ensure skb->lock is initialised

2019-07-11 Thread Jon Maloy
; >> ; ying@windriver.com; > >> da...@davemloft.net > >> Cc: net...@vger.kernel.org; tipc-discuss...@lists.sourceforge.net; > >> linux- ker...@vger.kernel.org > >> Subject: Re: [PATCH] tipc: ensure skb->lock is initialised > >> > >&g

Re: [PATCH] tipc: ensure skb->lock is initialised

2019-07-08 Thread Eric Dumazet
On 7/8/19 12:53 AM, Chris Packham wrote: > tipc_named_node_up() creates a skb list. It passes the list to > tipc_node_xmit() which has some code paths that can call > skb_queue_purge() which relies on the list->lock being initialised. > Ensure tipc_named_node_up() uses skb_queue_head_init() so t

Re: [PATCH] tipc: ensure skb->lock is initialised

2019-07-08 Thread Chris Packham
On 8/07/19 8:18 PM, Eric Dumazet wrote: > > > On 7/8/19 12:53 AM, Chris Packham wrote: >> tipc_named_node_up() creates a skb list. It passes the list to >> tipc_node_xmit() which has some code paths that can call >> skb_queue_purge() which relies on the list->lock being initialised. >> Ensure tip

Re: [PATCH] tipc: ensure skb->lock is initialised

2019-07-08 Thread Chris Packham
On 9/07/19 8:43 AM, Chris Packham wrote: > On 8/07/19 8:18 PM, Eric Dumazet wrote: >> >> >> On 7/8/19 12:53 AM, Chris Packham wrote: >>> tipc_named_node_up() creates a skb list. It passes the list to >>> tipc_node_xmit() which has some code paths that can call >>> skb_queue_purge() which relies on

Re: [PATCH] tipc: ensure skb->lock is initialised

2019-07-09 Thread Eric Dumazet
On 7/8/19 11:13 PM, Chris Packham wrote: > On 9/07/19 8:43 AM, Chris Packham wrote: >> On 8/07/19 8:18 PM, Eric Dumazet wrote: >>> >>> >>> On 7/8/19 12:53 AM, Chris Packham wrote: tipc_named_node_up() creates a skb list. It passes the list to tipc_node_xmit() which has some code paths

RE: [PATCH] tipc: ensure skb->lock is initialised

2019-07-09 Thread Jon Maloy
rg > Subject: Re: [PATCH] tipc: ensure skb->lock is initialised > > > > On 7/8/19 11:13 PM, Chris Packham wrote: > > On 9/07/19 8:43 AM, Chris Packham wrote: > >> On 8/07/19 8:18 PM, Eric Dumazet wrote: > >>> > >>> > >>> On 7/8/19

Re: [PATCH] tipc: ensure skb->lock is initialised

2019-07-09 Thread Eric Dumazet
rg; tipc-discuss...@lists.sourceforge.net; linux- >> ker...@vger.kernel.org >> Subject: Re: [PATCH] tipc: ensure skb->lock is initialised >> >> >> >> On 7/8/19 11:13 PM, Chris Packham wrote: >>> On 9/07/19 8:43 AM, Chris Packham wrote: >&g

RE: [PATCH] tipc: ensure skb->lock is initialised

2019-07-09 Thread Jon Maloy
l.org > Subject: Re: [PATCH] tipc: ensure skb->lock is initialised > > > > On 7/9/19 3:25 PM, Jon Maloy wrote: [...] > > TIPC is using the list lock at message reception within the scope of > tipc_sk_rcv()/tipc_skb_peek_port(), so it is fundamental that the lock alw

Re: [PATCH] tipc: ensure skb->lock is initialised

2019-07-10 Thread Eric Dumazet
On 7/9/19 10:15 PM, Jon Maloy wrote: > > It is not only for lockdep purposes, -it is essential. But please provide > details about where you see that more fixes are needed. > Simple fact that you detect a problem only when skb_queue_purge() is called should talk by itself. As I stated, th

RE: [PATCH] tipc: ensure skb->lock is initialised

2019-07-10 Thread Jon Maloy
l.org > Subject: Re: [PATCH] tipc: ensure skb->lock is initialised > > > > On 7/9/19 10:15 PM, Jon Maloy wrote: > > > > It is not only for lockdep purposes, -it is essential. But please provide > > details > about where you see that more fixes ar