Host backends supports guest-memfd now by detecting whether it's a confidential VM. There's no way to choose it yet from the memory level to use it fully shared. If we use guest-memfd, it so far always implies we need two layers of memory backends, while the guest-memfd only provides the private set of pages. This patch introduces a way so that QEMU can consume guest memfd as the only source of memory to back the object (aka, fully shared). To use the fully shared guest-memfd, one can add a memfd object with: -object memory-backend-memfd,x-guest-memfd=on,share=on Note that share=on is required with fully shared guest_memfd. Since guest-memfd is not yet a drop-in replacement for memfd (e.g. lack of hugepage support), the option is tagged as experimental for now so that it can be made available for early enablement/testing without causing any surprises for other users. PS: there's a trivial touch-up on fd<0 check, because the stub to create guest-memfd may return negative but not -1. Reviewed-by: Xiaoyao Li <xiaoyao.li@intel.com> Reviewed-by: Fabiano Rosas <farosas@suse.de> Reviewed-by: David Hildenbrand <david@kernel.org> Co-developed-by: Michael Roth <michael.roth@amd.com> Signed-off-by: Michael Roth <michael.roth@amd.com> Acked-by: Markus Armbruster <armbru@redhat.com> Link: https://lore.kernel.org/r/20260929235109.1398509-11-michael.roth@amd.com Signed-off-by: Peter Xu <peterx@redhat.com>
48 lines
764 B
ReStructuredText
48 lines
764 B
ReStructuredText
.. _System Emulation:
|
|
|
|
----------------
|
|
System Emulation
|
|
----------------
|
|
|
|
This section of the manual is the overall guide for users using QEMU
|
|
for full system emulation (as opposed to user-mode emulation).
|
|
This includes working with hypervisors such as KVM, Xen
|
|
or Hypervisor.Framework.
|
|
|
|
.. toctree::
|
|
:maxdepth: 3
|
|
|
|
introduction
|
|
invocation
|
|
device-emulation
|
|
keys
|
|
mux-chardev
|
|
monitor
|
|
images
|
|
virtio-net-failover
|
|
linuxboot
|
|
generic-loader
|
|
guest-loader
|
|
barrier
|
|
vnc-security
|
|
tls
|
|
secrets
|
|
authz
|
|
gdb
|
|
replay
|
|
managed-startup
|
|
bootindex
|
|
cpu-hotplug
|
|
pr-manager
|
|
targets
|
|
security
|
|
multi-process
|
|
confidential-guest-support
|
|
igvm
|
|
nitro
|
|
whpx
|
|
vm-templating
|
|
sriov
|
|
qemu-colo
|
|
guest-memfd
|