diff options
author | Lu Fengqi <lufq.fnst@cn.fujitsu.com> | 2018-10-11 08:40:35 +0300 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2018-10-15 18:23:41 +0300 |
commit | af9b8a0e2085fc90dca85acd85ee83ece7c05130 (patch) | |
tree | b581f8d45652eb3639d7e8a7396897db2d638b6f /fs/btrfs/extent-tree.c | |
parent | 9e920a6f03e40b1eb712f38b29ad5880153754e2 (diff) | |
download | linux-af9b8a0e2085fc90dca85acd85ee83ece7c05130.tar.xz |
btrfs: remove fs_info from btrfs_check_space_for_delayed_refs
It can be referenced from the transaction handle.
Signed-off-by: Lu Fengqi <lufq.fnst@cn.fujitsu.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/extent-tree.c')
-rw-r--r-- | fs/btrfs/extent-tree.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c index 3ee5d84cd817..c7de1e720f56 100644 --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c @@ -2789,9 +2789,9 @@ u64 btrfs_csum_bytes_to_leaves(struct btrfs_fs_info *fs_info, u64 csum_bytes) return num_csums; } -int btrfs_check_space_for_delayed_refs(struct btrfs_trans_handle *trans, - struct btrfs_fs_info *fs_info) +int btrfs_check_space_for_delayed_refs(struct btrfs_trans_handle *trans) { + struct btrfs_fs_info *fs_info = trans->fs_info; struct btrfs_block_rsv *global_rsv; u64 num_heads = trans->transaction->delayed_refs.num_heads_ready; u64 csum_bytes = trans->transaction->delayed_refs.pending_csums; @@ -2842,7 +2842,7 @@ int btrfs_should_throttle_delayed_refs(struct btrfs_trans_handle *trans, if (val >= NSEC_PER_SEC / 2) return 2; - return btrfs_check_space_for_delayed_refs(trans, fs_info); + return btrfs_check_space_for_delayed_refs(trans); } struct async_delayed_refs { |