io_uring/net: add io_req_msg_cleanup() helper
authorJens Axboe <axboe@kernel.dk>
Wed, 6 Mar 2024 14:57:57 +0000 (07:57 -0700)
committerJens Axboe <axboe@kernel.dk>
Fri, 8 Mar 2024 14:57:27 +0000 (07:57 -0700)
commitd9b441889c3595aa18f89ee42c6d22bb62234343
treea2a338ac36d1d4fcd3129ebe54706051e2bee6fd
parentfb6328bc2ab58dcf2998bd173f1ef0f3eb7be19a
io_uring/net: add io_req_msg_cleanup() helper

For the fast inline path, we manually recycle the io_async_msghdr and
free the iovec, and then clear the REQ_F_NEED_CLEANUP flag to avoid
that needing doing in the slower path. We already do that in 2 spots, and
in preparation for adding more, add a helper and use it.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/net.c