Skip to content

Commit aadb164

Browse files
fdmananakdave
authored andcommitted
btrfs: update documentation for a block group's bg_list member
Currently we are only documenting 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 e33e17e ("btrfs: add missing discards when unpinning extents with -o discard"); 2) To track block groups for automatic reclaim, introduced more recently by commit 18bb8bb ("btrfs: zoned: automatically reclaim zones") So document those two other use cases. Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
1 parent 7e27180 commit aadb164

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

fs/btrfs/block-group.h

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,14 @@ struct btrfs_block_group {
162162
*/
163163
struct list_head cluster_list;
164164

165-
/* For delayed block group creation or deletion of empty block groups */
165+
/*
166+
* Used for several lists:
167+
*
168+
* 1) struct btrfs_fs_info::unused_bgs
169+
* 2) struct btrfs_fs_info::reclaim_bgs
170+
* 3) struct btrfs_transaction::deleted_bgs
171+
* 4) struct btrfs_trans_handle::new_bgs
172+
*/
166173
struct list_head bg_list;
167174

168175
/* For read-only block groups */

0 commit comments

Comments
 (0)