| commit | c23af313c08a8454b06d6ff5baf566f025180023 | [log] [tgz] |
|---|---|---|
| author | Daniel Verkamp <dverkamp@chromium.org> | Tue Apr 29 13:25:23 2025 -0700 |
| committer | crosvm LUCI <crosvm-scoped@luci-project-accounts.iam.gserviceaccount.com> | Fri May 02 11:28:27 2025 -0700 |
| tree | 825ea022db403ccc1386305c4de65115608705f2 | |
| parent | 6e7c0c118b2d9b3244fb61a89a0da14e5463f20e [diff] |
devices: virtio: simplify the common add_used() len case Most of the time, the caller of Queue::add_used() passes the DescriptorChain's writer.bytes_written() as len, or 0 if the request is known to have written 0 bytes, which is equivalent to passing bytes_written(). Change add_used() to use writer.bytes_written() automatically and rename the existing function to add_used_with_bytes_written() to make the common case simpler and the unusual case more explicit. No functional change intended. Change-Id: Ie2eb800dd7b7977bdf9199727a6794db90490686 Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/6495584 Reviewed-by: Noah Gold <nkgold@google.com> Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
crosvm is a virtual machine monitor (VMM) based on Linux’s KVM hypervisor, with a focus on simplicity, security, and speed. crosvm is intended to run Linux guests, originally as a security boundary for running native applications on the ChromeOS platform. Compared to QEMU, crosvm doesn’t emulate architectures or real hardware, instead concentrating on paravirtualized devices, such as the virtio standard.
crosvm is currently used to run Linux/Android guests on ChromeOS devices.