btrfs: free more things in btrfs_free_fs_info
authorJosef Bacik <josef@toxicpanda.com>
Fri, 24 Jan 2020 14:32:57 +0000 (09:32 -0500)
committerDavid Sterba <dsterba@suse.com>
Mon, 23 Mar 2020 16:01:32 +0000 (17:01 +0100)
commit141386e1a5d641d6d89a7794f806a31945ec1e9f
treeb67dbf0926adfa5ab9de5817cf7f96cfc5531a7c
parentbc44d7c4b2b179c4b74fba208b9908e2ecbc1b4d
btrfs: free more things in btrfs_free_fs_info

Things like the percpu_counters, the mapping_tree, and the csum hash can
all be freed at btrfs_free_fs_info time, since the helpers all check if
the structure has been initialized already.  This significantly cleans
up the error cases in open_ctree.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/disk-io.c