xfs
[Top] [All Lists]

Re: [PATCH 0/2] splice: i_mutex vs splice write deadlock V2

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH 0/2] splice: i_mutex vs splice write deadlock V2
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Wed, 10 Aug 2011 06:19:21 -0400
Cc: xfs@xxxxxxxxxxx, linux-fsdevel@xxxxxxxxxxxxxxx, mfasheh@xxxxxxxx, jlbec@xxxxxxxxxxxx
In-reply-to: <1312785927-10662-1-git-send-email-david@xxxxxxxxxxxxx>
References: <1312785927-10662-1-git-send-email-david@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
On Mon, Aug 08, 2011 at 04:45:25PM +1000, Dave Chinner wrote:
> generic_file_splice_write() takes the inode->i_mutex after the
> filesystem has taken whatever locks it needs to ensure sanity.
> however, this typically violates the locking order of filesystems
> with their own locks in that the order is usually i_mutex ->
> filesystem lock.
> 
> XFS is such a case, and generic_file_splice_write() is generating
> lockdep warnings because of lock inversions between the
> inode->i_mutex and the XFS_I(inode)->i_iolock. There is also a
> reported case of fio causing a deadlock when it mixes IO types
> (e.g. splice vs direct IO).

Another case is ocfs2, which looks like a perfect candidate to be
converted over to your infrastructure.

<Prev in Thread] Current Thread [Next in Thread>