diff --git a/fs/btrfs/scrub.c b/fs/btrfs/scrub.c index 185595a7be10c5fb40ad8a963b6600f43fbd6784..b03dd10e1d25873551e39dcd523043f433498b3e 100644 --- a/fs/btrfs/scrub.c +++ b/fs/btrfs/scrub.c @@ -3254,9 +3254,11 @@ static noinline_for_stack int scrub_stripe(struct scrub_ctx *sctx, &extent_dev, &extent_mirror_num); - ret = btrfs_lookup_csums_range(csum_root, logical, - logical + map->stripe_len - 1, - &sctx->csum_list, 1); + ret = btrfs_lookup_csums_range(csum_root, + extent_logical, + extent_logical + + extent_len - 1, + &sctx->csum_list, 1); if (ret) goto out;