summary refs log tree commit diff
path: root/devices
diff options
context:
space:
mode:
authorDylan Reid <dgreid@chromium.org>2020-04-08 00:47:45 +0000
committerCommit Bot <commit-bot@chromium.org>2020-04-10 00:13:08 +0000
commit03164ca9d8baca09f4d8afedc25d57ddeb2361e6 (patch)
tree123b38c2a6c5955af3623fea9d4b015683a3bc4f /devices
parent23a2b7b8a22a4ca589a58c804596eddfbceab4e3 (diff)
downloadcrosvm-03164ca9d8baca09f4d8afedc25d57ddeb2361e6.tar
crosvm-03164ca9d8baca09f4d8afedc25d57ddeb2361e6.tar.gz
crosvm-03164ca9d8baca09f4d8afedc25d57ddeb2361e6.tar.bz2
crosvm-03164ca9d8baca09f4d8afedc25d57ddeb2361e6.tar.lz
crosvm-03164ca9d8baca09f4d8afedc25d57ddeb2361e6.tar.xz
crosvm-03164ca9d8baca09f4d8afedc25d57ddeb2361e6.tar.zst
crosvm-03164ca9d8baca09f4d8afedc25d57ddeb2361e6.zip
io_uring: allocate iovecs based on returned count from the kernel
The kernel is allowed to not only limit the number of requested entries,
but also provide more than is requested. If a non-power-of-2 is
requested, it will be rounded up to the next power of 2.

Ensure that there are enough iovecs by allocating them based on the
number returned from io_uring_setup instead of the number of entries
requested.

TEST=cargo test read_parallel

Change-Id: If92e0a31858d1af53b99af8415002a4f26b48230
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/2140915
Reviewed-by: Chirantan Ekbote <chirantan@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Tested-by: Dylan Reid <dgreid@chromium.org>
Commit-Queue: Dylan Reid <dgreid@chromium.org>
Diffstat (limited to 'devices')
0 files changed, 0 insertions, 0 deletions