summaryrefslogtreecommitdiffstats
path: root/fs/aio.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2015-03-21 19:11:55 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2015-04-11 22:27:10 -0400
commitd4fb392f4c5e57197a43b729e6fad5e02e5acaca (patch)
tree4c41baf749a79a07c5232d9150ff58cea5729766 /fs/aio.c
parent36e9f6535f398952772df5238b23e795a2810f86 (diff)
downloadlinux-d4fb392f4c5e57197a43b729e6fad5e02e5acaca.tar.bz2
kill aio_setup_single_vector()
identical to import_single_range() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/aio.c')
-rw-r--r--fs/aio.c18
1 files changed, 1 insertions, 17 deletions
diff --git a/fs/aio.c b/fs/aio.c
index 2ba172cfdeba..3dba5a70ad97 100644
--- a/fs/aio.c
+++ b/fs/aio.c
@@ -1376,21 +1376,6 @@ static int aio_setup_vectored_rw(int rw, char __user *buf, size_t len,
return 0;
}
-static int aio_setup_single_vector(int rw, char __user *buf, size_t len,
- struct iovec *iovec,
- struct iov_iter *iter)
-{
- if (len > MAX_RW_COUNT)
- len = MAX_RW_COUNT;
- if (unlikely(!access_ok(!rw, buf, len)))
- return -EFAULT;
-
- iovec->iov_base = buf;
- iovec->iov_len = len;
- iov_iter_init(iter, rw, iovec, 1, len);
- return 0;
-}
-
/*
* aio_run_iocb:
* Performs the initial checks and io submission.
@@ -1434,8 +1419,7 @@ rw_common:
ret = aio_setup_vectored_rw(rw, buf, len,
&iovec, compat, &iter);
else
- ret = aio_setup_single_vector(rw, buf, len,
- iovec, &iter);
+ ret = import_single_range(rw, buf, len, iovec, &iter);
if (!ret)
ret = rw_verify_area(rw, file, &req->ki_pos,
iov_iter_count(&iter));