mirror of
https://github.com/kdave/btrfs-progs
synced 2025-02-06 12:52:01 +00:00
btrfs-progs: fi usage: use btrfs_bg_type_to_sub_stripes in calc_chunk_size
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
cb0b63cd90
commit
86f7cc0ee1
@ -819,7 +819,7 @@ static u64 calc_chunk_size(struct chunk_info *ci)
|
||||
else if (ci->type & BTRFS_BLOCK_GROUP_RAID56_MASK)
|
||||
return ci->size / (ci->num_stripes - btrfs_bg_type_to_nparity(ci->type));
|
||||
else if (ci->type & BTRFS_BLOCK_GROUP_RAID10)
|
||||
return ci->size / (ci->num_stripes / 2);
|
||||
return ci->size / (ci->num_stripes / btrfs_bg_type_to_sub_stripes(ci->type));
|
||||
return ci->size;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user