From: Bart Van Assche <bvanassche@acm.org>
To: "Martin K . Petersen" <martin.petersen@oracle.com>
Cc: linux-scsi@vger.kernel.org, linux-block@vger.kernel.org,
John Garry <john.g.garry@oracle.com>,
Hannes Reinecke <hare@suse.de>,
Christoph Hellwig <hch@infradead.org>,
Damien Le Moal <dlemoal@kernel.org>,
Bart Van Assche <bvanassche@acm.org>
Subject: [PATCH v4 0/6] Increase SCSI IOPS
Date: Tue, 16 Dec 2025 14:30:44 -0800 [thread overview]
Message-ID: <20251216223052.350366-1-bvanassche@acm.org> (raw)
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(-)
next reply other threads:[~2025-12-16 22:31 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-16 22:30 Bart Van Assche [this message]
2025-12-16 22:30 ` [PATCH v4 1/6] block: Rename busy_tag_iter_fn into blk_mq_rq_iter_fn Bart Van Assche
2025-12-16 22:30 ` [PATCH v4 2/6] block: Introduce __blk_mq_tagset_iter() Bart Van Assche
2025-12-16 22:30 ` [PATCH v4 3/6] block: Introduce blk_mq_tagset_iter() Bart Van Assche
2025-12-16 22:30 ` [PATCH v4 4/6] ata: libata: Set .needs_budget_token Bart Van Assche
2025-12-16 22:30 ` [PATCH v4 5/6] scsi: core: Generalize scsi_device_busy() Bart Van Assche
2025-12-16 22:30 ` [PATCH v4 6/6] scsi: core: Improve IOPS in case of host-wide tags Bart Van Assche
2025-12-17 3:24 ` Damien Le Moal
2025-12-19 17:35 ` Bart Van Assche
2025-12-19 23:06 ` Damien Le Moal
2025-12-20 0:05 ` Bart Van Assche
2025-12-20 0:13 ` Damien Le Moal
2025-12-20 0:28 ` Bart Van Assche
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=20251216223052.350366-1-bvanassche@acm.org \
--to=bvanassche@acm.org \
--cc=dlemoal@kernel.org \
--cc=hare@suse.de \
--cc=hch@infradead.org \
--cc=john.g.garry@oracle.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox