Skip to content

Commit

Permalink
Merge tag 'for-6.6-rc6-tag' of git://git.kernel.org/pub/scm/linux/ker…
Browse files Browse the repository at this point in the history
…nel/git/kdave/linux

Pull btrfs fix from David Sterba:
 "Fix a bug in chunk size decision that could lead to suboptimal
  placement and filling patterns"

* tag 'for-6.6-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
  btrfs: fix stripe length calculation for non-zoned data chunk allocation
  • Loading branch information
Linus Torvalds committed Oct 19, 2023
2 parents dd72f9c + 8a540e9 commit 7cf4bea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/btrfs/volumes.c
Original file line number Diff line number Diff line change
Expand Up @@ -5109,7 +5109,7 @@ static void init_alloc_chunk_ctl_policy_regular(
ASSERT(space_info);

ctl->max_chunk_size = READ_ONCE(space_info->chunk_size);
ctl->max_stripe_size = ctl->max_chunk_size;
ctl->max_stripe_size = min_t(u64, ctl->max_chunk_size, SZ_1G);

if (ctl->type & BTRFS_BLOCK_GROUP_SYSTEM)
ctl->devs_max = min_t(int, ctl->devs_max, BTRFS_MAX_DEVS_SYS_CHUNK);
Expand Down

0 comments on commit 7cf4bea

Please sign in to comment.