]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
btrfs: Move btrfs_check_chunk_valid() to tree-check.[ch] and export it
authorQu Wenruo <wqu@suse.com>
Wed, 20 Mar 2019 05:16:42 +0000 (13:16 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 10 Nov 2020 11:35:56 +0000 (12:35 +0100)
commit5d123c6335e82db8de1e2fe1c15563e003245438
tree8461bccfe623e25ca1cc47c90ab2dc074ff0d4b4
parent1527c0e0229d2dd1c8ae1e73b1579bd8d5866b5b
btrfs: Move btrfs_check_chunk_valid() to tree-check.[ch] and export it

commit 82fc28fbedbb59642f05215db3b0ef4eb91aa31d upstream.

By function, chunk item verification is more suitable to be done inside
tree-checker.

So move btrfs_check_chunk_valid() to tree-checker.c and export it.

And since it's now moved to tree-checker, also add a better comment for
what this function is doing.

Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
[bwh: Cherry-picked for 4.19 to ease backporting later fixes]
Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/btrfs/tree-checker.c
fs/btrfs/tree-checker.h
fs/btrfs/volumes.c