* [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
@ 2022-07-21 0:33 Ming Lei
2022-07-25 11:48 ` Ming Lei
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: Ming Lei @ 2022-07-21 0:33 UTC (permalink / raw)
To: Christoph Hellwig, linux-nvme, Chaitanya Kulkarni
Cc: Sagi Grimberg, Keith Busch, James Smart, Ming Lei, Ewan D . Milne
Without restarting admin queue in __nvme_fc_abort_outstanding_ios(),
it leaves controller not capable of handling admin pt request, and
causes io hang.
Fixes it by restarting admin queue if the caller of __nvme_fc_abort_outstanding_ios
requires to restart queue.
Tested-by: Ewan D. Milne <emilne@redhat.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
---
drivers/nvme/host/fc.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/nvme/host/fc.c b/drivers/nvme/host/fc.c
index 9987797620b6..8d14df8eeab8 100644
--- a/drivers/nvme/host/fc.c
+++ b/drivers/nvme/host/fc.c
@@ -2533,6 +2533,8 @@ __nvme_fc_abort_outstanding_ios(struct nvme_fc_ctrl *ctrl, bool start_queues)
blk_mq_tagset_busy_iter(&ctrl->admin_tag_set,
nvme_fc_terminate_exchange, &ctrl->ctrl);
blk_mq_tagset_wait_completed_request(&ctrl->admin_tag_set);
+ if (start_queues)
+ nvme_start_admin_queue(&ctrl->ctrl);
}
static void
--
2.31.1
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-07-21 0:33 [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue Ming Lei
@ 2022-07-25 11:48 ` Ming Lei
2022-07-26 11:13 ` Christoph Hellwig
2022-07-25 11:52 ` Sagi Grimberg
` (2 subsequent siblings)
3 siblings, 1 reply; 9+ messages in thread
From: Ming Lei @ 2022-07-25 11:48 UTC (permalink / raw)
To: Christoph Hellwig, linux-nvme, Chaitanya Kulkarni
Cc: Sagi Grimberg, Keith Busch, James Smart, Ewan D . Milne
On Thu, Jul 21, 2022 at 08:33:58AM +0800, Ming Lei wrote:
> Without restarting admin queue in __nvme_fc_abort_outstanding_ios(),
> it leaves controller not capable of handling admin pt request, and
> causes io hang.
>
> Fixes it by restarting admin queue if the caller of __nvme_fc_abort_outstanding_ios
> requires to restart queue.
>
> Tested-by: Ewan D. Milne <emilne@redhat.com>
> Signed-off-by: Ming Lei <ming.lei@redhat.com>
> ---
Hello Guys,
Ping...
Thanks,
Ming
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-07-21 0:33 [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue Ming Lei
2022-07-25 11:48 ` Ming Lei
@ 2022-07-25 11:52 ` Sagi Grimberg
2022-07-27 17:00 ` James Smart
2022-07-28 16:06 ` Christoph Hellwig
3 siblings, 0 replies; 9+ messages in thread
From: Sagi Grimberg @ 2022-07-25 11:52 UTC (permalink / raw)
To: Ming Lei, Christoph Hellwig, linux-nvme, Chaitanya Kulkarni
Cc: Keith Busch, James Smart, Ewan D . Milne
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-07-25 11:48 ` Ming Lei
@ 2022-07-26 11:13 ` Christoph Hellwig
2022-07-26 20:42 ` Ewan Milne
0 siblings, 1 reply; 9+ messages in thread
From: Christoph Hellwig @ 2022-07-26 11:13 UTC (permalink / raw)
To: Ming Lei
Cc: Christoph Hellwig, linux-nvme, Chaitanya Kulkarni, Sagi Grimberg,
Keith Busch, James Smart, Ewan D . Milne
On Mon, Jul 25, 2022 at 07:48:52PM +0800, Ming Lei wrote:
> Hello Guys,
>
> Ping...
I'm waiting for a review from James, who apparently just got back from
his vacation.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-07-26 11:13 ` Christoph Hellwig
@ 2022-07-26 20:42 ` Ewan Milne
0 siblings, 0 replies; 9+ messages in thread
From: Ewan Milne @ 2022-07-26 20:42 UTC (permalink / raw)
To: Christoph Hellwig
Cc: Ming Lei, linux-nvme, Chaitanya Kulkarni, Sagi Grimberg,
Keith Busch, James Smart
I have a reproducible test case, FWIW. (It requires extra kernel code
to inject ERSP_IU errors though).
If you get an error at the wrong time when issuing commands e.g. in
nvme_init_ctrl_finish() it ends up
with a command on the admin queue and the admin queue quiesced.
-Ewan
On Tue, Jul 26, 2022 at 7:13 AM Christoph Hellwig <hch@lst.de> wrote:
>
> On Mon, Jul 25, 2022 at 07:48:52PM +0800, Ming Lei wrote:
> > Hello Guys,
> >
> > Ping...
>
> I'm waiting for a review from James, who apparently just got back from
> his vacation.
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-07-21 0:33 [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue Ming Lei
2022-07-25 11:48 ` Ming Lei
2022-07-25 11:52 ` Sagi Grimberg
@ 2022-07-27 17:00 ` James Smart
2022-07-28 16:06 ` Christoph Hellwig
3 siblings, 0 replies; 9+ messages in thread
From: James Smart @ 2022-07-27 17:00 UTC (permalink / raw)
To: Ming Lei, Christoph Hellwig, linux-nvme, Chaitanya Kulkarni
Cc: Sagi Grimberg, Keith Busch, James Smart, Ewan D . Milne
On 7/20/2022 5:33 PM, Ming Lei wrote:
> Without restarting admin queue in __nvme_fc_abort_outstanding_ios(),
> it leaves controller not capable of handling admin pt request, and
> causes io hang.
>
> Fixes it by restarting admin queue if the caller of __nvme_fc_abort_outstanding_ios
> requires to restart queue.
>
> Tested-by: Ewan D. Milne <emilne@redhat.com>
> Signed-off-by: Ming Lei <ming.lei@redhat.com>
> ---
> drivers/nvme/host/fc.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/nvme/host/fc.c b/drivers/nvme/host/fc.c
> index 9987797620b6..8d14df8eeab8 100644
> --- a/drivers/nvme/host/fc.c
> +++ b/drivers/nvme/host/fc.c
> @@ -2533,6 +2533,8 @@ __nvme_fc_abort_outstanding_ios(struct nvme_fc_ctrl *ctrl, bool start_queues)
> blk_mq_tagset_busy_iter(&ctrl->admin_tag_set,
> nvme_fc_terminate_exchange, &ctrl->ctrl);
> blk_mq_tagset_wait_completed_request(&ctrl->admin_tag_set);
> + if (start_queues)
> + nvme_start_admin_queue(&ctrl->ctrl);
> }
>
> static void
Looks correct.
Reviewed-by: James Smart <jsmart2021@gmail.com>
-- james
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-07-21 0:33 [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue Ming Lei
` (2 preceding siblings ...)
2022-07-27 17:00 ` James Smart
@ 2022-07-28 16:06 ` Christoph Hellwig
2022-08-02 2:04 ` Ming Lei
3 siblings, 1 reply; 9+ messages in thread
From: Christoph Hellwig @ 2022-07-28 16:06 UTC (permalink / raw)
To: Ming Lei
Cc: Christoph Hellwig, linux-nvme, Chaitanya Kulkarni, Sagi Grimberg,
Keith Busch, James Smart, Ewan D . Milne
Thanks,
applied to nvme-5.20.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-07-28 16:06 ` Christoph Hellwig
@ 2022-08-02 2:04 ` Ming Lei
2022-08-02 13:34 ` Christoph Hellwig
0 siblings, 1 reply; 9+ messages in thread
From: Ming Lei @ 2022-08-02 2:04 UTC (permalink / raw)
To: Christoph Hellwig
Cc: linux-nvme, Chaitanya Kulkarni, Sagi Grimberg, Keith Busch,
James Smart, Ewan D . Milne
On Thu, Jul 28, 2022 at 06:06:37PM +0200, Christoph Hellwig wrote:
> Thanks,
>
> applied to nvme-5.20.
Hi Christoph,
Looks not find the patch in your nvme-5.20 tree, :-(
http://git.infradead.org/nvme.git/shortlog/refs/heads/nvme-5.20
Thanks,
Ming
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue
2022-08-02 2:04 ` Ming Lei
@ 2022-08-02 13:34 ` Christoph Hellwig
0 siblings, 0 replies; 9+ messages in thread
From: Christoph Hellwig @ 2022-08-02 13:34 UTC (permalink / raw)
To: Ming Lei
Cc: Christoph Hellwig, linux-nvme, Chaitanya Kulkarni, Sagi Grimberg,
Keith Busch, James Smart, Ewan D . Milne
On Tue, Aug 02, 2022 at 10:04:21AM +0800, Ming Lei wrote:
> On Thu, Jul 28, 2022 at 06:06:37PM +0200, Christoph Hellwig wrote:
> > Thanks,
> >
> > applied to nvme-5.20.
>
> Hi Christoph,
>
> Looks not find the patch in your nvme-5.20 tree, :-(
I've pushed it out now.
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2022-08-02 13:34 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-21 0:33 [PATCH] nvme-fc: restart admin queue if the caller needs to restart queue Ming Lei
2022-07-25 11:48 ` Ming Lei
2022-07-26 11:13 ` Christoph Hellwig
2022-07-26 20:42 ` Ewan Milne
2022-07-25 11:52 ` Sagi Grimberg
2022-07-27 17:00 ` James Smart
2022-07-28 16:06 ` Christoph Hellwig
2022-08-02 2:04 ` Ming Lei
2022-08-02 13:34 ` Christoph Hellwig
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.