On 10/19/21 4:43 PM, Pavel Begunkov wrote: > Currently, IORING_REGISTER_IOWQ_MAX_WORKERS applies only to the task > that issued it, it's unexpected for users. If one task creates a ring, > limits workers and then passes it to another task the limit won't be > applied to the other task. > > Another pitfall is that a task should either create a ring or submit at > least one request for IORING_REGISTER_IOWQ_MAX_WORKERS to work at all, > furher complicating the picture. > > Change the API, save the limits and apply to all future users. Note, it > should be done first before giving away the ring or submitting new > requests otherwise the result is not guaranteed. Thanks, let's do this for 5.15. I've added: Fixes: 2e480058ddc2 ("io-wq: provide a way to limit max number of workers") -- Jens Axboe