]> git.baikalelectronics.ru Git - kernel.git/commit
Revert "btrfs: turn fs_roots_radix in btrfs_fs_info into an XArray"
authorDavid Sterba <dsterba@suse.com>
Fri, 15 Jul 2022 11:59:21 +0000 (13:59 +0200)
committerDavid Sterba <dsterba@suse.com>
Fri, 15 Jul 2022 17:14:28 +0000 (19:14 +0200)
commit76026314416500dbae6e467cb5056f8aa5caf0f4
treecfe8b4c89b38fc3957ff05d8dd302614776891a3
parent046506ee2afbbfec39d658357ebc6dcc65eb6b0a
Revert "btrfs: turn fs_roots_radix in btrfs_fs_info into an XArray"

This reverts commit a086f41191229da11b9412646c940383889ea651.

Revert the xarray conversion, there's a problem with potential
sleep-inside-spinlock [1] when calling xa_insert that triggers GFP_NOFS
allocation. The radix tree used the preloading mechanism to avoid
sleeping but this is not available in xarray.

Conversion from spin lock to mutex is possible but at time of rc6 is
riskier than a clean revert.

[1] https://lore.kernel.org/linux-btrfs/cover.1657097693.git.fdmanana@suse.com/

Reported-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/ctree.h
fs/btrfs/disk-io.c
fs/btrfs/extent-tree.c
fs/btrfs/inode.c
fs/btrfs/tests/btrfs-tests.c
fs/btrfs/transaction.c