Skip to content

Add support for uring passthrough commands

Ankit Kumar fio 3 versions – Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest9 patches 5 repliesApplied
  2. v28 patches 17 repliesSuperseded
  3. v17 patches 4 repliesSuperseded

Changes in v3 from the cover letter

- I/O command formation cleanup and example config file changes as per the review comments from Vincent and Jens.
- Addressed review comments from Kanchan with regards to io_uring_cmd options.
- test case 1 skip only for character device fixed, as reported by Shin'ichiro.

Patches in v3 Applied

#Subject and filesSizeRepliesApplied
1/9io_uring.h: add IORING_SETUP_SQE128 and IORING_SETUP_CQE32os/linux/io_uring.h+35 -10 replies
2/9configure: check nvme uring command supportconfigure+21 -00 replies
3/9init: return error incase an invalid value is passed as optioninit.c+9 -00 replies
4/9nvme: add nvme opcodes, structures and helper functionsMakefile engines/nvme.c engines/nvme.h+241 -20 replies
5/9engines/io_uring: add new I/O engine for uring passthrough supportengines/io_uring.c file.h os/linux/io_uring.h+328 -111 reply
6/9docs: document options for io_uring_cmd I/O engineHOWTO.rst fio.1+59 -150 replies
7/9zbd: Check for direct flag only if its block devicet/zbd/test-zbd-support zbd.c+12 -33 replies
8/9engines/io_uring: Enable zone device support for io_uring_cmd I/O engineengines/io_uring.c engines/nvme.c engines/nvme.h+353 -10 replies
9/9examples: add 2 example job file for io_uring_cmd engineexamples/uring-cmd-ng.fio examples/uring-cmd-zoned.fio+56 -00 replies

Reviews trailers per patch

1 of 9 patches has a Reviewed-by or Acked-by.

PatchAnuj GuptaAnkit KumarVincent FuShin'ichiro Kawasaki
1/9
2/9
3/9
4/9Co-authored-by
5/9Co-authored-by
6/9
7/9T-b R-b
8/9T-b
9/9Co-authored-by

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 4 reviewers.

Read the v3 thread

Cover letter [PATCH v3 0/9] Add support for uring passthrough commands

This patchset adds a new I/O engine (io_uring_cmd), which enables support for io_uring passthrough commands. This work is based on upcoming 5.19 kernel.
https://github.com/torvalds/linux/commits/master

This engine will use most of the existing helpers from io_uring. The I/O preparation, completion, file open, file close and post init paths are going to differ and hence io_uring_cmd will have its own helpers for them.

The current uring passthrough support is present only with nvme-ns character device (/dev/ngXnY). This includes both conventional as well as ZNS devices. Add a new io_uring_cmd engine specific option:
* cmd_type

cmd_type provides the flexibility to support different types of passthrough commands in future.

To enable support for nvme passthrough commands, we are adding nvme.c and nvme.h files. These will have the necessary NVMe specification data structures, opcodes and helper functions for sending admin and I/O passthrough commands.

O_DIRECT flag support is not present with nvme-ns charatcer devices, hence zbd will check for them only if fio filetype is a block device. The t/zbd/test-zbd-support test case #1 is now appropriately updated to run only for block device.

Changes from v2 to v3:
- I/O command formation cleanup and example config file changes as per the review comments from Vincent and Jens.
- Addressed review comments from Kanchan with regards to io_uring_cmd options.
- test case 1 skip only for character device fixed, as reported by Shin'ichiro.

Ankit Kumar (5):
configure: check nvme uring command support
nvme: add nvme opcodes, structures and helper functions
docs: document options for io_uring_cmd I/O engine
zbd: Check for direct flag only if its block device engines/io_uring: Enable zone device support for io_uring_cmd I/O
engine

Anuj Gupta (4):
io_uring.h: add IORING_SETUP_SQE128 and IORING_SETUP_CQE32
init: return error incase an invalid value is passed as option engines/io_uring: add new I/O engine for uring passthrough support
examples: add 2 example job file for io_uring_cmd engine

 HOWTO.rst                    |  41 +++-
 Makefile                     |   4 +-
 configure                    |  21 +++
 engines/io_uring.c           | 350 ++++++++++++++++++++++++++++++++++-
 engines/nvme.c               | 345 ++++++++++++++++++++++++++++++++++
 engines/nvme.h               | 214 +++++++++++++++++++++
 examples/uring-cmd-ng.fio    |  25 +++
 examples/uring-cmd-zoned.fio |  31 ++++
 file.h                       |  12 +-
 fio.1                        |  33 +++-
 init.c                       |   9 +
 os/linux/io_uring.h          |  45 ++++-
 t/zbd/test-zbd-support       |  11 +-
 zbd.c                        |   4 +-
 14 files changed, 1113 insertions(+), 32 deletions(-)
 create mode 100644 engines/nvme.c
 create mode 100644 engines/nvme.h
 create mode 100644 examples/uring-cmd-ng.fio
 create mode 100644 examples/uring-cmd-zoned.fio

base-commit: e1aeff3ac96a51128b0493377f405e38bdc83500

Signature · 1 line
2.17.1