On 22.05.25 23:06, Sasha Levin wrote:
This is a note to let you know that I've just added the patch titled
btrfs: zoned: exit btrfs_can_activate_zone if BTRFS_FS_NEED_ZONE_FINISH is set
to the 6.14-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git%3Ba=su...
The filename of the patch is: btrfs-zoned-exit-btrfs_can_activate_zone-if-btrfs_fs.patch and it can be found in the queue-6.14 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let stable@vger.kernel.org know about it.
Hey Sasha,
this patch is just a readability cleanup, no reason to backport it.
Thanks, Johannes
commit 1136d333d91088ecf2d5189367540a84e60449a0 Author: Johannes Thumshirn johannes.thumshirn@wdc.com Date: Wed Feb 12 15:05:00 2025 +0100
btrfs: zoned: exit btrfs_can_activate_zone if BTRFS_FS_NEED_ZONE_FINISH is set [ Upstream commit 26b38e28162ef4ceb1e0482299820fbbd7dbcd92 ] If BTRFS_FS_NEED_ZONE_FINISH is already set for the whole filesystem, exit early in btrfs_can_activate_zone(). There's no need to check if BTRFS_FS_NEED_ZONE_FINISH needs to be set if it is already set. Reviewed-by: Naohiro Aota <naohiro.aota@wdc.com> Signed-off-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
diff --git a/fs/btrfs/zoned.c b/fs/btrfs/zoned.c index f39656668967c..4a3e02b49f295 100644 --- a/fs/btrfs/zoned.c +++ b/fs/btrfs/zoned.c @@ -2344,6 +2344,9 @@ bool btrfs_can_activate_zone(struct btrfs_fs_devices *fs_devices, u64 flags) if (!btrfs_is_zoned(fs_info)) return true;
- if (test_bit(BTRFS_FS_NEED_ZONE_FINISH, &fs_info->flags))
return false;
- /* Check if there is a device with active zones left */ mutex_lock(&fs_info->chunk_mutex); spin_lock(&fs_info->zone_active_bgs_lock);