From: Nikolay Borisov Date: Fri, 18 Sep 2020 13:34:35 +0000 (+0300) Subject: btrfs: call submit_bio_hook directly in submit_one_bio X-Git-Tag: v5.10.7~1090^2~37 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cd0537449c275ca7da6f6e3ea2389ae5225c6b4e;p=platform%2Fkernel%2Flinux-rpi.git btrfs: call submit_bio_hook directly in submit_one_bio BTRFS has 2 inode types (for the purposes of the code in submit_one_bio) - ordinary data inodes (including the freespace inode) and the btree inode. Both of these implement submit_bio_hook so btrfsic_submit_bio can never be called from submit_one_bio so just remove it. Signed-off-by: Nikolay Borisov Reviewed-by: David Sterba Signed-off-by: David Sterba --- diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index 6cee6b6..1a96251 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c @@ -168,11 +168,8 @@ int __must_check submit_one_bio(struct bio *bio, int mirror_num, bio->bi_private = NULL; - if (tree->ops) - ret = tree->ops->submit_bio_hook(tree->private_data, bio, - mirror_num, bio_flags); - else - btrfsic_submit_bio(bio); + ret = tree->ops->submit_bio_hook(tree->private_data, bio, mirror_num, + bio_flags); return blk_status_to_errno(ret); }