io_uring: add infrastructure around io_uring_cmd_sqe
authorJens Axboe <axboe@kernel.dk>
Thu, 16 Dec 2021 12:46:17 +0000 (18:16 +0530)
committerJens Axboe <axboe@kernel.dk>
Fri, 17 Dec 2021 16:52:30 +0000 (09:52 -0700)
commit278755c32b7fd62a8e82a1229c819ed2fcd85730
tree7b85c61ab359dda0501b57b03b71d5497e65e7fb
parent5351d4d8d530f953ed5bfdfeb54ac97b6245a99e
io_uring: add infrastructure around io_uring_cmd_sqe

Define an io_uring_cmd_sqe struct that passthrough commands can use,
and define an array that has offset information for the two members
that we care about (user_data and personality). Then we can init the
two command types in basically the same way, just reading the user_data
and personality at the defined offsets for the command type.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c
include/uapi/linux/io_uring.h