Commit 275312a0 authored by Josef Bacik's avatar Josef Bacik Committed by David Sterba

btrfs: remove free space cache inode check in btrfs_truncate_inode_items

We no longer have inode cache feature, so this check is extraneous as
the only inode cache is in the tree_root, which is not marked as
SHAREABLE.
Reviewed-by: default avatarFilipe Manana <fdmanana@suse.com>
Signed-off-by: default avatarJosef Bacik <josef@toxicpanda.com>
Reviewed-by: default avatarDavid Sterba <dsterba@suse.com>
Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
parent 9a4a1429
...@@ -477,12 +477,10 @@ int btrfs_truncate_inode_items(struct btrfs_trans_handle *trans, ...@@ -477,12 +477,10 @@ int btrfs_truncate_inode_items(struct btrfs_trans_handle *trans,
BUG_ON(new_size > 0 && min_type != BTRFS_EXTENT_DATA_KEY); BUG_ON(new_size > 0 && min_type != BTRFS_EXTENT_DATA_KEY);
/* /*
* For non-free space inodes and non-shareable roots, we want to back * For shareable roots we want to back off from time to time, this turns
* off from time to time. This means all inodes in subvolume roots, * out to be subvolume roots, reloc roots, and data reloc roots.
* reloc roots, and data reloc roots.
*/ */
if (!btrfs_is_free_space_inode(inode) && if (test_bit(BTRFS_ROOT_SHAREABLE, &root->state))
test_bit(BTRFS_ROOT_SHAREABLE, &root->state))
be_nice = true; be_nice = true;
path = btrfs_alloc_path(); path = btrfs_alloc_path();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment