Lines Matching refs:trans
26 static void init_dummy_trans(struct btrfs_trans_handle *trans) in init_dummy_trans() argument
28 memset(trans, 0, sizeof(*trans)); in init_dummy_trans()
29 trans->transid = 1; in init_dummy_trans()
30 INIT_LIST_HEAD(&trans->qgroup_ref_list); in init_dummy_trans()
31 trans->type = __TRANS_DUMMY; in init_dummy_trans()
37 struct btrfs_trans_handle trans; in insert_normal_tree_ref() local
47 init_dummy_trans(&trans); in insert_normal_tree_ref()
60 ret = btrfs_insert_empty_item(&trans, root, path, &ins, size); in insert_normal_tree_ref()
90 struct btrfs_trans_handle trans; in add_tree_ref() local
97 init_dummy_trans(&trans); in add_tree_ref()
110 ret = btrfs_search_slot(&trans, root, &key, path, 0, 1); in add_tree_ref()
132 ret = btrfs_insert_empty_item(&trans, root, path, &key, 0); in add_tree_ref()
142 struct btrfs_trans_handle trans; in remove_extent_item() local
147 init_dummy_trans(&trans); in remove_extent_item()
160 ret = btrfs_search_slot(&trans, root, &key, path, -1, 1); in remove_extent_item()
166 btrfs_del_item(&trans, root, path); in remove_extent_item()
174 struct btrfs_trans_handle trans; in remove_extent_ref() local
181 init_dummy_trans(&trans); in remove_extent_ref()
194 ret = btrfs_search_slot(&trans, root, &key, path, 0, 1); in remove_extent_ref()
216 ret = btrfs_search_slot(&trans, root, &key, path, -1, 1); in remove_extent_ref()
222 btrfs_del_item(&trans, root, path); in remove_extent_ref()
229 struct btrfs_trans_handle trans; in test_no_shared_qgroup() local
235 init_dummy_trans(&trans); in test_no_shared_qgroup()
249 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &old_roots); in test_no_shared_qgroup()
260 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &new_roots); in test_no_shared_qgroup()
268 ret = btrfs_qgroup_account_extent(&trans, fs_info, 4096, 4096, in test_no_shared_qgroup()
282 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &old_roots); in test_no_shared_qgroup()
293 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &new_roots); in test_no_shared_qgroup()
301 ret = btrfs_qgroup_account_extent(&trans, fs_info, 4096, 4096, in test_no_shared_qgroup()
323 struct btrfs_trans_handle trans; in test_multiple_refs() local
329 init_dummy_trans(&trans); in test_multiple_refs()
340 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &old_roots); in test_multiple_refs()
351 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &new_roots); in test_multiple_refs()
359 ret = btrfs_qgroup_account_extent(&trans, fs_info, 4096, 4096, in test_multiple_refs()
371 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &old_roots); in test_multiple_refs()
382 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &new_roots); in test_multiple_refs()
390 ret = btrfs_qgroup_account_extent(&trans, fs_info, 4096, 4096, in test_multiple_refs()
407 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &old_roots); in test_multiple_refs()
418 ret = btrfs_find_all_roots(&trans, fs_info, 4096, 0, &new_roots); in test_multiple_refs()
426 ret = btrfs_qgroup_account_extent(&trans, fs_info, 4096, 4096, in test_multiple_refs()