diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 259d7891d10c3f18902918230f6f99d1f71a1f23..9fcce54ecde451aa3ace778d1834e085b93b1945 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c @@ -2711,13 +2711,13 @@ int open_ctree(struct super_block *sb, * kthreads */ filemap_write_and_wait(fs_info->btree_inode->i_mapping); - invalidate_inode_pages2(fs_info->btree_inode->i_mapping); fail_block_groups: btrfs_free_block_groups(fs_info); fail_tree_roots: free_root_pointers(fs_info, 1); + invalidate_inode_pages2(fs_info->btree_inode->i_mapping); fail_sb_buffer: btrfs_stop_workers(&fs_info->generic_worker); @@ -2738,7 +2738,6 @@ int open_ctree(struct super_block *sb, fail_iput: btrfs_mapping_tree_free(&fs_info->mapping_tree); - invalidate_inode_pages2(fs_info->btree_inode->i_mapping); iput(fs_info->btree_inode); fail_delalloc_bytes: percpu_counter_destroy(&fs_info->delalloc_bytes);