aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/btrfs/disk-io.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c
index c54aec87e89d..53c5ea702799 100644
--- a/fs/btrfs/disk-io.c
+++ b/fs/btrfs/disk-io.c
@@ -840,15 +840,15 @@ static int btree_submit_bio_hook(struct inode *inode, int rw, struct bio *bio,
840{ 840{
841 int ret; 841 int ret;
842 842
843 ret = btrfs_bio_wq_end_io(BTRFS_I(inode)->root->fs_info,
844 bio, 1);
845 BUG_ON(ret);
846
847 if (!(rw & REQ_WRITE)) { 843 if (!(rw & REQ_WRITE)) {
844
848 /* 845 /*
849 * called for a read, do the setup so that checksum validation 846 * called for a read, do the setup so that checksum validation
850 * can happen in the async kernel threads 847 * can happen in the async kernel threads
851 */ 848 */
849 ret = btrfs_bio_wq_end_io(BTRFS_I(inode)->root->fs_info,
850 bio, 1);
851 BUG_ON(ret);
852 return btrfs_map_bio(BTRFS_I(inode)->root, rw, bio, 852 return btrfs_map_bio(BTRFS_I(inode)->root, rw, bio,
853 mirror_num, 0); 853 mirror_num, 0);
854 } 854 }