summaryrefslogtreecommitdiffstats
path: root/fs/ext4/mballoc.c
diff options
context:
space:
mode:
authorDaeho Jeong <daeho.jeong@samsung.com>2017-08-05 13:11:57 -0400
committerTheodore Ts'o <tytso@mit.edu>2017-08-05 13:11:57 -0400
commite45105772db41c5318b2a7ec1c420183183414e3 (patch)
tree8569c5a85cfe6572ef48e4509f3219a7e4dc5169 /fs/ext4/mballoc.c
parent9c5d58fb9e1df8c9ead4daf9e770ce61e4256e02 (diff)
downloadlinux-e45105772db41c5318b2a7ec1c420183183414e3.tar.bz2
ext4: release discard bio after sending discard commands
We've changed the discard command handling into parallel manner. But, in this change, I forgot decreasing the usage count of the bio which was used to send discard request. I'm sorry about that. Fixes: a015434480dc ("ext4: send parallel discards on commit completions") Signed-off-by: Daeho Jeong <daeho.jeong@samsung.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Reviewed-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/ext4/mballoc.c')
-rw-r--r--fs/ext4/mballoc.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c
index 581e357e8406..8779893d74e5 100644
--- a/fs/ext4/mballoc.c
+++ b/fs/ext4/mballoc.c
@@ -2892,8 +2892,10 @@ void ext4_process_freed_data(struct super_block *sb, tid_t commit_tid)
break;
}
- if (discard_bio)
+ if (discard_bio) {
submit_bio_wait(discard_bio);
+ bio_put(discard_bio);
+ }
}
list_for_each_entry_safe(entry, tmp, &freed_data_list, efd_list)