Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

btrfs: Remove fs_info from btrfs_del_root

It can be referenced from the passed transaction handle.

Signed-off-by: Lu Fengqi <lufq.fnst@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>

authored by

Lu Fengqi and committed by
David Sterba
ab9ce7d4 9add2945

+6 -6
+1 -1
fs/btrfs/ctree.h
··· 2993 2993 u64 root_id, u64 ref_id, u64 dirid, u64 *sequence, 2994 2994 const char *name, int name_len); 2995 2995 int btrfs_del_root(struct btrfs_trans_handle *trans, 2996 - struct btrfs_fs_info *fs_info, const struct btrfs_key *key); 2996 + const struct btrfs_key *key); 2997 2997 int btrfs_insert_root(struct btrfs_trans_handle *trans, struct btrfs_root *root, 2998 2998 const struct btrfs_key *key, 2999 2999 struct btrfs_root_item *item);
+1 -1
fs/btrfs/extent-tree.c
··· 9028 9028 if (err) 9029 9029 goto out_end_trans; 9030 9030 9031 - ret = btrfs_del_root(trans, fs_info, &root->root_key); 9031 + ret = btrfs_del_root(trans, &root->root_key); 9032 9032 if (ret) { 9033 9033 btrfs_abort_transaction(trans, ret); 9034 9034 err = ret;
+1 -1
fs/btrfs/free-space-tree.c
··· 1236 1236 if (ret) 1237 1237 goto abort; 1238 1238 1239 - ret = btrfs_del_root(trans, fs_info, &free_space_root->root_key); 1239 + ret = btrfs_del_root(trans, &free_space_root->root_key); 1240 1240 if (ret) 1241 1241 goto abort; 1242 1242
+1 -1
fs/btrfs/qgroup.c
··· 1088 1088 goto end_trans; 1089 1089 } 1090 1090 1091 - ret = btrfs_del_root(trans, fs_info, &quota_root->root_key); 1091 + ret = btrfs_del_root(trans, &quota_root->root_key); 1092 1092 if (ret) { 1093 1093 btrfs_abort_transaction(trans, ret); 1094 1094 goto end_trans;
+2 -2
fs/btrfs/root-tree.c
··· 320 320 321 321 /* drop the root item for 'key' from the tree root */ 322 322 int btrfs_del_root(struct btrfs_trans_handle *trans, 323 - struct btrfs_fs_info *fs_info, const struct btrfs_key *key) 323 + const struct btrfs_key *key) 324 324 { 325 - struct btrfs_root *root = fs_info->tree_root; 325 + struct btrfs_root *root = trans->fs_info->tree_root; 326 326 struct btrfs_path *path; 327 327 int ret; 328 328