]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: prevent against ioend livelocks in xfs_file_fsync
authorChristoph Hellwig <hch@infradead.org>
Tue, 26 Jul 2011 15:07:11 +0000 (15:07 +0000)
committerAlex Elder <aelder@sgi.com>
Wed, 27 Jul 2011 03:06:39 +0000 (22:06 -0500)
commitad63b472a082f7948b4eed7f43c8c5cf946865d6
tree683b74f000cd28d260674e767255e0284a9587d7
parent8746b76462ef0f0dce70ba389b6d9f03db486fb0
xfs: prevent against ioend livelocks in xfs_file_fsync

We need to take some locks to prevent new ioends from coming in when we wait
for all existing ones to go away.  Up to Linux 3.0 that was done using the
i_mutex held by the VFS fsync code, but now that we are called without
it we need to take care of it ourselves.  Use the I/O lock instead of
i_mutex just like we do in other places.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Alex Elder <aelder@sgi.com>
fs/xfs/linux-2.6/xfs_file.c