Re: [PATCH 0/2] blk-mq: stop waiting for an SRCU grace period when freeing a tag set
From: Jens Axboe
Date: Fri Oct 16 2026 - 10:30:41 EST
On Thu, 01 Oct 2026 17:17:49 +0800, Qiliang Yuan wrote:
> blk_mq_free_tag_set() calls srcu_barrier() on the tag set's own
> tags_srcu before cleaning it up. That costs a full SRCU grace period,
> 1-3 ms, on every tag set teardown. When the free happens under a lock,
> the cost multiplies. ublk drops its last device reference under the
> global ublk_ctl_mutex, which caps 16-thread deletion of 4000 devices at
> 19 s on 7.3-rc5.
>
> [...]
Applied, thanks!
[1/2] blk-mq: share one tags_srcu instance across all tag sets
commit: e1c51edd6a575ba3b6fc5acb57ed2fec6951a910
[2/2] blk-mq: drop the tag_set argument from blk_mq_free_rq_map/tags
commit: 5f702d4bd61be29f11d07dc1c4a6953d39b28f9f
Best regards,
--
Jens Axboe