linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v6 0/3] Enabling ATA Command Priorities
@ 2016-10-17 18:27 Adam Manzanares
  2016-10-17 18:27 ` [PATCH v6 1/3] block: Add iocontext priority to request Adam Manzanares
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Adam Manzanares @ 2016-10-17 18:27 UTC (permalink / raw)
  To: axboe, tj, dan.j.williams, hare, martin.petersen, mchristi,
	toshi.kani, ming.lei, sathya.prakash, chaitra.basappa,
	suganath-prabu.subramani
  Cc: linux-block, linux-ide, linux-kernel, MPT-FusionLinux.pdl,
	linux-scsi, Adam Manzanares

This patch builds ATA commands with high priority if the iocontext of a process
is set to real time. The goal of the patch is to improve tail latencies of 
workloads that use higher queue depths. This requires setting the iocontext 
ioprio on the request when it is initialized

This patch has been tested with an Ultrastar HE8 HDD and cuts the 
the p99.99 tail latency of foreground IO from 2s down to 72ms when
using the deadline scheduler. This patch works independently of the
scheduler so it can be used with all of the currently available 
request based schedulers. 

Foreground IO, for the previously described results, is an async fio job 
submitting 4K read requests at a QD of 1 to the HDD. The foreground IO is set 
with the iopriority class of real time. The background workload is another fio
job submitting read requests at a QD of 32 to the same HDD with default 
iopriority.

This feature is enabled for ATA devices by setting the ata ncq_prio_on device 
attribute to 1. An ATA device is also checked to see if the device supports per
command priority.

v6:
 - Removed fusion mpt sas prio related code deletion
 - Renamed ata device attribute that enables priority cmds to the device

v5:
 - Updated block patch commit message to indicate the why and not the how
v4:
 - Added blk_rq_set_prio function to associate request prio with ioc prio
 - In init_request_from_bio use bio_prio if it is valid
 - Added ata enable_prio dev attribute to sysfs to enable prioritized commands

v3:
 - Removed null dereference issue in blk-core
 - Renamed queue sysfs entries for clarity
 - Added documentation for sysfs queue entry

v2:
 - Add queue flag to set iopriority going to the request
 - If queue flag set, send iopriority class to ata_build_rw_tf
 - Remove redundant code in ata_ncq_prio_enabled function.


Adam Manzanares (3):
  block: Add iocontext priority to request
  ata: Enabling ATA Command Priorities
  ata: ATA Command Priority Disabled By Default

 block/blk-core.c          |  4 ++-
 drivers/ata/libahci.c     |  1 +
 drivers/ata/libata-core.c | 35 +++++++++++++++++++++-
 drivers/ata/libata-scsi.c | 74 ++++++++++++++++++++++++++++++++++++++++++++++-
 drivers/ata/libata.h      |  2 +-
 include/linux/ata.h       |  6 ++++
 include/linux/blkdev.h    | 14 +++++++++
 include/linux/libata.h    | 25 ++++++++++++++++
 8 files changed, 157 insertions(+), 4 deletions(-)

-- 
2.1.4

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2016-10-19 20:02 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-17 18:27 [PATCH v6 0/3] Enabling ATA Command Priorities Adam Manzanares
2016-10-17 18:27 ` [PATCH v6 1/3] block: Add iocontext priority to request Adam Manzanares
2016-10-19 18:05   ` Tejun Heo
2016-10-19 18:08     ` Jens Axboe
2016-10-17 18:27 ` [PATCH v6 2/3] ata: Enabling ATA Command Priorities Adam Manzanares
2016-10-19 18:37   ` Tejun Heo
2016-10-17 18:27 ` [PATCH v6 3/3] ata: ATA Command Priority Disabled By Default Adam Manzanares
2016-10-19 18:05   ` Tejun Heo
2016-10-19 18:09     ` Adam Manzanares
2016-10-19 18:38   ` Tejun Heo
2016-10-19 20:02     ` Adam Manzanares
2016-10-19 18:38 ` [PATCH v6 0/3] Enabling ATA Command Priorities Tejun Heo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).