From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f102.google.com (mail-wr1-f102.google.com [209.85.221.102]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B838A36E47E for ; Sat, 27 Jun 2026 05:42:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.102 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782538971; cv=none; b=jIToaLp+4z4vI4W5uRa/QyIC8RCYaQN3zOLTZSnPES8BQzuOO94nw8exZ8rKScWTSNdDhFYWn83MM1W4ICdr3cY8c4pT9RdqrIWUE5h5VDKumZEZVvf133u52t/ztJF/Fsq0rVDcpAk256KYK9ynEK4Sy4vA9EAuNtVky9OEC9E= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782538971; c=relaxed/simple; bh=3m0aj9nfgTpMPyTKR0ZRW5BNaB7D8LtbyalSkO5JWfo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=cXBDdQ+qFBEuEC3UvVfwwNREGQnj6AINTD7eSSQ0dtx4Rxy9D1NHjF9J/KPdGA18+monXJvOkNLZCEaGn8kR5Vfm4tOTfuHi3ikzpQej1R28REnWoVgHVDvQBhN4EifQ+RkmfNAhuUr977w80QOmdv78drkbvRxv+BrvYqPtcWM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=purestorage.com; spf=pass smtp.mailfrom=purestorage.com; dkim=pass (2048-bit key) header.d=purestorage.com header.i=@purestorage.com header.b=IrZ8LMpA; arc=none smtp.client-ip=209.85.221.102 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=purestorage.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=purestorage.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=purestorage.com header.i=@purestorage.com header.b="IrZ8LMpA" Received: by mail-wr1-f102.google.com with SMTP id ffacd0b85a97d-46cf53b51ffso129760f8f.1 for ; Fri, 26 Jun 2026 22:42:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=purestorage.com; s=google2022; t=1782538968; x=1783143768; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=TdMp+kUDXzcCHRaLfP/G+q/ZKBuIsQ8XItHm4El4CqI=; b=IrZ8LMpAFf2rtrlm4o1mva2y7IIHa82m7d3kd1p3482zXtCHojgrAA0dfJoktVB8h2 zh0qwsoUoMs5a7bSGT+yv0kgcxUGK99JWgrHpjPDdoSLAfqWYLHtYv3Zh2kUya5aKlaM Bw6diaYQU0iuPmGQxRm7bDC66vT6Ye2LOFyeoYb01P2GzrjcmqVeMOqIu8sTOd2oKNb+ akYGUbqwpjgE23drOmDhCxjR4fNHfoXpRpkk0JVPDSkhSK/UvwZ8fBd88NqJS4DF6zmP pBkkwBKJOTxL03EzDef1AbRPrfT9e1vN3aF1hEYgjOSO7Sawr3bmO12SbaFoFDiBBQpK m0kg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1782538968; x=1783143768; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=TdMp+kUDXzcCHRaLfP/G+q/ZKBuIsQ8XItHm4El4CqI=; b=raSDpf6dteIwENmvpOP5X+U8i2U1vQo9kPzAcmO/zGljpb8XOMqiCjSFwoNlRqKvKX jQjEgEswu6nhmFlvIjCU38ocd7GNcdOquWHUN1AqFtI7/fA3u3TVXqhcTuflL+JVAgU7 nMcUHbXcQXYK9sF1NtpmHOzJI9cb9tGrjVoTSgwbKbb28Xh3OlAZ7059jRjWqLe4IqaO FBK44jQfn2FCRwWmK9Jp/38ctX8I95rwn2SVkruH2+N/Iv8GxImHYZEoRt9WUkNGGg97 /GUyUTVnjRGxPCHoLiR6UWMYt0rVXtXnkcY6VwChtya2eKx/pQoNbfFT6+q8J++HEtPQ wRyg== X-Forwarded-Encrypted: i=1; AFNElJ/lbHeuN3vWZLIbZFeJIJI1GLbRRlCqSwzvfGiy0/tZ4804owYgJmOTa3iqx9yTimmUNCAQDw1psy/vjpY=@vger.kernel.org X-Gm-Message-State: AOJu0YwkvUXShVIZiSKVJtJQ8Ud/qrv7xmfczIj8w1Cp5NEm8VIRvG9y VaoTaZhiL1TWHNXeA6z+A39xNIKCvPNfJa/hYKhSpbtXXilmqrLqCNrXXMJL6//89/qpTxXn5uW H1wasyhjNXtr8mie/7NJMQO8cXP27k24xbsM7 X-Gm-Gg: AfdE7clt1HyR8neFIm7Myf8eNEeBi5WcpAI+0dxZOJBzd57pPzNdgHvxXBBCGlYSXUi Q5e2g1GrPVZSK6ARZwWl1YzU5Wu0w4kVaX7Fh2UOul2DwD+fGcAqYq1AblJIu2/mltrQdpjvfvf V+58t6gTaxfu9vPpD007S43DV/Pe1t6qYPRVfN+Pv7qWYKXyzA6yEVP1Ca0d2SppDYoYBONl+N6 9xVemP5TUaXAApStP4xc07nVxtUGRQXbcCOh3+IMw4kXqzxsScoWr4/yWf/BLu5Z/ivvfIuu6b2 1CLIazcnLSpQ7Z0OIkKgViS6j4y0fxK5oCJULBRfdj6k+uMRhn5dcWbwxnxxPX/HqKy9Njgn4fm TDFdf3pidwmxxITs2FLvmoIajq6G36eYTH02S2yxubyM= X-Received: by 2002:a05:600c:c043:b0:492:4708:d73d with SMTP id 5b1f17b1804b1-4926686b471mr48451735e9.1.1782538968091; Fri, 26 Jun 2026 22:42:48 -0700 (PDT) Received: from c7-smtp-2026.dev.purestorage.com ([208.88.159.128]) by smtp-relay.gmail.com with ESMTPS id 5b1f17b1804b1-4926902d9b4sm2356335e9.14.2026.06.26.22.42.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Jun 2026 22:42:48 -0700 (PDT) X-Relaying-Domain: purestorage.com Received: from dev-csander.dev.purestorage.com (bond0.slc5-n17m28-k8s.dev.purestorage.com [IPv6:2620:125:9025:20::a31:41f]) by c7-smtp-2026.dev.purestorage.com (Postfix) with ESMTP id B2CB8402B4; Fri, 26 Jun 2026 23:42:46 -0600 (MDT) Received: by dev-csander.dev.purestorage.com (Postfix, from userid 1557716354) id B0913E40712; Fri, 26 Jun 2026 23:42:46 -0600 (MDT) From: Caleb Sander Mateos To: Jens Axboe , Christoph Hellwig , Sagi Grimberg , Chaitanya Kulkarni , "Martin K. Petersen" Cc: Anuj Gupta , linux-block@vger.kernel.org, linux-nvme@lists.infradead.org, linux-scsi@vger.kernel.org, target-devel@vger.kernel.org, linux-kernel@vger.kernel.org, Caleb Sander Mateos Subject: [PATCH v4 3/5] bio-integrity-fs: use integrity interval instead of sector as seed Date: Fri, 26 Jun 2026 23:42:18 -0600 Message-ID: <20260627054220.2174166-4-csander@purestorage.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260627054220.2174166-1-csander@purestorage.com> References: <20260627054220.2174166-1-csander@purestorage.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit bip_iter.bi_sector is meant to be in units of integrity intervals rather than 512-byte sectors. bio_integrity_verify() doesn't actually use it currently (it uses the passed in struct bvec_iter's bi_sector instead). But let's set it to the expected value for consistency. Signed-off-by: Caleb Sander Mateos Reviewed-by: Anuj Gupta Reviewed-by: Christoph Hellwig --- block/bio-integrity-fs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/bio-integrity-fs.c b/block/bio-integrity-fs.c index 9c5fe5fa8f0d..770eacb2220f 100644 --- a/block/bio-integrity-fs.c +++ b/block/bio-integrity-fs.c @@ -65,11 +65,11 @@ int fs_bio_integrity_verify(struct bio *bio, sector_t sector, unsigned int size) * * This is for use in the submitter after the driver is done with the * bio. Requires the submitter to remember the sector and the size. */ memset(&bip->bip_iter, 0, sizeof(bip->bip_iter)); - bip->bip_iter.bi_sector = sector; + bip->bip_iter.bi_sector = bio_integrity_intervals(bi, sector); bip->bip_iter.bi_size = bio_integrity_bytes(bi, size >> SECTOR_SHIFT); return blk_status_to_errno(bio_integrity_verify(bio, &data_iter)); } static int __init fs_bio_integrity_init(void) -- 2.54.0