xfs: wait for direct I/O to complete in fsync and write_inode
We need to wait for all pending direct I/O requests before taking care of metadata in fsync and write_inode. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <david@fromorbit.com>
This commit is contained in:

committed by
Alex Elder

parent
fce1cad651
commit
37bc5743fd
@@ -115,6 +115,8 @@ xfs_file_fsync(
|
||||
|
||||
xfs_iflags_clear(ip, XFS_ITRUNCATED);
|
||||
|
||||
xfs_ioend_wait(ip);
|
||||
|
||||
/*
|
||||
* We always need to make sure that the required inode state is safe on
|
||||
* disk. The inode might be clean but we still might need to force the
|
||||
|
Reference in New Issue
Block a user