OSDN Git Service

btrfs: hold a ref on the root in get_subvol_name_from_objectid
authorJosef Bacik <josef@toxicpanda.com>
Thu, 6 Feb 2020 15:24:26 +0000 (10:24 -0500)
committerDavid Sterba <dsterba@suse.com>
Mon, 23 Mar 2020 16:01:31 +0000 (17:01 +0100)
commit5168489a079aacd5626156ce5f8ab77325bcde15
treee1512a8df8d1426c03fa999d1c0e5c3d989e2d89
parent6f9a3da5da9e7e59f3a5a5909aab5f680fe919c9
btrfs: hold a ref on the root in get_subvol_name_from_objectid

We lookup the name of a subvol which means we'll cross into different
roots.  Hold a ref while we're doing the look ups in the fs_root we're
searching.

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/super.c