Any number of things could have gone wrong, like ENOMEM or EIO, so don't WARN_ON() if we're unable to find the reloc root in the backref code.
Reported-by: Zygo Blaxell <ce3g8...@umail.furryterror.org> Signed-off-by: Josef Bacik <jo...@toxicpanda.com> --- fs/btrfs/backref.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/backref.c b/fs/btrfs/backref.c index 02d7d7b2563b..f0877d2883f9 100644 --- a/fs/btrfs/backref.c +++ b/fs/btrfs/backref.c @@ -2624,7 +2624,7 @@ static int handle_direct_tree_backref(struct btrfs_backref_cache *cache, /* Only reloc backref cache cares about a specific root */ if (cache->is_reloc) { root = find_reloc_root(cache->fs_info, cur->bytenr); - if (WARN_ON(!root)) + if (!root) return -ENOENT; cur->root = root; } else { -- 2.26.2