Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-06-02 Thread Mel Gorman
On Thu, May 28, 2015 at 07:24:34AM -0400, Jeff Layton wrote: > > > 1) this is not done under a lock, so the non-atomic ++/-- is racy if > > > there are multiple swapons/swapoffs running concurrently on the same > > > xprt. Shouldn't those use an atomic? > > > > > > > It would be more appropriate

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-28 Thread Jeff Layton
On Thu, 28 May 2015 10:56:14 -0400 Trond Myklebust wrote: > On Thu, May 28, 2015 at 10:20 AM, Jerome Marchand wrote: > > On 05/28/2015 01:53 PM, Jeff Layton wrote: > >> On Tue, 26 May 2015 15:20:46 +0200 > >> Jerome Marchand wrote: > >> > >>> > >>> Commit dad2b015 added an rcu read lock around

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-28 Thread Trond Myklebust
On Thu, May 28, 2015 at 10:20 AM, Jerome Marchand wrote: > On 05/28/2015 01:53 PM, Jeff Layton wrote: >> On Tue, 26 May 2015 15:20:46 +0200 >> Jerome Marchand wrote: >> >>> >>> Commit dad2b015 added an rcu read lock around the call to xs_swapper() >>> in nfs_activate()/deactivate(), which can sle

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-28 Thread Jerome Marchand
On 05/28/2015 01:53 PM, Jeff Layton wrote: > On Tue, 26 May 2015 15:20:46 +0200 > Jerome Marchand wrote: > >> >> Commit dad2b015 added an rcu read lock around the call to xs_swapper() >> in nfs_activate()/deactivate(), which can sleep, thus raising a bug at >> each swapon and swapoff over NFS. >>

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-28 Thread Jeff Layton
On Tue, 26 May 2015 15:20:46 +0200 Jerome Marchand wrote: > > Commit dad2b015 added an rcu read lock around the call to xs_swapper() > in nfs_activate()/deactivate(), which can sleep, thus raising a bug at > each swapon and swapoff over NFS. > I'm not sure if this is related or not, but swapoff

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-28 Thread Jeff Layton
On Thu, 28 May 2015 09:26:19 +0100 Mel Gorman wrote: > On Tue, May 26, 2015 at 09:29:29PM -0400, Jeff Layton wrote: > > On Tue, 26 May 2015 09:56:14 -0400 > > Jeff Layton wrote: > > > > > On Tue, 26 May 2015 15:20:46 +0200 > > > Jerome Marchand wrote: > > > > > > > > > > > Commit dad2b015 ad

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-28 Thread Mel Gorman
On Tue, May 26, 2015 at 09:29:29PM -0400, Jeff Layton wrote: > On Tue, 26 May 2015 09:56:14 -0400 > Jeff Layton wrote: > > > On Tue, 26 May 2015 15:20:46 +0200 > > Jerome Marchand wrote: > > > > > > > > Commit dad2b015 added an rcu read lock around the call to xs_swapper() > > > in nfs_activat

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-26 Thread Jeff Layton
On Tue, 26 May 2015 09:56:14 -0400 Jeff Layton wrote: > On Tue, 26 May 2015 15:20:46 +0200 > Jerome Marchand wrote: > > > > > Commit dad2b015 added an rcu read lock around the call to xs_swapper() > > in nfs_activate()/deactivate(), which can sleep, thus raising a bug at > > each swapon and sw

Re: swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-26 Thread Jeff Layton
On Tue, 26 May 2015 15:20:46 +0200 Jerome Marchand wrote: > > Commit dad2b015 added an rcu read lock around the call to xs_swapper() > in nfs_activate()/deactivate(), which can sleep, thus raising a bug at > each swapon and swapoff over NFS. > I'm not sure if this is related or not, but swapoff

swap: nfs: Sleeping function called from an rcu read section in nfs_swap_activate

2015-05-26 Thread Jerome Marchand
Commit dad2b015 added an rcu read lock around the call to xs_swapper() in nfs_activate()/deactivate(), which can sleep, thus raising a bug at each swapon and swapoff over NFS. I'm not sure if this is related or not, but swapoff also triggers the WARN_ON(sk->sk_forward_alloc) in sk_clear_memalloc()