Lines Matching refs:BTRFS_I
115 BTRFS_I(inode)->io_tree.ops = &btrfs_extent_io_ops; in btrfs_test_inode_set_ops()
225 BTRFS_I(inode)->disk_i_size = inode->i_size; in insert_inline_extent()
309 set_bit(BTRFS_INODE_NEEDS_FULL_SYNC, &BTRFS_I(inode)->runtime_flags); in cow_file_range_inline()
361 struct btrfs_root *root = BTRFS_I(inode)->root; in inode_need_compress()
367 if (BTRFS_I(inode)->flags & BTRFS_INODE_NOCOMPRESS) in inode_need_compress()
370 BTRFS_I(inode)->flags & BTRFS_INODE_COMPRESS || in inode_need_compress()
371 BTRFS_I(inode)->force_compress) in inode_need_compress()
399 struct btrfs_root *root = BTRFS_I(inode)->root; in compress_file_range()
419 (start > 0 || end + 1 < BTRFS_I(inode)->disk_i_size)) in compress_file_range()
448 (start > 0 || end + 1 < BTRFS_I(inode)->disk_i_size)) in compress_file_range()
480 if (BTRFS_I(inode)->force_compress) in compress_file_range()
481 compress_type = BTRFS_I(inode)->force_compress; in compress_file_range()
593 !(BTRFS_I(inode)->force_compress)) { in compress_file_range()
594 BTRFS_I(inode)->flags |= BTRFS_INODE_NOCOMPRESS; in compress_file_range()
674 struct btrfs_root *root = BTRFS_I(inode)->root; in submit_compressed_extents()
675 struct extent_map_tree *em_tree = &BTRFS_I(inode)->extent_tree; in submit_compressed_extents()
685 io_tree = &BTRFS_I(inode)->io_tree; in submit_compressed_extents()
831 struct extent_io_tree *tree = &BTRFS_I(inode)->io_tree; in submit_compressed_extents()
869 struct extent_map_tree *em_tree = &BTRFS_I(inode)->extent_tree; in get_extent_allocation_hint()
917 struct btrfs_root *root = BTRFS_I(inode)->root; in cow_file_range()
926 struct extent_map_tree *em_tree = &BTRFS_I(inode)->extent_tree; in cow_file_range()
941 (start > 0 || end + 1 < BTRFS_I(inode)->disk_i_size)) in cow_file_range()
1122 struct btrfs_root *root = BTRFS_I(inode)->root; in cow_file_range_async()
1127 clear_extent_bit(&BTRFS_I(inode)->io_tree, start, end, EXTENT_LOCKED, in cow_file_range_async()
1137 if (BTRFS_I(inode)->flags & BTRFS_INODE_NOCOMPRESS && in cow_file_range_async()
1210 struct btrfs_root *root = BTRFS_I(inode)->root; in run_delalloc_nocow()
1406 em_tree = &BTRFS_I(inode)->extent_tree; in run_delalloc_nocow()
1498 if (!(BTRFS_I(inode)->flags & BTRFS_INODE_NODATACOW) && in need_force_cow()
1499 !(BTRFS_I(inode)->flags & BTRFS_INODE_PREALLOC)) in need_force_cow()
1507 if (BTRFS_I(inode)->defrag_bytes && in need_force_cow()
1508 test_range_bit(&BTRFS_I(inode)->io_tree, start, end, in need_force_cow()
1525 if (BTRFS_I(inode)->flags & BTRFS_INODE_NODATACOW && !force_cow) { in run_delalloc_range()
1528 } else if (BTRFS_I(inode)->flags & BTRFS_INODE_PREALLOC && !force_cow) { in run_delalloc_range()
1536 &BTRFS_I(inode)->runtime_flags); in run_delalloc_range()
1572 spin_lock(&BTRFS_I(inode)->lock); in btrfs_split_extent_hook()
1573 BTRFS_I(inode)->outstanding_extents++; in btrfs_split_extent_hook()
1574 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_split_extent_hook()
1601 spin_lock(&BTRFS_I(inode)->lock); in btrfs_merge_extent_hook()
1602 BTRFS_I(inode)->outstanding_extents--; in btrfs_merge_extent_hook()
1603 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_merge_extent_hook()
1636 spin_lock(&BTRFS_I(inode)->lock); in btrfs_merge_extent_hook()
1637 BTRFS_I(inode)->outstanding_extents--; in btrfs_merge_extent_hook()
1638 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_merge_extent_hook()
1645 if (list_empty(&BTRFS_I(inode)->delalloc_inodes)) { in btrfs_add_delalloc_inodes()
1646 list_add_tail(&BTRFS_I(inode)->delalloc_inodes, in btrfs_add_delalloc_inodes()
1649 &BTRFS_I(inode)->runtime_flags); in btrfs_add_delalloc_inodes()
1666 if (!list_empty(&BTRFS_I(inode)->delalloc_inodes)) { in btrfs_del_delalloc_inode()
1667 list_del_init(&BTRFS_I(inode)->delalloc_inodes); in btrfs_del_delalloc_inode()
1669 &BTRFS_I(inode)->runtime_flags); in btrfs_del_delalloc_inode()
1698 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_set_bit_hook()
1705 spin_lock(&BTRFS_I(inode)->lock); in btrfs_set_bit_hook()
1706 BTRFS_I(inode)->outstanding_extents++; in btrfs_set_bit_hook()
1707 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_set_bit_hook()
1716 spin_lock(&BTRFS_I(inode)->lock); in btrfs_set_bit_hook()
1717 BTRFS_I(inode)->delalloc_bytes += len; in btrfs_set_bit_hook()
1719 BTRFS_I(inode)->defrag_bytes += len; in btrfs_set_bit_hook()
1721 &BTRFS_I(inode)->runtime_flags)) in btrfs_set_bit_hook()
1723 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_set_bit_hook()
1738 spin_lock(&BTRFS_I(inode)->lock); in btrfs_clear_bit_hook()
1740 BTRFS_I(inode)->defrag_bytes -= len; in btrfs_clear_bit_hook()
1741 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_clear_bit_hook()
1749 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_clear_bit_hook()
1755 spin_lock(&BTRFS_I(inode)->lock); in btrfs_clear_bit_hook()
1756 BTRFS_I(inode)->outstanding_extents -= num_extents; in btrfs_clear_bit_hook()
1757 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_clear_bit_hook()
1779 spin_lock(&BTRFS_I(inode)->lock); in btrfs_clear_bit_hook()
1780 BTRFS_I(inode)->delalloc_bytes -= len; in btrfs_clear_bit_hook()
1781 if (do_list && BTRFS_I(inode)->delalloc_bytes == 0 && in btrfs_clear_bit_hook()
1783 &BTRFS_I(inode)->runtime_flags)) in btrfs_clear_bit_hook()
1785 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_clear_bit_hook()
1797 struct btrfs_root *root = BTRFS_I(page->mapping->host)->root; in btrfs_merge_bio_hook()
1830 struct btrfs_root *root = BTRFS_I(inode)->root; in __btrfs_submit_bio_start()
1850 struct btrfs_root *root = BTRFS_I(inode)->root; in __btrfs_submit_bio_done()
1867 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_submit_bio_hook()
1871 int async = !atomic_read(&BTRFS_I(inode)->sync_writers); in btrfs_submit_bio_hook()
1873 skip_sum = BTRFS_I(inode)->flags & BTRFS_INODE_NODATASUM; in btrfs_submit_bio_hook()
1899 ret = btrfs_wq_submit_bio(BTRFS_I(inode)->root->fs_info, in btrfs_submit_bio_hook()
1933 BTRFS_I(inode)->root->fs_info->csum_root, sum); in add_pending_csums()
1943 return set_extent_delalloc(&BTRFS_I(inode)->io_tree, start, end, in btrfs_set_extent_delalloc()
1977 lock_extent_bits(&BTRFS_I(inode)->io_tree, page_start, page_end, 0, in btrfs_writepage_fixup_worker()
1986 unlock_extent_cached(&BTRFS_I(inode)->io_tree, page_start, in btrfs_writepage_fixup_worker()
2006 unlock_extent_cached(&BTRFS_I(inode)->io_tree, page_start, page_end, in btrfs_writepage_fixup_worker()
2029 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_writepage_start_hook()
2058 struct btrfs_root *root = BTRFS_I(inode)->root; in insert_reserved_file_extent()
2239 if (BTRFS_I(inode)->root->root_key.objectid == root_id && in record_one_backref()
2247 fs_info = BTRFS_I(inode)->root->fs_info; in record_one_backref()
2345 struct btrfs_fs_info *fs_info = BTRFS_I(new->inode)->root->fs_info; in record_extent_backrefs()
2430 fs_info = BTRFS_I(src_inode)->root->fs_info; in relink_extent_backref()
2462 lock_extent_bits(&BTRFS_I(inode)->io_tree, lock_start, lock_end, in relink_extent_backref()
2590 unlock_extent_cached(&BTRFS_I(inode)->io_tree, lock_start, lock_end, in relink_extent_backref()
2621 root = BTRFS_I(inode)->root; in relink_file_extents()
2666 struct btrfs_root *root = BTRFS_I(inode)->root; in record_old_file_extents()
2797 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_finish_ordered_io()
2799 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in btrfs_finish_ordered_io()
2855 if (0 && last_snapshot >= BTRFS_I(inode)->generation) in btrfs_finish_ordered_io()
2898 unpin_extent_cache(&BTRFS_I(inode)->extent_tree, in btrfs_finish_ordered_io()
2988 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_writepage_end_io_hook()
3038 btrfs_warn(BTRFS_I(inode)->root->fs_info, in __readpage_endio_check()
3060 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in btrfs_readpage_end_io_hook()
3061 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_readpage_end_io_hook()
3068 if (BTRFS_I(inode)->flags & BTRFS_INODE_NODATASUM) in btrfs_readpage_end_io_hook()
3085 struct btrfs_fs_info *fs_info = BTRFS_I(inode)->root->fs_info; in btrfs_add_delayed_iput()
3086 struct btrfs_inode *binode = BTRFS_I(inode); in btrfs_add_delayed_iput()
3181 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_orphan_add()
3202 &BTRFS_I(inode)->runtime_flags)) { in btrfs_orphan_add()
3219 &BTRFS_I(inode)->runtime_flags)) in btrfs_orphan_add()
3236 &BTRFS_I(inode)->runtime_flags); in btrfs_orphan_add()
3241 &BTRFS_I(inode)->runtime_flags); in btrfs_orphan_add()
3268 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_orphan_del()
3275 &BTRFS_I(inode)->runtime_flags)) in btrfs_orphan_del()
3279 &BTRFS_I(inode)->runtime_flags)) in btrfs_orphan_del()
3434 &BTRFS_I(inode)->runtime_flags); in btrfs_orphan_cleanup()
3577 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_read_locked_inode()
3594 memcpy(&location, &BTRFS_I(inode)->location, sizeof(location)); in btrfs_read_locked_inode()
3622 BTRFS_I(inode)->i_otime.tv_sec = in btrfs_read_locked_inode()
3624 BTRFS_I(inode)->i_otime.tv_nsec = in btrfs_read_locked_inode()
3628 BTRFS_I(inode)->generation = btrfs_inode_generation(leaf, inode_item); in btrfs_read_locked_inode()
3629 BTRFS_I(inode)->last_trans = btrfs_inode_transid(leaf, inode_item); in btrfs_read_locked_inode()
3632 inode->i_generation = BTRFS_I(inode)->generation; in btrfs_read_locked_inode()
3636 BTRFS_I(inode)->index_cnt = (u64)-1; in btrfs_read_locked_inode()
3637 BTRFS_I(inode)->flags = btrfs_inode_flags(leaf, inode_item); in btrfs_read_locked_inode()
3649 if (BTRFS_I(inode)->last_trans == root->fs_info->generation) in btrfs_read_locked_inode()
3651 &BTRFS_I(inode)->runtime_flags); in btrfs_read_locked_inode()
3667 BTRFS_I(inode)->dir_index = btrfs_inode_ref_index(leaf, ref); in btrfs_read_locked_inode()
3672 BTRFS_I(inode)->dir_index = btrfs_inode_extref_index(leaf, in btrfs_read_locked_inode()
3699 BTRFS_I(inode)->io_tree.ops = &btrfs_extent_io_ops; in btrfs_read_locked_inode()
3742 btrfs_set_token_inode_size(leaf, item, BTRFS_I(inode)->disk_i_size, in fill_inode_item()
3763 BTRFS_I(inode)->i_otime.tv_sec, &token); in fill_inode_item()
3765 BTRFS_I(inode)->i_otime.tv_nsec, &token); in fill_inode_item()
3769 btrfs_set_token_inode_generation(leaf, item, BTRFS_I(inode)->generation, in fill_inode_item()
3774 btrfs_set_token_inode_flags(leaf, item, BTRFS_I(inode)->flags, &token); in fill_inode_item()
3794 ret = btrfs_lookup_inode(trans, root, path, &BTRFS_I(inode)->location, in btrfs_update_inode_item()
3909 if (BTRFS_I(inode)->dir_index) { in __btrfs_unlink_inode()
3912 index = BTRFS_I(inode)->dir_index; in __btrfs_unlink_inode()
3985 struct btrfs_root *root = BTRFS_I(dir)->root; in __unlink_start_trans()
4020 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_unlink()
4132 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_rmdir()
4146 BTRFS_I(inode)->location.objectid, in btrfs_rmdir()
4193 struct btrfs_root *root = BTRFS_I(inode)->root; in truncate_inline_extent()
4295 if (min_type == 0 && root == BTRFS_I(inode)->root) in btrfs_truncate_inode_items()
4579 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_truncate_page()
4580 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in btrfs_truncate_page()
4640 clear_extent_bit(&BTRFS_I(inode)->io_tree, page_start, page_end, in btrfs_truncate_page()
4689 BTRFS_I(inode)->last_trans = root->fs_info->generation; in maybe_insert_hole()
4690 BTRFS_I(inode)->last_sub_trans = root->log_transid; in maybe_insert_hole()
4691 BTRFS_I(inode)->last_log_commit = root->last_log_commit; in maybe_insert_hole()
4729 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_cont_expand()
4730 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in btrfs_cont_expand()
4733 struct extent_map_tree *em_tree = &BTRFS_I(inode)->extent_tree; in btrfs_cont_expand()
4792 &BTRFS_I(inode)->runtime_flags); in btrfs_cont_expand()
4854 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_setsize()
4910 &BTRFS_I(inode)->runtime_flags); in btrfs_setsize()
4958 i_size_write(inode, BTRFS_I(inode)->disk_i_size); in btrfs_setsize()
4972 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_setattr()
5014 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in evict_inode_truncate_pages()
5015 struct extent_map_tree *map_tree = &BTRFS_I(inode)->extent_tree; in evict_inode_truncate_pages()
5067 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_evict_inode()
5095 &BTRFS_I(inode)->runtime_flags)); in btrfs_evict_inode()
5246 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_inode_by_name()
5296 key.objectid = BTRFS_I(dir)->root->root_key.objectid; in fixup_tree_root_location()
5340 struct btrfs_root *root = BTRFS_I(inode)->root; in inode_tree_add()
5344 struct rb_node *new = &BTRFS_I(inode)->rb_node; in inode_tree_add()
5376 struct btrfs_root *root = BTRFS_I(inode)->root; in inode_tree_del()
5380 if (!RB_EMPTY_NODE(&BTRFS_I(inode)->rb_node)) { in inode_tree_del()
5381 rb_erase(&BTRFS_I(inode)->rb_node, &root->inode_tree); in inode_tree_del()
5382 RB_CLEAR_NODE(&BTRFS_I(inode)->rb_node); in inode_tree_del()
5464 memcpy(&BTRFS_I(inode)->location, args->location, in btrfs_init_locked_inode()
5466 BTRFS_I(inode)->root = args->root; in btrfs_init_locked_inode()
5473 return args->location->objectid == BTRFS_I(inode)->location.objectid && in btrfs_find_actor()
5474 args->root == BTRFS_I(inode)->root; in btrfs_find_actor()
5532 BTRFS_I(inode)->root = root; in new_simple_dir()
5533 memcpy(&BTRFS_I(inode)->location, key, sizeof(*key)); in new_simple_dir()
5534 set_bit(BTRFS_INODE_DUMMY, &BTRFS_I(inode)->runtime_flags); in new_simple_dir()
5543 BTRFS_I(inode)->i_otime = inode->i_mtime; in new_simple_dir()
5551 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_lookup_dentry()
5610 root = BTRFS_I(inode)->root; in btrfs_dentry_delete()
5648 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_real_readdir()
5842 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_write_inode()
5847 if (test_bit(BTRFS_INODE_DUMMY, &BTRFS_I(inode)->runtime_flags)) in btrfs_write_inode()
5873 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_dirty_inode()
5877 if (test_bit(BTRFS_INODE_DUMMY, &BTRFS_I(inode)->runtime_flags)) in btrfs_dirty_inode()
5895 if (BTRFS_I(inode)->delayed_node) in btrfs_dirty_inode()
5908 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_update_time()
5931 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_set_inode_index_count()
5960 BTRFS_I(inode)->index_cnt = 2; in btrfs_set_inode_index_count()
5971 BTRFS_I(inode)->index_cnt = 2; in btrfs_set_inode_index_count()
5975 BTRFS_I(inode)->index_cnt = found_key.offset + 1; in btrfs_set_inode_index_count()
5989 if (BTRFS_I(dir)->index_cnt == (u64)-1) { in btrfs_set_inode_index()
5998 *index = BTRFS_I(dir)->index_cnt; in btrfs_set_inode_index()
5999 BTRFS_I(dir)->index_cnt++; in btrfs_set_inode_index()
6007 args.location = &BTRFS_I(inode)->location; in btrfs_insert_inode_locked()
6008 args.root = BTRFS_I(inode)->root; in btrfs_insert_inode_locked()
6011 btrfs_inode_hash(inode->i_ino, BTRFS_I(inode)->root), in btrfs_insert_inode_locked()
6073 BTRFS_I(inode)->index_cnt = 2; in btrfs_new_inode()
6074 BTRFS_I(inode)->dir_index = *index; in btrfs_new_inode()
6075 BTRFS_I(inode)->root = root; in btrfs_new_inode()
6076 BTRFS_I(inode)->generation = trans->transid; in btrfs_new_inode()
6077 inode->i_generation = BTRFS_I(inode)->generation; in btrfs_new_inode()
6085 set_bit(BTRFS_INODE_NEEDS_FULL_SYNC, &BTRFS_I(inode)->runtime_flags); in btrfs_new_inode()
6107 location = &BTRFS_I(inode)->location; in btrfs_new_inode()
6127 BTRFS_I(inode)->i_otime = inode->i_mtime; in btrfs_new_inode()
6151 BTRFS_I(inode)->flags |= BTRFS_INODE_NODATASUM; in btrfs_new_inode()
6153 BTRFS_I(inode)->flags |= BTRFS_INODE_NODATACOW | in btrfs_new_inode()
6176 BTRFS_I(dir)->index_cnt--; in btrfs_new_inode()
6199 struct btrfs_root *root = BTRFS_I(parent_inode)->root; in btrfs_add_link()
6204 memcpy(&key, &BTRFS_I(inode)->root->root_key, sizeof(key)); in btrfs_add_link()
6277 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_mknod()
6351 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_create()
6401 BTRFS_I(inode)->io_tree.ops = &btrfs_extent_io_ops; in btrfs_create()
6425 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_link()
6432 if (root->objectid != BTRFS_I(inode)->root->objectid) in btrfs_link()
6455 BTRFS_I(inode)->dir_index = 0ULL; in btrfs_link()
6460 set_bit(BTRFS_INODE_COPY_EVERYTHING, &BTRFS_I(inode)->runtime_flags); in btrfs_link()
6500 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_mkdir()
6683 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_get_extent()
6688 struct extent_map_tree *em_tree = &BTRFS_I(inode)->extent_tree; in btrfs_get_extent()
6689 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in btrfs_get_extent()
6982 found = count_range_bits(&BTRFS_I(inode)->io_tree, &range_start, in btrfs_get_extent_fiemap()
7073 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_new_extent_direct()
7115 struct btrfs_root *root = BTRFS_I(inode)->root; in can_nocow_extent()
7116 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in can_nocow_extent()
7125 bool nocow = (BTRFS_I(inode)->flags & BTRFS_INODE_NODATACOW); in can_nocow_extent()
7325 lock_extent_bits(&BTRFS_I(inode)->io_tree, lockstart, lockend, in lock_extent_direct()
7347 unlock_extent_cached(&BTRFS_I(inode)->io_tree, lockstart, lockend, in lock_extent_direct()
7389 struct btrfs_root *root = BTRFS_I(inode)->root; in create_pinned_em()
7392 em_tree = &BTRFS_I(inode)->extent_tree; in create_pinned_em()
7433 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_get_blocks_direct()
7517 ((BTRFS_I(inode)->flags & BTRFS_INODE_NODATACOW) && in btrfs_get_blocks_direct()
7591 spin_lock(&BTRFS_I(inode)->lock); in btrfs_get_blocks_direct()
7592 BTRFS_I(inode)->outstanding_extents++; in btrfs_get_blocks_direct()
7593 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_get_blocks_direct()
7606 clear_extent_bit(&BTRFS_I(inode)->io_tree, lockstart, in btrfs_get_blocks_direct()
7618 clear_extent_bit(&BTRFS_I(inode)->io_tree, lockstart, lockend, in btrfs_get_blocks_direct()
7628 struct btrfs_root *root = BTRFS_I(inode)->root; in submit_dio_repair_bio()
7653 num_copies = btrfs_num_copies(BTRFS_I(inode)->root->fs_info, in btrfs_check_dio_repairable()
7718 btrfs_debug(BTRFS_I(inode)->root->fs_info, in dio_read_error()
7874 bool skip_csum = BTRFS_I(inode)->flags & BTRFS_INODE_NODATASUM; in btrfs_subio_endio_read()
7896 unlock_extent(&BTRFS_I(inode)->io_tree, dip->logical_offset, in btrfs_endio_direct_read()
7916 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_endio_direct_write()
7964 struct btrfs_root *root = BTRFS_I(inode)->root; in __btrfs_submit_bio_start_direct_io()
7975 btrfs_warn(BTRFS_I(dip->inode)->root->fs_info, in btrfs_end_dio_bio()
8053 struct btrfs_root *root = BTRFS_I(inode)->root; in __btrfs_submit_dio_bio()
8057 async_submit = !atomic_read(&BTRFS_I(inode)->sync_writers); in __btrfs_submit_dio_bio()
8103 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_submit_direct_hook()
8215 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_submit_direct()
8223 skip_sum = BTRFS_I(inode)->flags & BTRFS_INODE_NODATASUM; in btrfs_submit_direct()
8328 if (check_direct_IO(BTRFS_I(inode)->root, iocb, iter, offset)) in btrfs_direct_IO()
8342 &BTRFS_I(inode)->runtime_flags)) in btrfs_direct_IO()
8370 &BTRFS_I(inode)->runtime_flags)) { in btrfs_direct_IO()
8377 BTRFS_I(inode)->root->fs_info->fs_devices->latest_bdev, in btrfs_direct_IO()
8414 tree = &BTRFS_I(page->mapping->host)->io_tree; in btrfs_readpage()
8439 tree = &BTRFS_I(page->mapping->host)->io_tree; in btrfs_writepage()
8450 tree = &BTRFS_I(mapping->host)->io_tree; in btrfs_writepages()
8459 tree = &BTRFS_I(mapping->host)->io_tree; in btrfs_readpages()
8469 tree = &BTRFS_I(page->mapping->host)->io_tree; in __btrfs_releasepage()
8470 map = &BTRFS_I(page->mapping->host)->extent_tree; in __btrfs_releasepage()
8507 tree = &BTRFS_I(inode)->io_tree; in btrfs_invalidatepage()
8535 tree = &BTRFS_I(inode)->ordered_tree; in btrfs_invalidatepage()
8594 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_page_mkwrite()
8595 struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; in btrfs_page_mkwrite()
8660 clear_extent_bit(&BTRFS_I(inode)->io_tree, page_start, page_end, in btrfs_page_mkwrite()
8691 BTRFS_I(inode)->last_trans = root->fs_info->generation; in btrfs_page_mkwrite()
8692 BTRFS_I(inode)->last_sub_trans = BTRFS_I(inode)->root->log_transid; in btrfs_page_mkwrite()
8693 BTRFS_I(inode)->last_log_commit = BTRFS_I(inode)->root->last_log_commit; in btrfs_page_mkwrite()
8712 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_truncate()
8789 set_bit(BTRFS_INODE_NEEDS_FULL_SYNC, &BTRFS_I(inode)->runtime_flags); in btrfs_truncate()
8945 kmem_cache_free(btrfs_inode_cachep, BTRFS_I(inode)); in btrfs_test_destroy_inode()
8952 kmem_cache_free(btrfs_inode_cachep, BTRFS_I(inode)); in btrfs_i_callback()
8958 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_destroy_inode()
8962 WARN_ON(BTRFS_I(inode)->outstanding_extents); in btrfs_destroy_inode()
8963 WARN_ON(BTRFS_I(inode)->reserved_extents); in btrfs_destroy_inode()
8964 WARN_ON(BTRFS_I(inode)->delalloc_bytes); in btrfs_destroy_inode()
8965 WARN_ON(BTRFS_I(inode)->csum_bytes); in btrfs_destroy_inode()
8966 WARN_ON(BTRFS_I(inode)->defrag_bytes); in btrfs_destroy_inode()
8977 &BTRFS_I(inode)->runtime_flags)) { in btrfs_destroy_inode()
9003 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_drop_inode()
9096 stat->dev = BTRFS_I(inode)->root->anon_dev; in btrfs_getattr()
9099 spin_lock(&BTRFS_I(inode)->lock); in btrfs_getattr()
9100 delalloc_bytes = BTRFS_I(inode)->delalloc_bytes; in btrfs_getattr()
9101 spin_unlock(&BTRFS_I(inode)->lock); in btrfs_getattr()
9111 struct btrfs_root *root = BTRFS_I(old_dir)->root; in btrfs_rename()
9112 struct btrfs_root *dest = BTRFS_I(new_dir)->root; in btrfs_rename()
9187 BTRFS_I(old_inode)->dir_index = 0ULL; in btrfs_rename()
9220 root_objectid = BTRFS_I(old_inode)->root->root_key.objectid; in btrfs_rename()
9242 root_objectid = BTRFS_I(new_inode)->location.objectid; in btrfs_rename()
9271 BTRFS_I(old_inode)->dir_index = index; in btrfs_rename()
9310 &BTRFS_I(inode)->runtime_flags)) in btrfs_run_delalloc_work()
9502 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_symlink()
9552 BTRFS_I(inode)->io_tree.ops = &btrfs_extent_io_ops; in btrfs_symlink()
9626 struct extent_map_tree *em_tree = &BTRFS_I(inode)->extent_tree; in __btrfs_prealloc_file_range()
9628 struct btrfs_root *root = BTRFS_I(inode)->root; in __btrfs_prealloc_file_range()
9677 &BTRFS_I(inode)->runtime_flags); in __btrfs_prealloc_file_range()
9710 BTRFS_I(inode)->flags |= BTRFS_INODE_PREALLOC; in __btrfs_prealloc_file_range()
9762 struct btrfs_root *root = BTRFS_I(inode)->root; in btrfs_permission()
9769 if (BTRFS_I(inode)->flags & BTRFS_INODE_READONLY) in btrfs_permission()
9778 struct btrfs_root *root = BTRFS_I(dir)->root; in btrfs_tmpfile()
9807 BTRFS_I(inode)->io_tree.ops = &btrfs_extent_io_ops; in btrfs_tmpfile()