Home
last modified time | relevance | path

Searched refs:global_rsv (Results 1 – 5 of 5) sorted by relevance

/openbmc/linux/fs/btrfs/
H A Dblock-rsv.c277 struct btrfs_block_rsv *global_rsv = &fs_info->global_block_rsv; in btrfs_block_rsv_release() local
286 target = global_rsv; in btrfs_block_rsv_release()
287 else if (block_rsv != global_rsv && !btrfs_block_rsv_full(delayed_rsv)) in btrfs_block_rsv_release()
483 struct btrfs_block_rsv *global_rsv = &fs_info->global_block_rsv; in btrfs_use_block_rsv() local
530 block_rsv->space_info == global_rsv->space_info) { in btrfs_use_block_rsv()
531 ret = btrfs_block_rsv_use_bytes(global_rsv, blocksize); in btrfs_use_block_rsv()
533 return global_rsv; in btrfs_use_block_rsv()
H A Dspace-info.c958 if (global_rsv->space_info != space_info) in steal_from_global_rsv()
961 spin_lock(&global_rsv->lock); in steal_from_global_rsv()
962 min_bytes = mult_perc(global_rsv->size, 10); in steal_from_global_rsv()
963 if (global_rsv->reserved < min_bytes + ticket->bytes) { in steal_from_global_rsv()
964 spin_unlock(&global_rsv->lock); in steal_from_global_rsv()
967 global_rsv->reserved -= ticket->bytes; in steal_from_global_rsv()
972 if (global_rsv->reserved < global_rsv->size) in steal_from_global_rsv()
973 global_rsv->full = 0; in steal_from_global_rsv()
974 spin_unlock(&global_rsv->lock); in steal_from_global_rsv()
1138 struct btrfs_block_rsv *global_rsv; in btrfs_preempt_reclaim_metadata_space() local
[all …]
H A Ddelayed-ref.c34 struct btrfs_block_rsv *global_rsv = &fs_info->global_block_rsv; in btrfs_check_space_for_delayed_refs() local
38 spin_lock(&global_rsv->lock); in btrfs_check_space_for_delayed_refs()
39 reserved = global_rsv->reserved; in btrfs_check_space_for_delayed_refs()
40 spin_unlock(&global_rsv->lock); in btrfs_check_space_for_delayed_refs()
H A Droot-tree.c509 struct btrfs_block_rsv *global_rsv = &fs_info->global_block_rsv; in btrfs_subvolume_reserve_metadata() local
528 ret = btrfs_block_rsv_migrate(global_rsv, rsv, num_bytes, true); in btrfs_subvolume_reserve_metadata()
H A Dextent-tree.c2707 struct btrfs_block_rsv *global_rsv = &fs_info->global_block_rsv; in unpin_extent_range() local
2769 global_rsv->space_info == space_info) { in unpin_extent_range()
2770 spin_lock(&global_rsv->lock); in unpin_extent_range()
2771 if (!global_rsv->full) { in unpin_extent_range()
2772 u64 to_add = min(len, global_rsv->size - in unpin_extent_range()
2773 global_rsv->reserved); in unpin_extent_range()
2775 global_rsv->reserved += to_add; in unpin_extent_range()
2778 if (global_rsv->reserved >= global_rsv->size) in unpin_extent_range()
2779 global_rsv->full = 1; in unpin_extent_range()
2782 spin_unlock(&global_rsv->lock); in unpin_extent_range()