Commit 71b547c
io_uring: improve submit_state.ios_left accounting
state->ios_left isn't decremented for requests that don't need a file,
so it might be larger than number of SQEs left. That in some
circumstances makes us to grab more files that is needed so imposing
extra put.
Deaccount one ios_left for each request.
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>1 parent 8371adf commit 71b547c
1 file changed
Lines changed: 5 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2581 | 2581 | | |
2582 | 2582 | | |
2583 | 2583 | | |
2584 | | - | |
2585 | 2584 | | |
2586 | 2585 | | |
2587 | 2586 | | |
| |||
2591 | 2590 | | |
2592 | 2591 | | |
2593 | 2592 | | |
2594 | | - | |
2595 | | - | |
| 2593 | + | |
2596 | 2594 | | |
2597 | 2595 | | |
2598 | 2596 | | |
| |||
6386 | 6384 | | |
6387 | 6385 | | |
6388 | 6386 | | |
6389 | | - | |
| 6387 | + | |
6390 | 6388 | | |
6391 | 6389 | | |
6392 | 6390 | | |
| |||
6432 | 6430 | | |
6433 | 6431 | | |
6434 | 6432 | | |
6435 | | - | |
| 6433 | + | |
| 6434 | + | |
| 6435 | + | |
6436 | 6436 | | |
6437 | 6437 | | |
6438 | 6438 | | |
| |||
0 commit comments