diff options
author | Josef Bacik <josef@toxicpanda.com> | 2020-11-06 22:27:33 +0100 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2020-12-08 15:54:09 +0100 |
commit | 1bb96598410ccd52f4224e5584b8015c6d61b81f (patch) | |
tree | 77adb6245a2a98202d4005567ddb110617655935 /fs/btrfs/locking.c | |
parent | btrfs: locking: remove the recursion handling code (diff) | |
download | linux-1bb96598410ccd52f4224e5584b8015c6d61b81f.tar.xz linux-1bb96598410ccd52f4224e5584b8015c6d61b81f.zip |
btrfs: merge back btrfs_read_lock_root_node helpers
We no longer have recursive locking and there's no need for separate
helpers that allowed the transition to rwsem with minimal code changes.
Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/locking.c')
-rw-r--r-- | fs/btrfs/locking.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/btrfs/locking.c b/fs/btrfs/locking.c index 1e36a66fcefa..4190b824eca6 100644 --- a/fs/btrfs/locking.c +++ b/fs/btrfs/locking.c @@ -184,14 +184,13 @@ struct extent_buffer *btrfs_lock_root_node(struct btrfs_root *root) * * Return: root extent buffer with read lock held */ -struct extent_buffer *__btrfs_read_lock_root_node(struct btrfs_root *root, - bool recurse) +struct extent_buffer *btrfs_read_lock_root_node(struct btrfs_root *root) { struct extent_buffer *eb; while (1) { eb = btrfs_root_node(root); - __btrfs_tree_read_lock(eb, BTRFS_NESTING_NORMAL, recurse); + btrfs_tree_read_lock(eb); if (eb == root->node) break; btrfs_tree_read_unlock(eb); |