cloud-hypervisor/fuzz/fuzz_targets
Yuanchu Xie 5f18ac3bc0 devices: Add pvmemcontrol device
Pvmemcontrol provides a way for the guest to control its physical memory
properties, and enables optimizations and security features. For
example, the guest can provide information to the host where parts of a
hugepage may be unbacked, or sensitive data may not be swapped out, etc.

Pvmemcontrol allows guests to manipulate its gPTE entries in the SLAT,
and also some other properties of the memory map the back's host memory.
This is achieved by using the KVM_CAP_SYNC_MMU capability. When this
capability is available, the changes in the backing of the memory region
on the host are automatically reflected into the guest. For example, an
mmap() or madvise() that affects the region will be made visible
immediately.

There are two components of the implementation: the guest Linux driver
and Virtual Machine Monitor (VMM) device. A guest-allocated shared
buffer is negotiated per-cpu through a few PCI MMIO registers, the VMM
device assigns a unique command for each per-cpu buffer. The guest
writes its pvmemcontrol request in the per-cpu buffer, then writes the
corresponding command into the command register, calling into the VMM
device to perform the pvmemcontrol request.

The synchronous per-cpu shared buffer approach avoids the kick and busy
waiting that the guest would have to do with virtio virtqueue transport.

The Cloud Hypervisor component can be enabled with --pvmemcontrol.

Co-developed-by: Stanko Novakovic <stanko@google.com>
Co-developed-by: Pasha Tatashin <tatashin@google.com>
Signed-off-by: Yuanchu Xie <yuanchu@google.com>
2024-08-05 22:41:56 +00:00
..
balloon.rs misc: Fix various spelling errors using typos 2023-09-09 10:46:21 +01:00
block.rs block: Set an option to pin virtio block threads to host cpus 2024-02-13 09:05:57 +00:00
cmos.rs fuzz: fix unused import warnings 2024-01-08 17:39:05 +00:00
console.rs fuzz: Add fuzzer for virtio-console 2022-11-03 09:10:41 -07:00
http_api.rs devices: Add pvmemcontrol device 2024-08-05 22:41:56 +00:00
iommu.rs misc: Fix various spelling errors using typos 2023-09-09 10:46:21 +01:00
linux_loader_cmdline.rs vmm: Add IGVM to the config/commandline 2023-12-08 09:22:42 -08:00
linux_loader.rs fuzz: Add fuzzer for 'linux loader' 2022-12-12 13:50:28 +00:00
mem.rs misc: Fix various spelling errors using typos 2023-09-09 10:46:21 +01:00
net.rs vmm: add configuration for network offloading features 2023-01-12 09:05:45 +00:00
pmem.rs vmm: virtio-devices: Restore every VirtioDevice upon creation 2022-10-24 14:17:08 +02:00
qcow.rs build: add REUSE Compliance Check 2024-04-19 17:35:45 +00:00
rng.rs misc: Fix various spelling errors using typos 2023-09-09 10:46:21 +01:00
serial.rs vm-device: support batch update interrupt source group GSI 2023-08-03 15:58:36 +01:00
vhdx.rs block: merge qcow, vhdx and block_util into block crate 2023-07-19 13:52:43 +01:00
watchdog.rs vmm: virtio-devices: Restore every VirtioDevice upon creation 2022-10-24 14:17:08 +02:00