public inbox for linux-nvme@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] improve nvme quiesce time for large amount of namespaces
@ 2022-10-20  3:53 Chao Leng
  2022-10-20  3:53 ` [PATCH v3 1/2] blk-mq: add tagset quiesce interface Chao Leng
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Chao Leng @ 2022-10-20  3:53 UTC (permalink / raw)
  To: linux-nvme, linux-block
  Cc: hch, sagi, kbusch, lengchao, axboe, ming.lei, paulmck

Now nvme_stop_queues quiesce all queues one by one. Every queue must
wait a grace period(rcu or srcu). If the controller has a large amount
of namespaces, the total waiting time is very long.
Test result: the total waiting time is more than 20 seconds when the
controller has 256 namespace.

This set improves the quiesce time when using a large set of namespaces,
which also improves I/O failover time in a multipath environment.

We improve for both non-blocking tagset and blocking tagset introducing
blk_mq_[un]quiesce_tagset which works on all request queues over a given
tagset in parallel (which is the case in nvme).

Changes from v2:
- replace call_srcu to start_poll_synchronize_srcu
- rename the flag name to make it accurate.
- move unquiescing queue outside from nvme_set_queue_dying
- add mutex to ensure that all queues are quiesced after set the NVME_CTRL_STOPPED.

Changes from v1:
- improvement is based on tagset rather than namesapces

Chao Leng (2):
  blk-mq: add tagset quiesce interface
  nvme: use blk_mq_[un]quiesce_tagset

 block/blk-mq.c           | 76 ++++++++++++++++++++++++++++++++++++++++++++++++
 drivers/nvme/host/core.c | 57 +++++++++++++++---------------------
 drivers/nvme/host/nvme.h |  3 +-
 include/linux/blk-mq.h   |  2 ++
 include/linux/blkdev.h   |  3 ++
 5 files changed, 106 insertions(+), 35 deletions(-)

-- 
2.16.4



^ permalink raw reply	[flat|nested] 12+ messages in thread
* [PATCH v2 0/2] improve nvme quiesce time for large amount of namespaces
@ 2022-10-13  9:44 Chao Leng
  2022-10-13 14:32 ` Chaitanya Kulkarni
  0 siblings, 1 reply; 12+ messages in thread
From: Chao Leng @ 2022-10-13  9:44 UTC (permalink / raw)
  To: linux-nvme, linux-block; +Cc: hch, sagi, kbusch, lengchao, ming.lei, axboe

This set improves the quiesce time when using a large set of
namespaces, which also improves I/O failover time in a multipath environment.

We improve for both non-blocking hctxs and blocking hctxs introducing
blk_mq_[un]quiesce_tagset which works on all request queues over a given
tagset in parallel (which is the case in nvme) for both tagset types (blocking
and non-blocking);

Changes from v1:
- improvement is based on tagset rather than namesapces

Chao Leng (2):
  blk-mq: add tagset quiesce interface
  nvme: use blk_mq_[un]quiesce_tagset

 block/blk-mq.c           | 75 ++++++++++++++++++++++++++++++++++++++++++++++++
 drivers/nvme/host/core.c | 42 +++++++++------------------
 drivers/nvme/host/nvme.h |  2 +-
 include/linux/blk-mq.h   |  2 ++
 include/linux/blkdev.h   |  2 ++
 5 files changed, 93 insertions(+), 30 deletions(-)

-- 
2.16.4



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-10-20 16:11 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-20  3:53 [PATCH v2 0/2] improve nvme quiesce time for large amount of namespaces Chao Leng
2022-10-20  3:53 ` [PATCH v3 1/2] blk-mq: add tagset quiesce interface Chao Leng
2022-10-20 16:11   ` Paul E. McKenney
2022-10-20  3:53 ` [PATCH v3 2/2] nvme: use blk_mq_[un]quiesce_tagset Chao Leng
2022-10-20  6:11   ` Sagi Grimberg
2022-10-20  9:47     ` Chao Leng
2022-10-20  6:34 ` [PATCH v2 0/2] improve nvme quiesce time for large amount of namespaces Christoph Hellwig
2022-10-20  9:36   ` Chao Leng
  -- strict thread matches above, loose matches on Subject: below --
2022-10-13  9:44 Chao Leng
2022-10-13 14:32 ` Chaitanya Kulkarni
2022-10-14  2:12   ` Chao Leng
2022-10-15  0:30     ` Chaitanya Kulkarni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox