diff options
author | Nikolay Borisov <nborisov@suse.com> | 2019-12-02 10:40:13 +0100 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2020-01-20 16:40:51 +0100 |
commit | 5c4b691eb8958dfdba9bb77d5ac4897bbaeb9064 (patch) | |
tree | 856cddb416d271b4a62c2f2ca015fccf5a2b25dd /fs/btrfs/tree-log.c | |
parent | btrfs: Rename __btrfs_free_reserved_extent to btrfs_pin_reserved_extent (diff) | |
download | linux-5c4b691eb8958dfdba9bb77d5ac4897bbaeb9064.tar.xz linux-5c4b691eb8958dfdba9bb77d5ac4897bbaeb9064.zip |
btrfs: Remove WARN_ON in walk_log_tree
The log_root passed to walk_log_tree is guaranteed to have its
root_key.objectid always be BTRFS_TREE_LOG_OBJECTID. This is by
merit that all log roots of an ordinary root are allocated in
alloc_log_tree which hard-codes objectid to be BTRFS_TREE_LOG_OBJECTID.
In case walk_log_tree is called for a log tree found by btrfs_read_fs_root
in btrfs_recover_log_trees, that function already ensures
found_key.objectid is BTRFS_TREE_LOG_OBJECTID.
No functional changes.
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to '')
-rw-r--r-- | fs/btrfs/tree-log.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index 47f4c6eea851..9a6b1303fcab 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c @@ -2894,8 +2894,6 @@ static int walk_log_tree(struct btrfs_trans_handle *trans, clear_extent_buffer_dirty(next); } - WARN_ON(log->root_key.objectid != - BTRFS_TREE_LOG_OBJECTID); ret = btrfs_pin_reserved_extent(fs_info, next->start, next->len); if (ret) |