io_uring: Move old async data allocation helper to header
authorGabriel Krisman Bertazi <krisman@suse.de>
Mon, 16 Dec 2024 20:46:14 +0000 (15:46 -0500)
committerJens Axboe <axboe@kernel.dk>
Mon, 16 Dec 2024 20:47:48 +0000 (13:47 -0700)
commit6cd2993dcdc17cac5cf6b11034abc6014caab71b
tree6c9fd185cf59fa262ebef0502016401d46048cb0
parent8cf0c459993ee2911f4f01fba21b1987b102c887
io_uring: Move old async data allocation helper to header

There are two remaining uses of the old async data allocator that do not
rely on the alloc cache.  I don't want to make them use the new
allocator helper because that would require a if(cache) check, which
will result in dead code for the cached case (for callers passing a
cache, gcc can't prove the cache isn't NULL, and will therefore preserve
the check.  Since this is an inline function and just a few lines long,
keep a second helper to deal with cases where we don't have an async
data cache.

No functional change intended here.  This is just moving the helper
around and making it inline.

Signed-off-by: Gabriel Krisman Bertazi <krisman@suse.de>
Link: https://lore.kernel.org/r/20241216204615.759089-9-krisman@suse.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/io_uring.c
io_uring/io_uring.h
io_uring/timeout.c
io_uring/waitid.c