[PATCHSET 0/15] Get rid of ->prep_async()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

This patchset gets rid of on-stack state, that is then fixed up and
copied if we need to go async. Having to do this fixup is nasty
business, and this is the main motivation for the change.

Opcodes are converted to setting up their async context at prep time,
which means that everything is stable beyond that. No more special
io_req_prep_async() handling, and no more "oops we can't proceed,
let's now allocate memory, copy state, and be ready for a retry".
By default, opcodes are now always ready for a retry, and the issue
path can be simplified. This is most readily apparent in the read/write
handling, but can be seen on the net side too.

The diffstat reflects that, but doesn't even tell the full story. Most
of the added lines are trivial, whereas some of the removed lines are
pretty hairy.

Lightly tested - passes all tests.

 include/linux/io_uring_types.h |   2 +
 io_uring/io_uring.c            |  42 +---
 io_uring/io_uring.h            |   1 -
 io_uring/net.c                 | 539 ++++++++++++++++++-----------------------
 io_uring/net.h                 |  10 +-
 io_uring/opdef.c               |  65 +++--
 io_uring/opdef.h               |   9 +-
 io_uring/rw.c                  | 536 +++++++++++++++++++---------------------
 io_uring/rw.h                  |  27 ++-
 io_uring/uring_cmd.c           |  77 ++++--
 io_uring/uring_cmd.h           |  11 +-
 11 files changed, 613 insertions(+), 706 deletions(-)

-- 
Jens Axboe





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux