Re: [PATCH 3/8] btrfs: Record btrfs_device directly btrfs_io_bio

Johannes Thumshirn
2020-07-02T13:16:12Z

On 02/07/2020 14:40, Nikolay Borisov wrote:
> @@ -6319,7 +6314,7 @@ static void submit_stripe_bio(struct btrfs_bio *bbio, struct bio *bio,
> struct btrfs_fs_info *fs_info = bbio->fs_info;
>
> bio->bi_private = bbio;
> - btrfs_io_bio(bio)->stripe_index = dev_nr;
> + btrfs_io_bio(bio)->dev = dev;
> bio->bi_end_io = btrfs_end_bio;
> bio->bi_iter.bi_sector = physical >> 9;
> btrfs_debug_in_rcu(fs_info,

Can't we just pass in a btrfs_device here (into submit_stripe_bio() that is) instead of dev_nr?