projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
414d0f4
)
io_uring/poll: shrink alloc cache size to 32
author
Jens Axboe
<axboe@kernel.dk>
Thu, 21 Mar 2024 13:53:07 +0000
(07:53 -0600)
committer
Jens Axboe
<axboe@kernel.dk>
Mon, 15 Apr 2024 14:10:25 +0000
(08:10 -0600)
This should be plenty, rather than the default of 128, and matches what
we have on the rsrc and futex side as well.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/io_uring.c
patch
|
blob
|
history
io_uring/poll.h
patch
|
blob
|
history
diff --git
a/io_uring/io_uring.c
b/io_uring/io_uring.c
index 1d453eb8e49f43deb34058ea0abd9670abcc6205..8e53b93eeb180e9b22a04ef33a57c1cbde5737d8 100644
(file)
--- a/
io_uring/io_uring.c
+++ b/
io_uring/io_uring.c
@@
-308,7
+308,7
@@
static __cold struct io_ring_ctx *io_ring_ctx_alloc(struct io_uring_params *p)
INIT_HLIST_HEAD(&ctx->io_buf_list);
ret = io_alloc_cache_init(&ctx->rsrc_node_cache, IO_NODE_ALLOC_CACHE_MAX,
sizeof(struct io_rsrc_node));
- ret |= io_alloc_cache_init(&ctx->apoll_cache, IO_ALLOC_CACHE_MAX,
+ ret |= io_alloc_cache_init(&ctx->apoll_cache, IO_
POLL_
ALLOC_CACHE_MAX,
sizeof(struct async_poll));
ret |= io_alloc_cache_init(&ctx->netmsg_cache, IO_ALLOC_CACHE_MAX,
sizeof(struct io_async_msghdr));
diff --git
a/io_uring/poll.h
b/io_uring/poll.h
index 5c240f11069a41bf052d038adf4f83dcfc31414a..b0e3745f5a29b9ab0f8e1901af9abe3906c4e956 100644
(file)
--- a/
io_uring/poll.h
+++ b/
io_uring/poll.h
@@
-1,5
+1,7
@@
// SPDX-License-Identifier: GPL-2.0
+#define IO_POLL_ALLOC_CACHE_MAX 32
+
enum {
IO_APOLL_OK,
IO_APOLL_ABORTED,