| commit | ce13dca5bfa199f43289e54692534cf5637f4dd8 | [log] [tgz] |
|---|---|---|
| author | Junnan Wu <junnan01.wu@samsung.com> | Fri Apr 11 16:32:03 2025 +0800 |
| committer | crosvm LUCI <crosvm-scoped@luci-project-accounts.iam.gserviceaccount.com> | Thu May 22 11:05:32 2025 -0700 |
| tree | 9c6c595e3458087b911612369cf7b4e066997ab2 | |
| parent | d9e7d2bf11180011c8b7f888ff9f0c196c56c7ed [diff] |
devices: virtio-net: implement MRG_RXBUF feature Add a new process_mrg_rx flow to enable MRG_RXBUF feature. In order to support this feature, following steps are necessary. 1. Copy socket buffer to crosvm's pending buffer in advance, so that we can know how much space this buffer required. 2. Queue need to support look around available ring to try to pop several descriptors whose total length bigger than required. 3. Split the pending buffer in crosvm progress and write to each descriptor. 4. Queue need to support add all descriptors into used one time to avoid unexpected error. By the way, because we read socket packet to pending buffer from tap in advance, if this packet has not sent to driver due to vq is exhausted, we should keep it and use it firstly in next handle process instead of re-reading from tap. Furthermore, due to extra copy, the performance for rx big frame TCP will descresed little, but rx UDP performance will increase significantly. BUG=b/413511264 TEST=presubmit Change-Id: Iaca233c714471d1ad52d29bb3eee75817ad3959a Signed-off-by: Junnan Wu <junnan01.wu@samsung.com> Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/6490829 Reviewed-by: David Stevens <stevensd@chromium.org> Commit-Queue: Daniel Verkamp <dverkamp@chromium.org> Reviewed-by: 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.