]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: track io length in async_list based on bytes
authorZhengyuan Liu <liuzhengyuan@kylinos.cn>
Mon, 22 Jul 2019 02:23:27 +0000 (10:23 +0800)
committerJens Axboe <axboe@kernel.dk>
Mon, 22 Jul 2019 03:46:55 +0000 (21:46 -0600)
commitca54e535238ab6e6d81c7ab071c68c645593f02b
tree116cab71c667dff15dedcb4c0439c964ddcdea6a
parent1a4f3a239ce4f1ac328a621f2cb3fe492ad556b8
io_uring: track io length in async_list based on bytes

We are using PAGE_SIZE as the unit to determine if the total len in
async_list has exceeded max_pages, it's not fair for smaller io sizes.
For example, if we are doing 1k-size io streams, we will never exceed
max_pages since len >>= PAGE_SHIFT always gets zero. So use original
bytes to make it more accurate.

Signed-off-by: Zhengyuan Liu <liuzhengyuan@kylinos.cn>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c