From: Ming Lei <ming.lei@redhat.com>
To: Christoph Hellwig <hch@lst.de>
Cc: Keith Busch <kbusch@kernel.org>,
Bart Van Assche <bvanassche@acm.org>,
Jens Axboe <axboe@kernel.dk>,
linux-block@vger.kernel.org, ming.lei@redhat.com
Subject: Re: [PATCH V2 2/2] blk-mq: make sure elevator callbacks aren't called for passthrough request
Date: Wed, 17 May 2023 16:58:57 +0800 [thread overview]
Message-ID: <ZGSXUTA5odBi2Jr0@ovpn-8-19.pek2.redhat.com> (raw)
In-Reply-To: <20230517072218.GB27026@lst.de>
On Wed, May 17, 2023 at 09:22:18AM +0200, Christoph Hellwig wrote:
> On Tue, May 16, 2023 at 04:39:05PM +0800, Ming Lei wrote:
> > I can understand the point, but it may not be done by single flag,
>
> Can you explain why? Note that we also already have RQF_ELVPRIV for
> any request that has elevator private data. I don't really think we
> need a third flag.
RQF_ELVPRIV isn't same with RQF_ELV, and follows the two's relationship:
RQF_ELVPRIV == (RQF_ELV && non_flush_pt_req && !e->type->ops.prepare_request)
RQF_ELVPRIV can be replaced with the above expression to save one flag.
RQF_ELV isn't same with RQF_SCHED_TAGS too, RQF_ELV should be used for
checking if elevator callback is needed, and RQF_SCHED_TAGS is for allocating
req/tag and dealing with tags busy things.
In case of q->elevator, RQF_SCHED_TAGS is always set, but
- for pt/flush request, RQF_ELV is cleared.
- for other request, RQF_ELV are set
Then we can avoid any elevator callback for pt/flush request.
thanks,
Ming
next prev parent reply other threads:[~2023-05-17 9:05 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-15 14:45 [PATCH V2 0/2] blk-mq: handle passthrough request as really passthrough Ming Lei
2023-05-15 14:46 ` [PATCH V2 1/2] blk-mq: don't queue plugged passthrough requests into scheduler Ming Lei
2023-05-16 6:22 ` Christoph Hellwig
2023-05-16 8:10 ` Ming Lei
2023-05-17 7:20 ` Christoph Hellwig
2023-05-15 14:46 ` [PATCH V2 2/2] blk-mq: make sure elevator callbacks aren't called for passthrough request Ming Lei
2023-05-15 15:52 ` Bart Van Assche
2023-05-15 20:22 ` Keith Busch
2023-05-16 1:20 ` Ming Lei
2023-05-16 6:24 ` Christoph Hellwig
2023-05-16 8:39 ` Ming Lei
2023-05-17 7:22 ` Christoph Hellwig
2023-05-17 8:58 ` Ming Lei [this message]
2023-05-16 14:47 ` Keith Busch
2023-05-17 3:26 ` Ming Lei
2023-05-17 18:13 ` Keith Busch
2023-05-18 1:22 ` Ming Lei
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=ZGSXUTA5odBi2Jr0@ovpn-8-19.pek2.redhat.com \
--to=ming.lei@redhat.com \
--cc=axboe@kernel.dk \
--cc=bvanassche@acm.org \
--cc=hch@lst.de \
--cc=kbusch@kernel.org \
--cc=linux-block@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.