• Home
  • Raw
  • Download

Lines Matching refs:quota_root

304 	struct btrfs_root *quota_root = fs_info->quota_root;  in btrfs_read_qgroup_config()  local
336 ret = btrfs_search_slot_for_read(quota_root, &key, path, 1, 1); in btrfs_read_qgroup_config()
415 ret = btrfs_next_item(quota_root, path); in btrfs_read_qgroup_config()
429 ret = btrfs_search_slot_for_read(quota_root, &key, path, 1, 0); in btrfs_read_qgroup_config()
457 ret = btrfs_next_item(quota_root, path); in btrfs_read_qgroup_config()
507 struct btrfs_root *quota_root, in add_qgroup_relation_item() argument
522 ret = btrfs_insert_empty_item(trans, quota_root, path, &key, 0); in add_qgroup_relation_item()
531 struct btrfs_root *quota_root, in del_qgroup_relation_item() argument
546 ret = btrfs_search_slot(trans, quota_root, &key, path, -1, 1); in del_qgroup_relation_item()
555 ret = btrfs_del_item(trans, quota_root, path); in del_qgroup_relation_item()
562 struct btrfs_root *quota_root, u64 qgroupid) in add_qgroup_item() argument
571 if (btrfs_is_testing(quota_root->fs_info)) in add_qgroup_item()
588 ret = btrfs_insert_empty_item(trans, quota_root, path, &key, in add_qgroup_item()
607 ret = btrfs_insert_empty_item(trans, quota_root, path, &key, in add_qgroup_item()
630 struct btrfs_root *quota_root, u64 qgroupid) in del_qgroup_item() argument
643 ret = btrfs_search_slot(trans, quota_root, &key, path, -1, 1); in del_qgroup_item()
652 ret = btrfs_del_item(trans, quota_root, path); in del_qgroup_item()
659 ret = btrfs_search_slot(trans, quota_root, &key, path, -1, 1); in del_qgroup_item()
668 ret = btrfs_del_item(trans, quota_root, path); in del_qgroup_item()
855 struct btrfs_root *quota_root; in btrfs_quota_enable() local
867 if (fs_info->quota_root) { in btrfs_quota_enable()
881 quota_root = btrfs_create_tree(trans, fs_info, in btrfs_quota_enable()
883 if (IS_ERR(quota_root)) { in btrfs_quota_enable()
884 ret = PTR_ERR(quota_root); in btrfs_quota_enable()
898 ret = btrfs_insert_empty_item(trans, quota_root, path, &key, in btrfs_quota_enable()
933 ret = add_qgroup_item(trans, quota_root, in btrfs_quota_enable()
953 ret = add_qgroup_item(trans, quota_root, BTRFS_FS_TREE_OBJECTID); in btrfs_quota_enable()
963 fs_info->quota_root = quota_root; in btrfs_quota_enable()
970 free_extent_buffer(quota_root->node); in btrfs_quota_enable()
971 free_extent_buffer(quota_root->commit_root); in btrfs_quota_enable()
972 kfree(quota_root); in btrfs_quota_enable()
987 struct btrfs_root *quota_root; in btrfs_quota_disable() local
991 if (!fs_info->quota_root) in btrfs_quota_disable()
997 quota_root = fs_info->quota_root; in btrfs_quota_disable()
998 fs_info->quota_root = NULL; in btrfs_quota_disable()
1004 ret = btrfs_clean_quota_tree(trans, quota_root); in btrfs_quota_disable()
1008 ret = btrfs_del_root(trans, tree_root, &quota_root->root_key); in btrfs_quota_disable()
1012 list_del(&quota_root->dirty_list); in btrfs_quota_disable()
1014 btrfs_tree_lock(quota_root->node); in btrfs_quota_disable()
1015 clean_tree_block(trans, tree_root->fs_info, quota_root->node); in btrfs_quota_disable()
1016 btrfs_tree_unlock(quota_root->node); in btrfs_quota_disable()
1017 btrfs_free_tree_block(trans, quota_root, quota_root->node, 0, 1); in btrfs_quota_disable()
1019 free_extent_buffer(quota_root->node); in btrfs_quota_disable()
1020 free_extent_buffer(quota_root->commit_root); in btrfs_quota_disable()
1021 kfree(quota_root); in btrfs_quota_disable()
1141 struct btrfs_root *quota_root; in btrfs_add_qgroup_relation() local
1157 quota_root = fs_info->quota_root; in btrfs_add_qgroup_relation()
1158 if (!quota_root) { in btrfs_add_qgroup_relation()
1177 ret = add_qgroup_relation_item(trans, quota_root, src, dst); in btrfs_add_qgroup_relation()
1181 ret = add_qgroup_relation_item(trans, quota_root, dst, src); in btrfs_add_qgroup_relation()
1183 del_qgroup_relation_item(trans, quota_root, src, dst); in btrfs_add_qgroup_relation()
1188 ret = add_relation_rb(quota_root->fs_info, src, dst); in btrfs_add_qgroup_relation()
1204 struct btrfs_root *quota_root; in __del_qgroup_relation() local
1216 quota_root = fs_info->quota_root; in __del_qgroup_relation()
1217 if (!quota_root) { in __del_qgroup_relation()
1237 ret = del_qgroup_relation_item(trans, quota_root, src, dst); in __del_qgroup_relation()
1238 err = del_qgroup_relation_item(trans, quota_root, dst, src); in __del_qgroup_relation()
1266 struct btrfs_root *quota_root; in btrfs_create_qgroup() local
1271 quota_root = fs_info->quota_root; in btrfs_create_qgroup()
1272 if (!quota_root) { in btrfs_create_qgroup()
1282 ret = add_qgroup_item(trans, quota_root, qgroupid); in btrfs_create_qgroup()
1300 struct btrfs_root *quota_root; in btrfs_remove_qgroup() local
1306 quota_root = fs_info->quota_root; in btrfs_remove_qgroup()
1307 if (!quota_root) { in btrfs_remove_qgroup()
1323 ret = del_qgroup_item(trans, quota_root, qgroupid); in btrfs_remove_qgroup()
1336 del_qgroup_rb(quota_root->fs_info, qgroupid); in btrfs_remove_qgroup()
1347 struct btrfs_root *quota_root; in btrfs_limit_qgroup() local
1357 quota_root = fs_info->quota_root; in btrfs_limit_qgroup()
1358 if (!quota_root) { in btrfs_limit_qgroup()
1410 ret = update_qgroup_limit_item(trans, quota_root, qgroup); in btrfs_limit_qgroup()
1716 BUG_ON(!fs_info->quota_root); in btrfs_qgroup_account_extent()
1827 struct btrfs_root *quota_root = fs_info->quota_root; in btrfs_run_qgroups() local
1831 if (!quota_root) in btrfs_run_qgroups()
1850 ret = update_qgroup_info_item(trans, quota_root, qgroup); in btrfs_run_qgroups()
1854 ret = update_qgroup_limit_item(trans, quota_root, qgroup); in btrfs_run_qgroups()
1866 ret = update_qgroup_status_item(trans, fs_info, quota_root); in btrfs_run_qgroups()
1898 struct btrfs_root *quota_root = fs_info->quota_root; in btrfs_qgroup_inherit() local
1908 if (!quota_root) { in btrfs_qgroup_inherit()
1935 ret = add_qgroup_item(trans, quota_root, objectid); in btrfs_qgroup_inherit()
1965 ret = add_qgroup_relation_item(trans, quota_root, in btrfs_qgroup_inherit()
1969 ret = add_qgroup_relation_item(trans, quota_root, in btrfs_qgroup_inherit()
1993 ret = update_qgroup_limit_item(trans, quota_root, dstgroup); in btrfs_qgroup_inherit()
2037 ret = add_relation_rb(quota_root->fs_info, objectid, in btrfs_qgroup_inherit()
2091 struct btrfs_root *quota_root; in qgroup_reserve() local
2106 quota_root = fs_info->quota_root; in qgroup_reserve()
2107 if (!quota_root) in qgroup_reserve()
2173 struct btrfs_root *quota_root; in btrfs_qgroup_free_refroot() local
2187 quota_root = fs_info->quota_root; in btrfs_qgroup_free_refroot()
2188 if (!quota_root) in btrfs_qgroup_free_refroot()
2379 trans = btrfs_start_transaction(fs_info->quota_root, 1); in btrfs_qgroup_rescan_worker()
2387 ret = update_qgroup_status_item(trans, fs_info, fs_info->quota_root); in btrfs_qgroup_rescan_worker()
2392 btrfs_end_transaction(trans, fs_info->quota_root); in btrfs_qgroup_rescan_worker()