diff options
author | Christoph Hellwig <hch@lst.de> | 2017-08-29 16:13:20 +0200 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2017-09-05 01:04:23 +0200 |
commit | 91f9943e1c7b6638f27312d03fe71fcc67b23571 (patch) | |
tree | bf9c2212d93f4fbf9af6f5fafc2e667fa3d29de1 /fs/aio.c | |
parent | fs: support IOCB_NOWAIT in generic_file_buffered_read (diff) | |
download | linux-91f9943e1c7b6638f27312d03fe71fcc67b23571.tar.xz linux-91f9943e1c7b6638f27312d03fe71fcc67b23571.zip |
fs: support RWF_NOWAIT for buffered reads
This is based on the old idea and code from Milosz Tanski. With the aio
nowait code it becomes mostly trivial now. Buffered writes continue to
return -EOPNOTSUPP if RWF_NOWAIT is passed.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/aio.c')
-rw-r--r-- | fs/aio.c | 6 |
1 files changed, 0 insertions, 6 deletions
@@ -1593,12 +1593,6 @@ static int io_submit_one(struct kioctx *ctx, struct iocb __user *user_iocb, goto out_put_req; } - if ((req->common.ki_flags & IOCB_NOWAIT) && - !(req->common.ki_flags & IOCB_DIRECT)) { - ret = -EOPNOTSUPP; - goto out_put_req; - } - ret = put_user(KIOCB_KEY, &user_iocb->aio_key); if (unlikely(ret)) { pr_debug("EFAULT: aio_key\n"); |