io_uring: Move from hlist to io_wq_work_node
authorBreno Leitao <leitao@debian.org>
Thu, 23 Feb 2023 16:43:52 +0000 (08:43 -0800)
committerJens Axboe <axboe@kernel.dk>
Mon, 3 Apr 2023 13:16:12 +0000 (07:16 -0600)
commitefba1a9e653e107577a48157b5424878c46f2285
tree2a70cd4738906ed7ddf0187cfdc5e3b422cdb7c4
parentda64d6db3bd304d44d7ac1eb7f319a1cc7efd611
io_uring: Move from hlist to io_wq_work_node

Having cache entries linked using the hlist format brings no benefit, and
also requires an unnecessary extra pointer address per cache entry.

Use the internal io_wq_work_node single-linked list for the internal
alloc caches (async_msghdr and async_poll)

This is required to be able to use KASAN on cache entries, since we do
not need to touch unused (and poisoned) cache entries when adding more
entries to the list.

Suggested-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Breno Leitao <leitao@debian.org>
Link: https://lore.kernel.org/r/20230223164353.2839177-2-leitao@debian.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
include/linux/io_uring_types.h
io_uring/alloc_cache.h