]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: cap SQ submit size for SQPOLL with multiple rings
authorJens Axboe <axboe@kernel.dk>
Tue, 8 Sep 2020 15:11:32 +0000 (09:11 -0600)
committerJens Axboe <axboe@kernel.dk>
Thu, 1 Oct 2020 02:32:34 +0000 (20:32 -0600)
commitda6ed45133db22926facf65f7d95c91fd6b03677
tree34005d63a26e5f6f09b9ecc581a7502f3be6e2e8
parent1b0baaa93f30385c77df75edc83449c885e5a1d9
io_uring: cap SQ submit size for SQPOLL with multiple rings

In the spirit of fairness, cap the max number of SQ entries we'll submit
for SQPOLL if we have multiple rings. If we don't do that, we could be
submitting tons of entries for one ring, while others are waiting to get
service.

The value of 8 is somewhat arbitrarily chosen as something that allows
a fair bit of batching, without using an excessive time per ring.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c