On 7/19/2022 6:52 AM, Ankit Kumar wrote: > This patchset adds test/io_uring_passthrough.c to submit uring passthrough > commands to nvme-ns character device. The uring passthrough was introduced > with 5.19 io_uring. > > To send nvme uring passthrough commands we require helpers to fetch NVMe > char device (/dev/ngXnY) specific fields such as namespace id, lba size. There wouldn't be a way to run these tests using a more general configuration, would there? I spent way too much time trying to coax my systems into pretending it has this device. > > How to run: > ./test/io_uring_passthrough.t /dev/ng0n1 > > This covers basic write/read with verify for sqthread poll, > vectored / nonvectored and fixed IO buffers, which can be easily extended > in future. > > Ankit Kumar (5): > configure: check for nvme uring command support > io_uring.h: sync sqe entry with 5.20 io_uring > nvme: add nvme opcodes, structures and helper functions > test: add io_uring passthrough test > test/io_uring_passthrough: add test case for poll IO > > configure | 20 ++ > src/include/liburing/io_uring.h | 17 +- > test/Makefile | 1 + > test/io_uring_passthrough.c | 395 ++++++++++++++++++++++++++++++++ > test/nvme.h | 168 ++++++++++++++ > 5 files changed, 599 insertions(+), 2 deletions(-) > create mode 100644 test/io_uring_passthrough.c > create mode 100644 test/nvme.h >