Message ID | 148d635697bfb4ac3f9010526a6d79b8ee34316d.1686061295.git.fdmanana@suse.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | btrfs: update documentation for a block group's bg_list member | expand |
Looks good,
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
On Tue, Jun 06, 2023 at 03:26:03PM +0100, fdmanana@kernel.org wrote: > From: Filipe Manana <fdmanana@suse.com> > > Currently we are only documentating two uses of the bg_list member of a > block group, but there two more: > > 1) To track deleted block groups for discard purposes, introduced in > commit e33e17ee1098 ("btrfs: add missing discards when unpinning > extents with -o discard"); > > 2) To track block groups for automatic reclaim, introduced more recently > by commit 18bb8bbf13c1 ("btrfs: zoned: automatically reclaim zones") > > So document those two other use cases. > > Signed-off-by: Filipe Manana <fdmanana@suse.com> Added to misc-next, thanks.
diff --git a/fs/btrfs/block-group.h b/fs/btrfs/block-group.h index cc0e4b37db2d..f204addc3fe8 100644 --- a/fs/btrfs/block-group.h +++ b/fs/btrfs/block-group.h @@ -162,7 +162,14 @@ struct btrfs_block_group { */ struct list_head cluster_list; - /* For delayed block group creation or deletion of empty block groups */ + /* + * Used for several lists: + * + * 1) struct btrfs_fs_info::unused_bgs + * 2) struct btrfs_fs_info::reclaim_bgs + * 3) struct btrfs_transaction::deleted_bgs + * 4) struct btrfs_trans_handle::new_bgs + */ struct list_head bg_list; /* For read-only block groups */