Skip to content

Increase SCSI IOPS

Bart Van Assche linux-block linux-scsi 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest6 patches 6 repliesIn review
  2. v2 posting 2/25 patches 8 repliesSuperseded
  3. v2 posting 1/25 patches 1 replySuperseded

Changes in v4 from the cover letter

- Instead of removing the use of cmd->budget_token from the ATA core, introduce the SCSI host flag .needs_budget_token and set it from the ATA core.

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6block: Rename busy_tag_iter_fn into blk_mq_rq_iter_fnblock/blk-mq-tag.c block/blk-mq.h include/linux/blk-mq.h+12 -120 replies
2/6block: Introduce __blk_mq_tagset_iter()block/blk-mq-tag.c+19 -130 replies
3/6block: Introduce blk_mq_tagset_iter()block/blk-mq-tag.c include/linux/blk-mq.h+21 -00 replies
4/6ata: libata: Set .needs_budget_tokendrivers/ata/libata-scsi.c include/scsi/scsi_host.h+4 -00 replies
5/6scsi: core: Generalize scsi_device_busy()drivers/scsi/scsi_lib.c include/scsi/scsi_device.h+39 -40 replies
6/6scsi: core: Improve IOPS in case of host-wide tagsdrivers/scsi/scsi.c drivers/scsi/scsi_scan.c+21 -56 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v4 yet.

Read the v4 thread

Cover letter [PATCH v4 0/6] Increase SCSI IOPS

Hi Martin,

This patch series increases scsi_debug IOPS by 5% on my test setup by disabling SCSI budget management if it is not needed. This patch series improves the performance of many SCSI LLDs, including the UFS and ATA drivers. On my UFS 4 test setup this patch improves IOPS by 1% and reduces the time spent in scsi_mq_get_budget() from 0.22% to 0.01%. The improvement for UFS 5 devices is expected to be significantly larger than what I measured on my UFS 4 test setup.

Please consider this patch series for the next merge window.

Thanks,

Bart.

Changes compared to v3:
- Instead of removing the use of cmd->budget_token from the ATA core, introduce the SCSI host flag .needs_budget_token and set it from the ATA core.

Changes compared to v2:
- Fixed a hang during LUN scanning for ATA devices.

Changes compared to v1:
- Added three block layer patches to introduce the function blk_mq_tagset_iter().
- Applied the optimization not only for host-wide tags but also if there is only a single hardware queue.
- Renamed scsi_device_check_in_flight() into scsi_device_check_allocated().
- Added support for set->shared_tags == NULL in scsi_device_busy().

Bart Van Assche (6):
block: Rename busy_tag_iter_fn into blk_mq_rq_iter_fn
block: Introduce __blk_mq_tagset_iter()
block: Introduce blk_mq_tagset_iter()
ata: libata: Set .needs_budget_token
scsi: core: Generalize scsi_device_busy()
scsi: core: Improve IOPS in case of host-wide tags

 block/blk-mq-tag.c         | 67 ++++++++++++++++++++++++++------------
 block/blk-mq.h             |  4 +--
 drivers/ata/libata-scsi.c  |  1 +
 drivers/scsi/scsi.c        |  6 ++--
 drivers/scsi/scsi_lib.c    | 38 +++++++++++++++++++++
 drivers/scsi/scsi_scan.c   | 20 +++++++++++-
 include/linux/blk-mq.h     |  6 ++--
 include/scsi/scsi_device.h |  5 +--
 include/scsi/scsi_host.h   |  3 ++
 9 files changed, 116 insertions(+), 34 deletions(-)