Re: [BUG?] possible recursive locking detected

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 27 Jul 2006 16:51:29 +1000
Nick Piggin <[email protected]> wrote:

> > We hold the ext2 directory mutex, and ntfs_put_inode is trying to take an
> > ntfs i_mutex.  Not a deadlock as such, but it could become one in ntfs if
> > ntfs ever does a __GFP_WAIT allocation inside i_mutex, which it surely
> > does.
> 
> Though it should be using GFP_NOFS, right? So the dcache shrinker would
> not reenter the fs in that case.

Sort-of, arguably.  Many years ago, holding i_mutex (i_sem) was considered
to be "in the fs" and one should use GFP_NOFS.

(This code dates from the ext2 directory-in-pagecache conversion - it's
2.4 stuff.)

It's better, of course, to use GFP_HIGHUSER for pagecache so we should aim
to get this working.  And that means don't-take-i_mutex-on-the-reclaim-path.

We quite possibly are doing that in other places, too.

> I'm surprised ext2 is allocating with __GFP_FS set, though. Would that
> cause any problem?

It might, if ext2 takes i_mutex on the reclaim path.  But it doesn't.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux