From: "liu xiang" <liu.xiang@zlingsmart.com>
To: "Christoph Hellwig" <hch@infradead.org>
Cc: "linux-block" <linux-block@vger.kernel.org>,
"axboe" <axboe@kernel.dk>,
"linux-kernel" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] blk-mq: introduce REQ_COMPLETE_WQ and add a workqueue to complete the request
Date: Thu, 21 Jan 2021 15:33:26 +0800 [thread overview]
Message-ID: <460a3fcd-b7a1-42f4-abc3-b1a267259c26.liu.xiang@zlingsmart.com> (raw)
In-Reply-To: <20210120095409.GB3694085@infradead.org>
On Wed, Jan 20, 2021 at 10:15:22AM +0800, Liu Xiang wrote:
> The commit "40d09b53bfc557af7481b9d80f060a7ac9c7d314" has solved the
> irqsoff problem by completing the request in softirq. But it may cause
> the system to suffer bad preemptoff time.
> Introduce the REQ_COMPLETE_WQ flag and blk_complete workqueue.
> This flag makes the request to be completed in the blk_complete workqueue.
> It can be used for requests that want to cut down both irqsoff and
> preemptoff time.
In addition to bloating the request_queue and introducing the completion
fast path this seems to lack an actual user.
I have tested mmc and virtio_blk drivers. They both have preemptoff problem.
The mmc driver has its own complete workqueue. But it can not work well now.
I think it is better to complete request directly with REQ_HIPRI flag.
The virtio_blk driver can use REQ_COMPLETE_WQ flag to avoid preemptoff problem.
prev parent reply other threads:[~2021-01-21 7:35 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-20 2:15 [PATCH] blk-mq: introduce REQ_COMPLETE_WQ and add a workqueue to complete the request Liu Xiang
2021-01-20 9:54 ` Christoph Hellwig
2021-01-21 7:33 ` liu xiang [this message]
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=460a3fcd-b7a1-42f4-abc3-b1a267259c26.liu.xiang@zlingsmart.com \
--to=liu.xiang@zlingsmart.com \
--cc=axboe@kernel.dk \
--cc=hch@infradead.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).