]> git.hungrycats.org Git - linux/commitdiff
btrfs: stripe_alloc: allow-rmw policy, and write-in-place for isolated nocow extents...
authorZygo Blaxell <ce3g8jdj@umail.furryterror.org>
Sat, 19 Sep 2026 17:17:40 +0000 (13:17 -0400)
committerZygo Blaxell <ce3g8jdj@umail.furryterror.org>
Mon, 2 Nov 2026 02:16:30 +0000 (21:16 -0500)
The hunks of "btrfs: stripe_alloc: allow-rmw policy, and write-in-place
for isolated nocow extents" (earlier in this series) that need code from
"btrfs: add a write-hole invariant checker to the raid56 write path",
which comes after it in this series: they are applied here, once "btrfs:
add a write-hole invariant checker to the raid56 write path" is in,
instead of with the rest of "btrfs: stripe_alloc: allow-rmw policy, and
write-in-place for isolated nocow extents".

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

index b24cabbd7a2abcadf3caa2a647142c15b1a915ba..6ecfd21c3e2d783535d87df3bff411a82c925053 100644 (file)
@@ -3047,7 +3047,8 @@ void btrfs_stripe_check_write(struct btrfs_fs_info *fs_info,
        if (!bg)
                return;
        if (!btrfs_is_stripe_alloc_bg(bg) ||
-           test_bit(BLOCK_GROUP_FLAG_STRIPE_RELOC_USED, &bg->runtime_flags))
+           test_bit(BLOCK_GROUP_FLAG_STRIPE_RELOC_USED, &bg->runtime_flags) ||
+           test_bit(BLOCK_GROUP_FLAG_STRIPE_NOCOW_USED, &bg->runtime_flags))
                goto out;
        fsl = bg->full_stripe_len;
        spin_lock_irqsave(&bg->stripe_run_lock, flags);