All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sagi Grimberg <sagi@grimberg.me>
To: Ming Lei <ming.lei@redhat.com>
Cc: Jens Axboe <axboe@kernel.dk>, Christoph Hellwig <hch@lst.de>,
	linux-block@vger.kernel.org,
	Lai Jiangshan <jiangshanlai@gmail.com>,
	"Paul E . McKenney" <paulmck@kernel.org>,
	Josh Triplett <josh@joshtriplett.org>,
	Bart Van Assche <bvanassche@acm.org>
Subject: Re: [RFC PATCH] blk-mq: implement queue quiesce via percpu_ref for BLK_MQ_F_BLOCKING
Date: Wed, 29 Jul 2020 15:37:27 -0700	[thread overview]
Message-ID: <f3ead535-070d-40ec-08b8-56e2c1cd7ba4@grimberg.me> (raw)
In-Reply-To: <20200729154957.GD1698748@T590>


>>>> In case of BLK_MQ_F_BLOCKING, blk-mq uses SRCU to mark read critical
>>>> section during dispatching request, then request queue quiesce is based on
>>>> SRCU. What we want to get is low cost added in fast path.
>>>>
>>>> However, from srcu_read_lock/srcu_read_unlock implementation, not see
>>>> it is quicker than percpu refcount, so use percpu_ref to implement
>>>> queue quiesce. This usage is cleaner and simpler & enough for implementing
>>>> queue quiesce. The main requirement is to make sure all read sections to observe
>>>> QUEUE_FLAG_QUIESCED once blk_mq_quiesce_queue() returns.
>>>>
>>>> Also it becomes much easier to add interface of async queue quiesce.
>>>
>>> BTW, no obvious IOPS difference is observed with this patch applied when running
>>> io on null_blk(blocking, submit_queues=32) in one dual-socket, 32cores system.
>>
>> Thanks Ming, can you test for non-blocking on the same setup?
> 
> OK, I can do that, but this patch supposes to not affect non-blocking,
> care to share your motivation for testing non-blocking?

I think it will be a significant improvement to have a single code path.
The code will be more robust and we won't need to face issues that are
specific for blocking.

If the cost is negligible, I think the upside is worth it.

  reply	other threads:[~2020-07-29 22:37 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-28 13:49 [RFC PATCH] blk-mq: implement queue quiesce via percpu_ref for BLK_MQ_F_BLOCKING Ming Lei
2020-07-29 10:28 ` Ming Lei
2020-07-29 15:42   ` Sagi Grimberg
2020-07-29 15:49     ` Ming Lei
2020-07-29 22:37       ` Sagi Grimberg [this message]
2020-07-30 14:53         ` Ming Lei
2020-07-30 16:10           ` Sagi Grimberg
2020-07-30 18:18             ` Keith Busch
2020-07-30 18:23               ` Sagi Grimberg
2020-07-30 19:27                 ` Keith Busch
2020-07-30 19:53                   ` Jens Axboe
2020-07-30 21:03                     ` Sagi Grimberg
2020-07-31  0:33                       ` Ming Lei
2020-07-31  0:24               ` Ming Lei
2020-07-31  0:28             ` Ming Lei
2020-07-29 11:20 ` Johannes Thumshirn
2020-07-29 16:12 ` Keith Busch
2020-07-29 22:16   ` Ming Lei
2020-07-29 22:42     ` Sagi Grimberg
2020-07-30 15:05       ` 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=f3ead535-070d-40ec-08b8-56e2c1cd7ba4@grimberg.me \
    --to=sagi@grimberg.me \
    --cc=axboe@kernel.dk \
    --cc=bvanassche@acm.org \
    --cc=hch@lst.de \
    --cc=jiangshanlai@gmail.com \
    --cc=josh@joshtriplett.org \
    --cc=linux-block@vger.kernel.org \
    --cc=ming.lei@redhat.com \
    --cc=paulmck@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.