Linux block layer
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Jens Axboe <axboe@kernel.dk>
Cc: Qu Wenruo <quwenruo.btrfs@gmx.com>,
	Keith Busch <kbusch@kernel.org>,
	linux-block@vger.kernel.org
Subject: [PATCH 3/4] iomap: open code bio_iov_iter_get_bdev_pages
Date: Tue,  7 Oct 2025 11:06:27 +0200	[thread overview]
Message-ID: <20251007090642.3251548-4-hch@lst.de> (raw)
In-Reply-To: <20251007090642.3251548-1-hch@lst.de>

Prepare for passing different alignments, and to retired
bio_iov_iter_get_bdev_pages as a global helper.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 fs/iomap/direct-io.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/fs/iomap/direct-io.c b/fs/iomap/direct-io.c
index 9802b2cc29bb..5d5d63efbd57 100644
--- a/fs/iomap/direct-io.c
+++ b/fs/iomap/direct-io.c
@@ -433,7 +433,8 @@ static int iomap_dio_bio_iter(struct iomap_iter *iter, struct iomap_dio *dio)
 		bio->bi_private = dio;
 		bio->bi_end_io = iomap_dio_bio_end_io;
 
-		ret = bio_iov_iter_get_bdev_pages(bio, dio->submit.iter, iomap->bdev);
+		ret = bio_iov_iter_get_pages(bio, dio->submit.iter,
+				bdev_logical_block_size(iomap->bdev) - 1);
 		if (unlikely(ret)) {
 			/*
 			 * We have to stop part way through an IO. We must fall
-- 
2.47.3


  parent reply	other threads:[~2025-10-07  9:06 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-07  9:06 cleanup for the recent bio_iov_iter_get_pages changes Christoph Hellwig
2025-10-07  9:06 ` [PATCH 1/4] block: remove bio_iov_iter_get_pages Christoph Hellwig
2025-10-07  9:06 ` [PATCH 2/4] block: rename bio_iov_iter_get_pages_aligned to bio_iov_iter_get_pages Christoph Hellwig
2025-10-07  9:06 ` Christoph Hellwig [this message]
2025-10-07  9:06 ` [PATCH 4/4] block: move bio_iov_iter_get_bdev_pages to block/fops.c Christoph Hellwig
2025-10-07 11:57   ` shinichiro.kawasaki
2025-10-07 12:57     ` Keith Busch
2025-10-08  0:07       ` Shinichiro Kawasaki
2025-10-07  9:36 ` cleanup for the recent bio_iov_iter_get_pages changes Qu Wenruo
2025-10-07 12:46 ` Keith Busch
2025-10-07 12:55 ` Johannes Thumshirn
2025-10-07 13:31 ` Martin K. Petersen
2025-10-07 14:06 ` Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20251007090642.3251548-4-hch@lst.de \
    --to=hch@lst.de \
    --cc=axboe@kernel.dk \
    --cc=kbusch@kernel.org \
    --cc=linux-block@vger.kernel.org \
    --cc=quwenruo.btrfs@gmx.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox