public inbox for io-uring@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC 0/2] mock files for advanced io_uring testing
@ 2025-05-22 15:10 Pavel Begunkov
  2025-05-22 15:10 ` [PATCH 1/2] io_uring/mock: add basic infra for test mock files Pavel Begunkov
  2025-05-22 15:10 ` [PATCH 2/2] io_uring/mock: add cmd using vectored regbufs Pavel Begunkov
  0 siblings, 2 replies; 3+ messages in thread
From: Pavel Begunkov @ 2025-05-22 15:10 UTC (permalink / raw)
  To: io-uring; +Cc: asml.silence, chase xd

There are core io_uring features that are hard to test without having
some specific file types. That includes various read/write and polling
edge cases, but the problem got even more distinct with the introduction
of commands and io_uring adding new features for them.

For improving testing we need a finer control over file behaviour. Add
special / mock files we can create and configure. First, the file is
implementing a set of io_uring commands that uses various cmd io_uring
features.
Chase also suggestedd adding read/write/poll file operations and varying
their characteristics: pollability, nowait support, whether the IO is
async, etc., which will be added in the future.

Liburing tests:

https://github.com/isilence/liburing/tree/mock-file-tests
git https://github.com/isilence/liburing.git mock-file-tests

Pavel Begunkov (2):
  io_uring/mock: add basic infra for test mock files
  io_uring/mock: add cmd using vectored regbufs

 init/Kconfig         |  11 +++
 io_uring/Makefile    |   1 +
 io_uring/mock_file.c | 207 +++++++++++++++++++++++++++++++++++++++++++
 io_uring/mock_file.h |  34 +++++++
 4 files changed, 253 insertions(+)
 create mode 100644 io_uring/mock_file.c
 create mode 100644 io_uring/mock_file.h

-- 
2.49.0


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

end of thread, other threads:[~2025-05-22 15:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-22 15:10 [RFC 0/2] mock files for advanced io_uring testing Pavel Begunkov
2025-05-22 15:10 ` [PATCH 1/2] io_uring/mock: add basic infra for test mock files Pavel Begunkov
2025-05-22 15:10 ` [PATCH 2/2] io_uring/mock: add cmd using vectored regbufs Pavel Begunkov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox