/kernel/linux/linux-5.10/fs/btrfs/ |
D | space-info.c | 175 struct list_head *head = &info->space_info; in btrfs_clear_space_info_full() 185 struct btrfs_space_info *space_info; in create_space_info() local 189 space_info = kzalloc(sizeof(*space_info), GFP_NOFS); in create_space_info() 190 if (!space_info) in create_space_info() 193 ret = percpu_counter_init(&space_info->total_bytes_pinned, 0, in create_space_info() 196 kfree(space_info); in create_space_info() 201 INIT_LIST_HEAD(&space_info->block_groups[i]); in create_space_info() 202 init_rwsem(&space_info->groups_sem); in create_space_info() 203 spin_lock_init(&space_info->lock); in create_space_info() 204 space_info->flags = flags & BTRFS_BLOCK_GROUP_TYPE_MASK; in create_space_info() [all …]
|
D | space-info.h | 86 static inline bool btrfs_mixed_space_info(struct btrfs_space_info *space_info) in btrfs_mixed_space_info() argument 88 return ((space_info->flags & BTRFS_BLOCK_GROUP_METADATA) && in btrfs_mixed_space_info() 89 (space_info->flags & BTRFS_BLOCK_GROUP_DATA)); in btrfs_mixed_space_info() 123 struct btrfs_space_info **space_info); 137 struct btrfs_space_info *space_info); 139 struct btrfs_space_info *space_info, u64 bytes, 144 struct btrfs_space_info *space_info, in btrfs_space_info_free_bytes_may_use() argument 147 spin_lock(&space_info->lock); in btrfs_space_info_free_bytes_may_use() 148 btrfs_space_info_update_bytes_may_use(fs_info, space_info, -num_bytes); in btrfs_space_info_free_bytes_may_use() 149 btrfs_try_granting_tickets(fs_info, space_info); in btrfs_space_info_free_bytes_may_use() [all …]
|
D | block-rsv.c | 107 struct btrfs_space_info *space_info = block_rsv->space_info; in block_rsv_release_bytes() local 151 space_info, in block_rsv_release_bytes() 185 rsv->space_info = btrfs_find_space_info(fs_info, in btrfs_init_metadata_block_rsv() 291 if (target && block_rsv->space_info != target->space_info) in btrfs_block_rsv_release() 332 if (global_rsv->space_info != dest->space_info) in btrfs_cond_migrate_bytes() 353 struct btrfs_space_info *sinfo = block_rsv->space_info; in btrfs_update_global_block_rsv() 417 struct btrfs_space_info *space_info; in btrfs_init_global_block_rsv() local 419 space_info = btrfs_find_space_info(fs_info, BTRFS_BLOCK_GROUP_SYSTEM); in btrfs_init_global_block_rsv() 420 fs_info->chunk_block_rsv.space_info = space_info; in btrfs_init_global_block_rsv() 422 space_info = btrfs_find_space_info(fs_info, BTRFS_BLOCK_GROUP_METADATA); in btrfs_init_global_block_rsv() [all …]
|
D | block-group.c | 337 struct btrfs_space_info *space_info = bg->space_info; in btrfs_wait_block_group_reservations() local 354 down_write(&space_info->groups_sem); in btrfs_wait_block_group_reservations() 355 up_write(&space_info->groups_sem); in btrfs_wait_block_group_reservations() 664 spin_lock(&block_group->space_info->lock); in caching_thread() 667 block_group->space_info->bytes_used += bytes_used >> 1; in caching_thread() 669 spin_unlock(&block_group->space_info->lock); in caching_thread() 768 spin_lock(&cache->space_info->lock); in btrfs_cache_block_group() 771 cache->space_info->bytes_used += bytes_used >> 1; in btrfs_cache_block_group() 773 spin_unlock(&cache->space_info->lock); in btrfs_cache_block_group() 850 struct list_head *head = &fs_info->space_info; in clear_incompat_bg_bits() [all …]
|
D | sysfs.c | 618 BTRFS_ATTR(space_info, field, btrfs_space_info_show_##field) 638 BTRFS_ATTR(space_info, total_bytes_pinned, 642 BTRFS_ATTR_PTR(space_info, flags), 643 BTRFS_ATTR_PTR(space_info, total_bytes), 644 BTRFS_ATTR_PTR(space_info, bytes_used), 645 BTRFS_ATTR_PTR(space_info, bytes_pinned), 646 BTRFS_ATTR_PTR(space_info, bytes_reserved), 647 BTRFS_ATTR_PTR(space_info, bytes_may_use), 648 BTRFS_ATTR_PTR(space_info, bytes_readonly), 649 BTRFS_ATTR_PTR(space_info, disk_used), [all …]
|
D | sysfs.h | 32 struct btrfs_space_info *space_info); 33 void btrfs_sysfs_remove_space_info(struct btrfs_space_info *space_info);
|
D | extent-tree.c | 2540 spin_lock(&cache->space_info->lock); in pin_down_extent() 2543 btrfs_space_info_update_bytes_pinned(fs_info, cache->space_info, in pin_down_extent() 2547 cache->space_info->bytes_reserved -= num_bytes; in pin_down_extent() 2550 spin_unlock(&cache->space_info->lock); in pin_down_extent() 2552 __btrfs_mod_total_bytes_pinned(cache->space_info, num_bytes); in pin_down_extent() 2695 struct btrfs_space_info *space_info, u64 *empty_cluster) in fetch_cluster_info() argument 2700 if (btrfs_mixed_space_info(space_info)) in fetch_cluster_info() 2703 if (space_info->flags & BTRFS_BLOCK_GROUP_METADATA) { in fetch_cluster_info() 2709 } else if ((space_info->flags & BTRFS_BLOCK_GROUP_DATA) && in fetch_cluster_info() 2723 struct btrfs_space_info *space_info; in unpin_extent_range() local [all …]
|
D | block-rsv.h | 26 struct btrfs_space_info *space_info; member
|
D | block-group.h | 106 struct btrfs_space_info *space_info; member
|
D | free-space-cache.c | 3395 struct btrfs_space_info *space_info = block_group->space_info; in do_trimming() local 3405 spin_lock(&space_info->lock); in do_trimming() 3409 space_info->bytes_reserved += reserved_bytes; in do_trimming() 3413 spin_unlock(&space_info->lock); in do_trimming() 3434 spin_lock(&space_info->lock); in do_trimming() 3437 space_info->bytes_readonly += reserved_bytes; in do_trimming() 3439 space_info->bytes_reserved -= reserved_bytes; in do_trimming() 3441 spin_unlock(&space_info->lock); in do_trimming()
|
D | root-tree.c | 505 rsv->space_info = btrfs_find_space_info(fs_info, in btrfs_subvolume_reserve_metadata()
|
D | disk-io.c | 2736 INIT_LIST_HEAD(&fs_info->space_info); in btrfs_init_fs_info() 4428 spin_lock(&cache->space_info->lock); in btrfs_destroy_delayed_refs() 4432 cache->space_info, head->num_bytes); in btrfs_destroy_delayed_refs() 4434 cache->space_info->bytes_reserved -= head->num_bytes; in btrfs_destroy_delayed_refs() 4436 spin_unlock(&cache->space_info->lock); in btrfs_destroy_delayed_refs() 4438 &cache->space_info->total_bytes_pinned, in btrfs_destroy_delayed_refs()
|
D | transaction.c | 633 if (rsv->space_info->force_alloc) in start_transaction() 723 u64 flags = h->block_rsv->space_info->flags; in start_transaction()
|
D | super.c | 2175 list_for_each_entry(found, &fs_info->space_info, list) { in btrfs_statfs() 2246 if (!mixed && block_rsv->space_info->full && in btrfs_statfs()
|
D | delayed-ref.c | 161 delayed_refs_rsv->space_info, to_free); in btrfs_migrate_to_delayed_refs_rsv()
|
D | tree-log.c | 2700 spin_lock(&cache->space_info->lock); in unaccount_log_buffer() 2703 cache->space_info->bytes_reserved -= fs_info->nodesize; in unaccount_log_buffer() 2705 spin_unlock(&cache->space_info->lock); in unaccount_log_buffer()
|
D | ioctl.c | 3542 list_for_each_entry(tmp, &fs_info->space_info, list) { in btrfs_ioctl_space_info() 3595 list_for_each_entry(tmp, &fs_info->space_info, list) { in btrfs_ioctl_space_info()
|
D | ctree.h | 814 struct list_head space_info; member
|