From: Christoph Hellwig <hch@lst.de>
To: Caleb Sander Mateos <csander@purestorage.com>
Cc: Jens Axboe <axboe@kernel.dk>, Damien Le Moal <dlemoal@kernel.org>,
Christoph Hellwig <hch@lst.de>,
linux-block@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] zloop: use blk_rq_nr_phys_segments() instead of iterating bvecs
Date: Tue, 11 Nov 2025 10:07:55 +0100 [thread overview]
Message-ID: <20251111090755.GA12545@lst.de> (raw)
In-Reply-To: <20251108230101.4187106-3-csander@purestorage.com>
On Sat, Nov 08, 2025 at 04:01:01PM -0700, Caleb Sander Mateos wrote:
> The number of bvecs can be obtained directly from struct request's
> nr_phys_segments field via blk_rq_nr_phys_segments(), so use that
> instead of iterating over the bvecs an extra time.
Same reason this doesn't work as Ming explained for ublk.
Maybe we should lift this code from loop/zloop into a well documented
common helper to make it more obvious?
next prev parent reply other threads:[~2025-11-11 9:08 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-08 23:00 [PATCH 0/2] use blk_rq_nr_phys_segments() instead of iterating bvecs Caleb Sander Mateos
2025-11-08 23:01 ` [PATCH 1/2] loop: " Caleb Sander Mateos
2025-11-09 12:19 ` Ming Lei
2025-11-09 19:05 ` Chaitanya Kulkarni
2025-11-10 16:47 ` Caleb Sander Mateos
2025-11-10 21:34 ` Chaitanya Kulkarni
2025-11-11 1:22 ` Ming Lei
2025-11-08 23:01 ` [PATCH 2/2] zloop: " Caleb Sander Mateos
2025-11-11 9:07 ` Christoph Hellwig [this message]
2025-11-11 18:19 ` Chaitanya Kulkarni
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=20251111090755.GA12545@lst.de \
--to=hch@lst.de \
--cc=axboe@kernel.dk \
--cc=csander@purestorage.com \
--cc=dlemoal@kernel.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).