aboutsummaryrefslogtreecommitdiff
path: root/fs/aio.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2013-03-19 21:01:03 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2013-04-09 14:12:55 -0400
commit8d71db4f0890605d44815a2b2da4ca003f1bb142 (patch)
treee5bb078717c3e8ace7f032b940ada7901dbab545 /fs/aio.c
parent5f2e354f5212a49fc639c25de2581cc8ae90d11b (diff)
lift sb_start_write/sb_end_write out of ->aio_write()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/aio.c')
-rw-r--r--fs/aio.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/aio.c b/fs/aio.c
index 3f941f2a305..4ec28f13a92 100644
--- a/fs/aio.c
+++ b/fs/aio.c
@@ -1324,6 +1324,8 @@ static ssize_t aio_rw_vect_retry(struct kiocb *iocb)
if (iocb->ki_pos < 0)
return -EINVAL;
+ if (opcode == IOCB_CMD_PWRITEV)
+ file_start_write(file);
do {
ret = rw_op(iocb, &iocb->ki_iovec[iocb->ki_cur_seg],
iocb->ki_nr_segs - iocb->ki_cur_seg,
@@ -1336,6 +1338,8 @@ static ssize_t aio_rw_vect_retry(struct kiocb *iocb)
} while (ret > 0 && iocb->ki_left > 0 &&
(opcode == IOCB_CMD_PWRITEV ||
(!S_ISFIFO(inode->i_mode) && !S_ISSOCK(inode->i_mode))));
+ if (opcode == IOCB_CMD_PWRITEV)
+ file_end_write(file);
/* This means we must have transferred all that we could */
/* No need to retry anymore */