diff options
Diffstat (limited to 'fs/btrfs/ctree.h')
-rw-r--r-- | fs/btrfs/ctree.h | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h index c72ead869507..8fd9fe4282f5 100644 --- a/fs/btrfs/ctree.h +++ b/fs/btrfs/ctree.h | |||
@@ -2900,6 +2900,18 @@ void btrfs_create_pending_block_groups(struct btrfs_trans_handle *trans, | |||
2900 | u64 btrfs_reduce_alloc_profile(struct btrfs_root *root, u64 flags); | 2900 | u64 btrfs_reduce_alloc_profile(struct btrfs_root *root, u64 flags); |
2901 | u64 btrfs_get_alloc_profile(struct btrfs_root *root, int data); | 2901 | u64 btrfs_get_alloc_profile(struct btrfs_root *root, int data); |
2902 | void btrfs_clear_space_info_full(struct btrfs_fs_info *info); | 2902 | void btrfs_clear_space_info_full(struct btrfs_fs_info *info); |
2903 | |||
2904 | enum btrfs_reserve_flush_enum { | ||
2905 | /* If we are in the transaction, we can't flush anything.*/ | ||
2906 | BTRFS_RESERVE_NO_FLUSH, | ||
2907 | /* | ||
2908 | * Flushing delalloc may cause deadlock somewhere, in this | ||
2909 | * case, use FLUSH LIMIT | ||
2910 | */ | ||
2911 | BTRFS_RESERVE_FLUSH_LIMIT, | ||
2912 | BTRFS_RESERVE_FLUSH_ALL, | ||
2913 | }; | ||
2914 | |||
2903 | int btrfs_check_data_free_space(struct inode *inode, u64 bytes); | 2915 | int btrfs_check_data_free_space(struct inode *inode, u64 bytes); |
2904 | void btrfs_free_reserved_data_space(struct inode *inode, u64 bytes); | 2916 | void btrfs_free_reserved_data_space(struct inode *inode, u64 bytes); |
2905 | void btrfs_trans_release_metadata(struct btrfs_trans_handle *trans, | 2917 | void btrfs_trans_release_metadata(struct btrfs_trans_handle *trans, |
@@ -2919,19 +2931,13 @@ struct btrfs_block_rsv *btrfs_alloc_block_rsv(struct btrfs_root *root, | |||
2919 | void btrfs_free_block_rsv(struct btrfs_root *root, | 2931 | void btrfs_free_block_rsv(struct btrfs_root *root, |
2920 | struct btrfs_block_rsv *rsv); | 2932 | struct btrfs_block_rsv *rsv); |
2921 | int btrfs_block_rsv_add(struct btrfs_root *root, | 2933 | int btrfs_block_rsv_add(struct btrfs_root *root, |
2922 | struct btrfs_block_rsv *block_rsv, | 2934 | struct btrfs_block_rsv *block_rsv, u64 num_bytes, |
2923 | u64 num_bytes); | 2935 | enum btrfs_reserve_flush_enum flush); |
2924 | int btrfs_block_rsv_add_noflush(struct btrfs_root *root, | ||
2925 | struct btrfs_block_rsv *block_rsv, | ||
2926 | u64 num_bytes); | ||
2927 | int btrfs_block_rsv_check(struct btrfs_root *root, | 2936 | int btrfs_block_rsv_check(struct btrfs_root *root, |
2928 | struct btrfs_block_rsv *block_rsv, int min_factor); | 2937 | struct btrfs_block_rsv *block_rsv, int min_factor); |
2929 | int btrfs_block_rsv_refill(struct btrfs_root *root, | 2938 | int btrfs_block_rsv_refill(struct btrfs_root *root, |
2930 | struct btrfs_block_rsv *block_rsv, | 2939 | struct btrfs_block_rsv *block_rsv, u64 min_reserved, |
2931 | u64 min_reserved); | 2940 | enum btrfs_reserve_flush_enum flush); |
2932 | int btrfs_block_rsv_refill_noflush(struct btrfs_root *root, | ||
2933 | struct btrfs_block_rsv *block_rsv, | ||
2934 | u64 min_reserved); | ||
2935 | int btrfs_block_rsv_migrate(struct btrfs_block_rsv *src_rsv, | 2941 | int btrfs_block_rsv_migrate(struct btrfs_block_rsv *src_rsv, |
2936 | struct btrfs_block_rsv *dst_rsv, | 2942 | struct btrfs_block_rsv *dst_rsv, |
2937 | u64 num_bytes); | 2943 | u64 num_bytes); |