]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
btrfs: do not readahead in build_backref_tree
authorJosef Bacik <josef@toxicpanda.com>
Fri, 13 Mar 2020 21:09:54 +0000 (17:09 -0400)
committerDavid Sterba <dsterba@suse.com>
Mon, 23 Mar 2020 16:03:50 +0000 (17:03 +0100)
Here we are just searching down to the bytenr we're building the backref
tree for, and all of it's paths to the roots.  These bytenrs are not
guaranteed to be anywhere near each other, so readahead just generates
extra latency.

Reviewed-by: Qu Wenruo <wqu@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>
fs/btrfs/relocation.c

index 7f31dd57de541adaecf5961cbc9fea0960714fcc..63b11e546a87506899137ed849cea44ea199cac7 100644 (file)
@@ -743,8 +743,6 @@ struct backref_node *build_backref_tree(struct reloc_control *rc,
                err = -ENOMEM;
                goto out;
        }
-       path1->reada = READA_FORWARD;
-       path2->reada = READA_FORWARD;
 
        node = alloc_backref_node(cache);
        if (!node) {