diff options
author | Liu Bo <bo.liu@linux.alibaba.com> | 2018-05-18 05:00:20 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2018-05-30 16:46:44 +0200 |
commit | e6a1d6fd276965db0ca91e91dffc0a6fb7d89254 (patch) | |
tree | dff22e61d0c7251484847aa1122f83eebca73256 /fs/btrfs | |
parent | Btrfs: remove superfluous free_extent_buffer in read_block_for_search (diff) | |
download | linux-e6a1d6fd276965db0ca91e91dffc0a6fb7d89254.tar.xz linux-e6a1d6fd276965db0ca91e91dffc0a6fb7d89254.zip |
Btrfs: use more straightforward extent_buffer_uptodate check
If parent_transid "0" is passed to btrfs_buffer_uptodate(),
btrfs_buffer_uptodate() is equivalent to extent_buffer_uptodate(), but
extent_buffer_uptodate() is preferred since we don't have to look into
verify_parent_transid().
Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>
Reviewed-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/ctree.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c index 820226d42d5d..46afc9743ad0 100644 --- a/fs/btrfs/ctree.c +++ b/fs/btrfs/ctree.c @@ -2445,7 +2445,7 @@ read_block_for_search(struct btrfs_root *root, struct btrfs_path *p, * and give up so that our caller doesn't loop forever * on our EAGAINs. */ - if (!btrfs_buffer_uptodate(tmp, 0, 0)) + if (!extent_buffer_uptodate(tmp)) ret = -EIO; free_extent_buffer(tmp); } else { |