aboutsummaryrefslogtreecommitdiffstats
path: root/fs/direct-io.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/direct-io.c')
-rw-r--r--fs/direct-io.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/direct-io.c b/fs/direct-io.c
index 0a073c7125a6..01d2d9ef609c 100644
--- a/fs/direct-io.c
+++ b/fs/direct-io.c
@@ -293,11 +293,12 @@ static ssize_t dio_complete(struct dio *dio, loff_t offset, ssize_t ret, bool is
293 if (dio->end_io && dio->result) { 293 if (dio->end_io && dio->result) {
294 dio->end_io(dio->iocb, offset, transferred, 294 dio->end_io(dio->iocb, offset, transferred,
295 dio->map_bh.b_private, ret, is_async); 295 dio->map_bh.b_private, ret, is_async);
296 } else if (is_async) { 296 } else {
297 aio_complete(dio->iocb, ret, 0); 297 if (is_async)
298 aio_complete(dio->iocb, ret, 0);
299 inode_dio_done(dio->inode);
298 } 300 }
299 301
300 inode_dio_done(dio->inode);
301 return ret; 302 return ret;
302} 303}
303 304