xfs: make xfs_file_aio_write_checks IOCB_NOWAIT-aware
authorChristoph Hellwig <hch@lst.de>
Sat, 23 Jan 2021 18:06:28 +0000 (10:06 -0800)
committerDarrick J. Wong <djwong@kernel.org>
Mon, 1 Feb 2021 17:47:18 +0000 (09:47 -0800)
commit354be7e3b2baf32e63c0599cc131d393591ba299
tree56d22325a46202bb021b4147d6aa32164b1cb24f
parentf50b8f475a2c70ae8309c16b6d4ecb305a4aa9d6
xfs: make xfs_file_aio_write_checks IOCB_NOWAIT-aware

Ensure we don't block on the iolock, or waiting for I/O in
xfs_file_aio_write_checks if the caller asked to avoid that.

Fixes: 29a5d29ec181 ("xfs: nowait aio support")
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
fs/xfs/xfs_file.c