From: Filipe Manana Date: Mon, 9 Feb 2026 10:03:08 +0000 (+0000) Subject: btrfs: remove duplicated eb uptodate check in btrfs_buffer_uptodate() X-Git-Tag: v7.1-rc1~231^2~97 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8352b29ad02ba647a32d45862478fb5165666155;p=thirdparty%2Fkernel%2Flinux.git btrfs: remove duplicated eb uptodate check in btrfs_buffer_uptodate() We are calling extent_buffer_uptodate() twice, and the result will not change before the second call. So remove the second call. Reviewed-by: Qu Wenruo Signed-off-by: Filipe Manana Signed-off-by: David Sterba --- diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 9f4f770c7da61..200a165f9a840 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c @@ -121,8 +121,7 @@ int btrfs_buffer_uptodate(struct extent_buffer *eb, u64 parent_transid, bool ato if (atomic) return -EAGAIN; - if (!extent_buffer_uptodate(eb) || - btrfs_header_generation(eb) != parent_transid) { + if (btrfs_header_generation(eb) != parent_transid) { btrfs_err_rl(eb->fs_info, "parent transid verify failed on logical %llu mirror %u wanted %llu found %llu", eb->start, eb->read_mirror,