diff options
author | Jens Axboe <axboe@fb.com> | 2016-05-06 02:09:49 (GMT) |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2016-05-06 02:09:49 (GMT) |
commit | 32157de29a3140bfaa74c6e0fae18c78fe84a5df (patch) | |
tree | 6c7c431e96c4c03b9f7b068e48db4d69adce44cd | |
parent | 935244cd54b86ca46e69bc6604d2adfb1aec2d42 (diff) | |
download | linux-32157de29a3140bfaa74c6e0fae18c78fe84a5df.tar.xz |
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>
-rw-r--r-- | fs/ext4/page-io.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/ext4/page-io.c b/fs/ext4/page-io.c index e4fc8ea..2a01df9 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; } |