On Sunday 20 July 2008 10:13:50 pm David Woodhouse wrote:
> On Mon, 2008-07-21 at 00:41 +0530, Balaji Rao wrote:
> > Hi,
> >
> > There's a problem in btrfs_readdir that tries to lock a root node with
> > one being held. This happens when NFS calls vfs_readdir function with a
> > nfs specific filldir function pointer. This filldir function, called with
> > the lock held calls btrfs_lookup, which tries to take the same lock. So,
> > it keeps waiting on lock_page indefinitely - a deadlock. This is not seen
> > if the inode is RAM in which case, lookup is not called.
>
> We've seen precisely this problem (nfs3 readdirplus calling ->lookup
> from within ->readdir and deadlocking) in a number of other file
> systems.
>
oh, ok!

> I have an evil workaround hack for JFFS2 at
> http://lists.infradead.org/pipermail/linux-mtd/2007-March/017663.html
>
The idea of the patch seems correct to me, that once we "own" the lock, an 
attempt to take it again should be a nop.

Balaji
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to