All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/3] nvme: introduce the service-time iopolicy
@ 2026-10-19  7:56 Guixin Liu
  2026-10-19  7:56 ` [PATCH v2 1/3] nvme-multipath: implement " Guixin Liu
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Guixin Liu @ 2026-10-19  7:56 UTC (permalink / raw)
  To: Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg,
	Nilay Shroff, Daniel Wagner, Hannes Reinecke
  Cc: linux-nvme

The queue-depth iopolicy counts requests, so a 128K I/O weighs the same
as a 4K one, and it cannot express that one path is simply faster than
another. This series adds a service-time iopolicy for NVMe native
multipath, adapted from dm-ps-service-time: it picks the path with the
lowest estimated service time, in_flight_bytes / relative_throughput,
so balancing follows actual bytes in flight and per-path throughput
weights.

Weights live in a per-path relative_throughput sysfs attribute (0-100,
default 1, 0 makes the path a standby). Patch 3 documents the new
attributes in the stable sysfs ABI; patch 1 carries the benchmark data
in its commit log.

Changes since v1:

- Rebased onto v7.3. iopolicy parsing was refactored into
  nvme_iopolicy_parse() in the meantime, which picks up the new policy
  for both the module parameter and the per-subsystem attribute.

- The comparison helper now returns a sign-safe -1/0/1. The in-flight
  sizes are 64-bit, and returning the plain difference truncated to
  int can report the wrong sign once loads grow. Selection is
  unchanged in the ranges the benchmarks cover.

- relative_throughput now defaults to 1 in nvme_mpath_init_ctrl().
  v1 re-applied the default on every controller reset in
  nvme_mpath_init_identify(), which silently re-enabled standby paths
  after routine reconnects.

- Dropped the unused "incoming" argument of the comparison helper.

- Added ABI documentation for in_flight_bytes and relative_throughput.

On the adaptive I/O policy dependency Hannes raised during v1: that
series has become the latency I/O policy and is still under
revision, so this version stays on plain master. The two are
complementary: the latency policy infers path speed from observed
completions, service-time takes configured weights and byte counts.
I can rebase once the latency series lands.

Guixin Liu (3):
  nvme-multipath: implement service-time iopolicy
  nvme-multipath: document service-time iopolicy
  nvme: document the service-time iopolicy sysfs attributes

 Documentation/ABI/stable/sysfs-nvme          |  22 +++
 Documentation/admin-guide/nvme-multipath.rst |  31 +++-
 drivers/nvme/host/multipath.c                | 162 ++++++++++++++++++-
 drivers/nvme/host/nvme.h                     |   6 +
 drivers/nvme/host/sysfs.c                    |   5 +-
 5 files changed, 221 insertions(+), 5 deletions(-)

v1 of this series:
https://lore.kernel.org/r/20260617114602.2224074-1-kanie@linux.alibaba.com

latency I/O policy v7:
https://lore.kernel.org/r/20260809100825.2014133-1-nilay@linux.ibm.com
-- 
2.43.7


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

end of thread, other threads:[~2026-10-19 14:52 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-19  7:56 [PATCH v2 0/3] nvme: introduce the service-time iopolicy Guixin Liu
2026-10-19  7:56 ` [PATCH v2 1/3] nvme-multipath: implement " Guixin Liu
2026-10-19  8:14   ` sashiko-bot
2026-10-19  7:56 ` [PATCH v2 2/3] nvme-multipath: document " Guixin Liu
2026-10-19  7:56 ` [PATCH v2 3/3] nvme: document the service-time iopolicy sysfs attributes Guixin Liu
2026-10-19  8:13   ` sashiko-bot
2026-10-19 11:13     ` Guixin Liu
2026-10-19 12:13       ` Martin George
2026-10-19 12:43         ` Laurence Oberman
2026-10-19 13:21           ` Guixin Liu
2026-10-19 14:46           ` Martin George
2026-10-19 14:51             ` Laurence Oberman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.