]> Git Repo - linux.git/commit
blk-mq: remove synchronize_rcu() from blk_mq_del_queue_tag_set()
authorMing Lei <[email protected]>
Mon, 25 Jun 2018 11:31:48 +0000 (19:31 +0800)
committerJens Axboe <[email protected]>
Mon, 9 Jul 2018 15:07:52 +0000 (09:07 -0600)
commit97889f9ac24f8d2fc8e703ea7f80c162bab10d4d
treef8280901685cfc59ae03e92ea91a29a567f3b7b6
parent5815839b3ca16bb1d45939270871169f6803a121
blk-mq: remove synchronize_rcu() from blk_mq_del_queue_tag_set()

We have to remove synchronize_rcu() from blk_queue_cleanup(),
otherwise long delay can be caused during lun probe. For removing
it, we have to avoid to iterate the set->tag_list in IO path, eg,
blk_mq_sched_restart().

This patch reverts 5b79413946d (Revert "blk-mq: don't handle
TAG_SHARED in restart"). Given we have fixed enough IO hang issue,
and there isn't any reason to restart all queues in one tags any more,
see the following reasons:

1) blk-mq core can deal with shared-tags case well via blk_mq_get_driver_tag(),
which can wake up queues waiting for driver tag.

2) SCSI is a bit special because it may return BLK_STS_RESOURCE if queue,
target or host is ready, but SCSI built-in restart can cover all these well,
see scsi_end_request(), queue will be rerun after any request initiated from
this host/target is completed.

In my test on scsi_debug(8 luns), this patch may improve IOPS by 20% ~ 30%
when running I/O on these 8 luns concurrently.

Fixes: 705cda97ee3a ("blk-mq: Make it safe to use RCU to iterate over blk_mq_tag_set.tag_list")
Cc: Omar Sandoval <[email protected]>
Cc: Bart Van Assche <[email protected]>
Cc: Christoph Hellwig <[email protected]>
Cc: Martin K. Petersen <[email protected]>
Cc: [email protected]
Reported-by: Andrew Jones <[email protected]>
Tested-by: Andrew Jones <[email protected]>
Signed-off-by: Ming Lei <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
block/blk-mq-sched.c
block/blk-mq.c
include/linux/blkdev.h
This page took 0.054301 seconds and 4 git commands to generate.