diff options
author | David Sterba <dsterba@suse.com> | 2017-06-02 17:38:30 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2017-06-19 18:26:02 +0200 |
commit | 3aa8e074ab2ec507b7380dd5d460fea83d92b66b (patch) | |
tree | 76a454c2c41ca3af6dd286e823a6437e1ebf36a1 /fs/btrfs/volumes.c | |
parent | 0c4dd97c5efddd6cac144d73635962ce6e48165b (diff) | |
download | lwn-3aa8e074ab2ec507b7380dd5d460fea83d92b66b.tar.gz lwn-3aa8e074ab2ec507b7380dd5d460fea83d92b66b.zip |
btrfs: btrfs_bio_clone never fails, skip error handling
Update direct callers of btrfs_bio_clone that do error handling, that we
can now remove.
Reviewed-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/volumes.c')
-rw-r--r-- | fs/btrfs/volumes.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index e28c113785bb..ea9912157a56 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -6255,10 +6255,9 @@ int btrfs_map_bio(struct btrfs_fs_info *fs_info, struct bio *bio, continue; } - if (dev_nr < total_devs - 1) { + if (dev_nr < total_devs - 1) bio = btrfs_bio_clone(first_bio, GFP_NOFS); - BUG_ON(!bio); /* -ENOMEM */ - } else + else bio = first_bio; submit_stripe_bio(bbio, bio, bbio->stripes[dev_nr].physical, |