From: Ming Lei <ming.lei@redhat.com>
To: Jens Axboe <axboe@kernel.dk>, Christoph Hellwig <hch@lst.de>,
linux-block@vger.kernel.org, Thomas Gleixner <tglx@linutronix.de>
Cc: John Garry <john.garry@huawei.com>,
Sagi Grimberg <sagi@grimberg.me>, Daniel Wagner <dwagner@suse.de>,
Wen Xiong <wenxiong@us.ibm.com>
Subject: Re: [PATCH V7 0/3] blk-mq: fix blk_mq_alloc_request_hctx
Date: Fri, 20 Aug 2021 06:38:50 +0800 [thread overview]
Message-ID: <YR7demOSG6MKFVAF@T590> (raw)
In-Reply-To: <20210818144428.896216-1-ming.lei@redhat.com>
On Wed, Aug 18, 2021 at 10:44:25PM +0800, Ming Lei wrote:
> Hi,
>
> blk_mq_alloc_request_hctx() is used by NVMe fc/rdma/tcp/loop to connect
> io queue. Also the sw ctx is chosen as the 1st online cpu in hctx->cpumask.
> However, all cpus in hctx->cpumask may be offline.
>
> This usage model isn't well supported by blk-mq which supposes allocator is
> always done on one online CPU in hctx->cpumask. This assumption is
> related with managed irq, which also requires blk-mq to drain inflight
> request in this hctx when the last cpu in hctx->cpumask is going to
> offline.
>
> However, NVMe fc/rdma/tcp/loop don't use managed irq, so we should allow
> them to ask for request allocation when the specified hctx is inactive
> (all cpus in hctx->cpumask are offline). Fix blk_mq_alloc_request_hctx() by
> allowing to allocate request when all CPUs of this hctx are offline.
>
> Wen Xiong has verified V4 in her nvmef test.
>
> V7:
> - move blk_mq_hctx_use_managed_irq() into block/blk-mq.c, 3/3
Hello Jens,
NVMe TCP and others have been a bit popular recent days, and the kernel panic
of blk_mq_alloc_request_hctx() has annoyed people for a bit long.
Any chance to pull the three patches in so we can fix them in 5.15?
Thanks,
Ming
prev parent reply other threads:[~2021-08-19 22:39 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-18 14:44 [PATCH V7 0/3] blk-mq: fix blk_mq_alloc_request_hctx Ming Lei
2021-08-18 14:44 ` [PATCH V7 1/3] genirq: add device_has_managed_msi_irq Ming Lei
2021-10-11 18:23 ` Varad Gautam
2021-08-18 14:44 ` [PATCH V7 2/3] blk-mq: mark if one queue map uses managed irq Ming Lei
2021-08-23 17:17 ` Sagi Grimberg
2021-08-18 14:44 ` [PATCH V7 3/3] blk-mq: don't deactivate hctx if managed irq isn't used Ming Lei
2021-08-23 17:18 ` Sagi Grimberg
2021-09-15 16:14 ` Daniel Wagner
2021-09-16 2:17 ` Ming Lei
2021-09-16 7:42 ` Daniel Wagner
2021-09-16 8:13 ` Ming Lei
2021-10-04 12:25 ` [RFC] nvme-fc: Allow managed IRQs Daniel Wagner
2021-08-19 22:38 ` Ming Lei [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=YR7demOSG6MKFVAF@T590 \
--to=ming.lei@redhat.com \
--cc=axboe@kernel.dk \
--cc=dwagner@suse.de \
--cc=hch@lst.de \
--cc=john.garry@huawei.com \
--cc=linux-block@vger.kernel.org \
--cc=sagi@grimberg.me \
--cc=tglx@linutronix.de \
--cc=wenxiong@us.ibm.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