Re: [PATCH 08/13] btrfs: factor out block mapping for RAID5/6

From: Johannes Thumshirn
Date: Wed Dec 13 2023 - 04:04:12 EST


On 13.12.23 09:53, Christoph Hellwig wrote:
>> +static void map_blocks_for_raid56(struct btrfs_chunk_map *map,
>> + enum btrfs_map_op op,
>> + struct btrfs_io_geometry *io_geom,
>> + u64 logical, u64 *length)
>> +{
>> + int data_stripes = nr_data_stripes(map);
>> +
>> + if (op != BTRFS_MAP_READ || io_geom->mirror_num > 1) {
>
> Any reason to not have separate read/write helpers here given that
> they don't really share anything?
>

Nope, can do sure.