summaryrefslogtreecommitdiffstats
path: root/fs/ext4/page-io.c
diff options
context:
space:
mode:
authorJens Axboe <axboe@fb.com>2016-05-06 04:09:49 +0200
committerTheodore Ts'o <tytso@mit.edu>2016-05-06 04:09:49 +0200
commit32157de29a3140bfaa74c6e0fae18c78fe84a5df (patch)
tree6c7c431e96c4c03b9f7b068e48db4d69adce44cd /fs/ext4/page-io.c
parentext4: silence UBSAN in ext4_mb_init() (diff)
downloadlinux-32157de29a3140bfaa74c6e0fae18c78fe84a5df.tar.xz
linux-32157de29a3140bfaa74c6e0fae18c78fe84a5df.zip
ext4: remove unnecessary bio get/put
ext4_io_submit() used to check for EOPNOTSUPP after bio submission, which is why it had to get an extra reference to the bio before submitting it. But since we no longer touch the bio after submission, get rid of the redundant get/put of the bio. If we do get the extra reference, we enter the slower path of having to flag this bio as now having external references. Signed-off-by: Jens Axboe <axboe@fb.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to '')
-rw-r--r--fs/ext4/page-io.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/ext4/page-io.c b/fs/ext4/page-io.c
index e4fc8ea45d78..2a01df9cc1c3 100644
--- a/fs/ext4/page-io.c
+++ b/fs/ext4/page-io.c
@@ -342,9 +342,7 @@ void ext4_io_submit(struct ext4_io_submit *io)
if (bio) {
int io_op = io->io_wbc->sync_mode == WB_SYNC_ALL ?
WRITE_SYNC : WRITE;
- bio_get(io->io_bio);
submit_bio(io_op, io->io_bio);
- bio_put(io->io_bio);
}
io->io_bio = NULL;
}