public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dm-verity: switch to bio_advance_iter_single()
@ 2026-01-11 20:27 Eric Biggers
  2026-01-23 23:21 ` Sami Tolvanen
  0 siblings, 1 reply; 2+ messages in thread
From: Eric Biggers @ 2026-01-11 20:27 UTC (permalink / raw)
  To: dm-devel, Alasdair Kergon, Mike Snitzer, Mikulas Patocka,
	Benjamin Marzinski
  Cc: Sami Tolvanen, linux-kernel, Eric Biggers

dm-verity doesn't support data blocks that span pages, and it sets
dma_alignment accordingly.  As such, instead of using
bio_advance_iter(), it can use the more lightweight function
bio_advance_iter_single() to get the same result.

Signed-off-by: Eric Biggers <ebiggers@kernel.org>
---
 drivers/md/dm-verity-target.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/md/dm-verity-target.c b/drivers/md/dm-verity-target.c
index 777a0ebe8536..4b86f7faffd0 100644
--- a/drivers/md/dm-verity-target.c
+++ b/drivers/md/dm-verity-target.c
@@ -526,11 +526,11 @@ static int verity_verify_io(struct dm_verity_io *io)
 		iter = &iter_copy;
 	} else
 		iter = &io->iter;
 
 	for (b = 0; b < io->n_blocks;
-	     b++, bio_advance_iter(bio, iter, block_size)) {
+	     b++, bio_advance_iter_single(bio, iter, block_size)) {
 		sector_t blkno = io->block + b;
 		struct pending_block *block;
 		bool is_zero;
 		struct bio_vec bv;
 		void *data;

base-commit: 8fbb8fe75d4cf92eaa7b21828ec39c1bf79a262f
-- 
2.52.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] dm-verity: switch to bio_advance_iter_single()
  2026-01-11 20:27 [PATCH] dm-verity: switch to bio_advance_iter_single() Eric Biggers
@ 2026-01-23 23:21 ` Sami Tolvanen
  0 siblings, 0 replies; 2+ messages in thread
From: Sami Tolvanen @ 2026-01-23 23:21 UTC (permalink / raw)
  To: Eric Biggers
  Cc: dm-devel, Alasdair Kergon, Mike Snitzer, Mikulas Patocka,
	Benjamin Marzinski, linux-kernel

On Sun, Jan 11, 2026 at 12:28 PM Eric Biggers <ebiggers@kernel.org> wrote:
>
> dm-verity doesn't support data blocks that span pages, and it sets
> dma_alignment accordingly.  As such, instead of using
> bio_advance_iter(), it can use the more lightweight function
> bio_advance_iter_single() to get the same result.
>
> Signed-off-by: Eric Biggers <ebiggers@kernel.org>

Reviewed-by: Sami Tolvanen <samitolvanen@google.com>

Sami

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-01-23 23:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-11 20:27 [PATCH] dm-verity: switch to bio_advance_iter_single() Eric Biggers
2026-01-23 23:21 ` Sami Tolvanen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox