]> www.infradead.org Git - users/dwmw2/linux.git/commit
io_uring/cmd: add per-op data to struct io_uring_cmd_data
authorJens Axboe <axboe@kernel.dk>
Fri, 3 Jan 2025 15:02:24 +0000 (15:02 +0000)
committerDavid Sterba <dsterba@suse.com>
Mon, 6 Jan 2025 12:51:06 +0000 (13:51 +0100)
commit3347fa658a1baecd61b007787d031b729cd86537
tree97623883f4550fb4c6caa92fba2817000f1f18fd
parentdadf03cfd4eaa09f1d0e8b2521de1e11d3e3bec1
io_uring/cmd: add per-op data to struct io_uring_cmd_data

In case an op handler for ->uring_cmd() needs stable storage for user
data, it can allocate io_uring_cmd_data->op_data and use it for the
duration of the request. When the request gets cleaned up, uring_cmd
will free it automatically.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: David Sterba <dsterba@suse.com>
include/linux/io_uring/cmd.h
io_uring/uring_cmd.c