This is a 2nd stab at solving the problem of hostwide shared tags for SCSI HBAs. As discussed previously, Ming Lei's most recent series in [0] to use hctx[0] tags for all hctx for a host was a bit messy and intrusive, so seen as a no go. Indeed, blk-mq is designed for separate tags per hctx. This series introduces a different approach to solve that problem, in keeping the per-hctx tags but introducing a new separate shared set of tags, which SCSI HBAs can use for a hostwide tags. Adding support for shared tags should not have a significant performance impact for when shared tags are not requested. Currently I just fixed up the hisi_sas driver to use the shared tags, but should not be much trouble to change others over. Patch #3 is quite experimental at this point. I also threw in a minor tidy-up patch. [0] https://lore.kernel.org/linux-block/20190531022801.10003-1-ming.lei@xxxxxxxxxx/ Hannes Reinecke (1): scsi: Add template flag 'host_tagset' John Garry (3): blk-mq: Remove some unused function arguments blk-mq: Facilitate a shared tags per tagset scsi: hisi_sas: Switch v3 hw to MQ Ming Lei (1): blk-mq: rename BLK_MQ_F_TAG_SHARED as BLK_MQ_F_TAG_QUEUE_SHARED block/blk-core.c | 1 + block/blk-flush.c | 2 + block/blk-mq-debugfs.c | 4 +- block/blk-mq-tag.c | 91 +++++++++++++++++++++++++- block/blk-mq-tag.h | 8 +-- block/blk-mq.c | 91 +++++++++++++++++++------- block/blk-mq.h | 11 +++- drivers/scsi/hisi_sas/hisi_sas.h | 3 +- drivers/scsi/hisi_sas/hisi_sas_main.c | 43 ++++++------ drivers/scsi/hisi_sas/hisi_sas_v3_hw.c | 85 ++++++++++-------------- drivers/scsi/scsi_lib.c | 2 + include/linux/blk-mq.h | 5 +- include/linux/blkdev.h | 1 + include/scsi/scsi_host.h | 3 + 14 files changed, 242 insertions(+), 108 deletions(-) -- 2.17.1