io_uring_register_iowq_max_workers(3) | liburing Manual | io_uring_register_iowq_max_workers(3) |
io_uring_register_iowq_max_workers - modify the maximum allowed async workers
#include <liburing.h>
int io_uring_register_iowq_max_workers(struct io_uring *ring, unsigned int *values);
io_uring async workers are split into two types:
By default, the amount of bounded IO workers is limited to how many SQ entries the ring was setup with, or 4 times the number of online CPUs in the system, whichever is smaller. Unbounded workers are only limited by the process task limit, as indicated by the rlimit RLIMIT_NPROC limit.
This can be modified by calling io_uring_register_iowq_max_workers with ring set to the ring in question, and values pointing to an array of two values. The first element should contain the number of desired bounded workers, and the second element should contain the number of desired unbounded workers. These are both maximum values, io_uring will not maintain a high count of idle workers, they are reaped when they are not necessary anymore.
If called with both values set to 0, the existing values are returned.
Returns 0 on success, with values containing the previous values for the settings. On error, any of the following may be returned.
March 13, 2022 | liburing-2.2 |