summaryrefslogtreecommitdiff
path: root/fs/read_write.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2015-04-04 05:10:20 +0300
committerAl Viro <viro@zeniv.linux.org.uk>2015-04-12 05:29:42 +0300
commit9a219bc70b54523c8f14a3c957179854785ee97c (patch)
tree6ac486e87780c2aaeb3b77290ee54e189ebc0973 /fs/read_write.c
parent6c09e94a32e1094983d39879b9e8ccf9ffdcfa36 (diff)
downloadlinux-9a219bc70b54523c8f14a3c957179854785ee97c.tar.xz
kill do_sync_read/do_sync_write
all remaining instances of aio_{read,write} (all 4 of them) have explicit ->read and ->write resp.; do_sync_read/do_sync_write is never called by __vfs_read/__vfs_write anymore and no other users had been left. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/read_write.c')
-rw-r--r--fs/read_write.c38
1 files changed, 0 insertions, 38 deletions
diff --git a/fs/read_write.c b/fs/read_write.c
index 3ae8eee3b82a..3d42d8ee5940 100644
--- a/fs/read_write.c
+++ b/fs/read_write.c
@@ -410,23 +410,6 @@ int rw_verify_area(int read_write, struct file *file, const loff_t *ppos, size_t
return count > MAX_RW_COUNT ? MAX_RW_COUNT : count;
}
-ssize_t do_sync_read(struct file *filp, char __user *buf, size_t len, loff_t *ppos)
-{
- struct iovec iov = { .iov_base = buf, .iov_len = len };
- struct kiocb kiocb;
- ssize_t ret;
-
- init_sync_kiocb(&kiocb, filp);
- kiocb.ki_pos = *ppos;
-
- ret = filp->f_op->aio_read(&kiocb, &iov, 1, kiocb.ki_pos);
- BUG_ON(ret == -EIOCBQUEUED);
- *ppos = kiocb.ki_pos;
- return ret;
-}
-
-EXPORT_SYMBOL(do_sync_read);
-
static ssize_t new_sync_read(struct file *filp, char __user *buf, size_t len, loff_t *ppos)
{
struct iovec iov = { .iov_base = buf, .iov_len = len };
@@ -449,8 +432,6 @@ ssize_t __vfs_read(struct file *file, char __user *buf, size_t count,
{
if (file->f_op->read)
return file->f_op->read(file, buf, count, pos);
- else if (file->f_op->aio_read)
- return do_sync_read(file, buf, count, pos);
else if (file->f_op->read_iter)
return new_sync_read(file, buf, count, pos);
else
@@ -485,23 +466,6 @@ ssize_t vfs_read(struct file *file, char __user *buf, size_t count, loff_t *pos)
EXPORT_SYMBOL(vfs_read);
-ssize_t do_sync_write(struct file *filp, const char __user *buf, size_t len, loff_t *ppos)
-{
- struct iovec iov = { .iov_base = (void __user *)buf, .iov_len = len };
- struct kiocb kiocb;
- ssize_t ret;
-
- init_sync_kiocb(&kiocb, filp);
- kiocb.ki_pos = *ppos;
-
- ret = filp->f_op->aio_write(&kiocb, &iov, 1, kiocb.ki_pos);
- BUG_ON(ret == -EIOCBQUEUED);
- *ppos = kiocb.ki_pos;
- return ret;
-}
-
-EXPORT_SYMBOL(do_sync_write);
-
static ssize_t new_sync_write(struct file *filp, const char __user *buf, size_t len, loff_t *ppos)
{
struct iovec iov = { .iov_base = (void __user *)buf, .iov_len = len };
@@ -524,8 +488,6 @@ ssize_t __vfs_write(struct file *file, const char __user *p, size_t count,
{
if (file->f_op->write)
return file->f_op->write(file, p, count, pos);
- else if (file->f_op->aio_write)
- return do_sync_write(file, p, count, pos);
else if (file->f_op->write_iter)
return new_sync_write(file, p, count, pos);
else