]> git.hungrycats.org Git - linux/commit
btrfs: stripe_meta: let a group go read-only for relocation against the reserve
authorZygo Blaxell <ce3g8jdj@umail.furryterror.org>
Sun, 6 Sep 2026 13:54:37 +0000 (09:54 -0400)
committerZygo Blaxell <ce3g8jdj@umail.furryterror.org>
Wed, 16 Sep 2026 21:40:05 +0000 (17:40 -0400)
commitb3ea6b9817a9695e6bebcecd5561a40c6d461a51
tree29d94012076244d1f65941f13dd882844609ed4a
parent8072ad7afd9d89cabdb6eb47becebff2e2addfb0
btrfs: stripe_meta: let a group go read-only for relocation against the reserve

The read-only guard keeps admitted bytes placeable by refusing to take a
group's usable free space out of the supply when the space_info could
not absorb it.  With the whole-stripe reserve counted as used, that
refusal comes by the width of the reserve at the fill edge: two
eligible metadata groups sat marked for reclaim through a 300 second
wait and the worker dropped each on inc_block_group_ro() -- the
space_info was 7 MiB short of the check with 376 MiB of whole stripes
claimable, 352 MiB of them the reserve that exists for this move.

Going read-only is the first step of relocation, so let the guard draw
on the reserve the way relocation's own reservations do.

Assisted-by: Claude:claude-fable-5
fs/btrfs/block-group.c