[PATCH REBASE 0/7] qemu: Use memory-backend-* for regular guest memory

This is a rebased version of patches posted in May: https://www.redhat.com/archives/libvir-list/2020-May/msg01114.html Fortunately, the QEMU part is now merged (v5.1.0-3-gc556600598) and thus these can get proper review. Michal Prívozník (7): qemuBuildMemoryBackendProps: Move @prealloc setting to backend agnostic part qemuBuildMemoryBackendProps: Respect //memoryBacking/allocation/@mode=immediate qemuBuildMemoryBackendProps: Prealloc mem for memfd backend qemuBuildMemoryBackendProps: Fix const correctness qemu: Introduce QEMU_CAPS_MACHINE_MEMORY_BACKEND qemu: Track default-ram-id machine attribute qemu: Use memory-backend-* for regular guest memory src/qemu/qemu_capabilities.c | 42 +++- src/qemu/qemu_capabilities.h | 6 + src/qemu/qemu_capspriv.h | 3 +- src/qemu/qemu_command.c | 98 +++++++-- src/qemu/qemu_command.h | 4 +- src/qemu/qemu_monitor.c | 1 + src/qemu/qemu_monitor.h | 1 + src/qemu/qemu_monitor_json.c | 11 + .../caps_5.2.0.x86_64.xml | 197 +++++++++--------- .../blkdeviotune-group-num.x86_64-latest.args | 3 +- ...blkdeviotune-max-length.x86_64-latest.args | 3 +- .../blkdeviotune-max.x86_64-latest.args | 3 +- .../channel-unix-guestfwd.x86_64-latest.args | 3 +- .../console-virtio-unix.x86_64-latest.args | 3 +- .../controller-virtio-scsi.x86_64-latest.args | 3 +- ...-Icelake-Server-pconfig.x86_64-latest.args | 3 +- .../cpu-translation.x86_64-latest.args | 3 +- .../cputune-cpuset-big-id.x86_64-latest.args | 3 +- .../disk-aio-io_uring.x86_64-latest.args | 3 +- .../disk-aio.x86_64-latest.args | 3 +- ...-backing-chains-noindex.x86_64-latest.args | 3 +- .../disk-cache.x86_64-latest.args | 4 +- .../disk-cdrom-bus-other.x86_64-latest.args | 3 +- ...m-empty-network-invalid.x86_64-latest.args | 3 +- .../disk-cdrom-network.x86_64-latest.args | 3 +- .../disk-cdrom-tray.x86_64-latest.args | 3 +- .../disk-cdrom.x86_64-latest.args | 3 +- .../disk-copy_on_read.x86_64-latest.args | 3 +- .../disk-detect-zeroes.x86_64-latest.args | 3 +- .../disk-discard.x86_64-latest.args | 3 +- .../disk-error-policy.x86_64-latest.args | 3 +- .../disk-floppy-q35-2_11.x86_64-latest.args | 4 +- .../disk-floppy-q35-2_9.x86_64-latest.args | 4 +- .../disk-floppy.x86_64-latest.args | 3 +- .../disk-network-gluster.x86_64-latest.args | 3 +- .../disk-network-http.x86_64-latest.args | 3 +- .../disk-network-iscsi.x86_64-latest.args | 3 +- .../disk-network-nbd.x86_64-latest.args | 3 +- .../disk-network-rbd.x86_64-latest.args | 3 +- .../disk-network-sheepdog.x86_64-latest.args | 3 +- ...isk-network-source-auth.x86_64-latest.args | 3 +- ...isk-network-tlsx509-nbd.x86_64-latest.args | 3 +- .../disk-nvme.x86_64-latest.args | 3 +- .../disk-readonly-disk.x86_64-latest.args | 3 +- .../disk-scsi-device-auto.x86_64-latest.args | 3 +- .../disk-scsi.x86_64-latest.args | 3 +- .../disk-shared.x86_64-latest.args | 3 +- .../disk-slices.x86_64-latest.args | 3 +- ...irtio-scsi-reservations.x86_64-latest.args | 3 +- .../eoi-disabled.x86_64-latest.args | 3 +- .../eoi-enabled.x86_64-latest.args | 3 +- .../floppy-drive-fat.x86_64-latest.args | 3 +- .../qemuxml2argvdata/fs9p.x86_64-latest.args | 3 +- .../genid-auto.x86_64-latest.args | 3 +- .../qemuxml2argvdata/genid.x86_64-latest.args | 3 +- ...egl-headless-rendernode.x86_64-latest.args | 3 +- .../graphics-egl-headless.x86_64-latest.args | 3 +- ...pice-gl-auto-rendernode.x86_64-latest.args | 3 +- ...graphics-vnc-tls-secret.x86_64-latest.args | 3 +- .../graphics-vnc-tls.x86_64-latest.args | 3 +- ...tdev-mdev-display-ramfb.x86_64-latest.args | 3 +- ...play-spice-egl-headless.x86_64-latest.args | 3 +- ...ev-display-spice-opengl.x86_64-latest.args | 3 +- ...isplay-vnc-egl-headless.x86_64-latest.args | 3 +- ...ostdev-mdev-display-vnc.x86_64-latest.args | 3 +- .../hostdev-scsi-lsi.x86_64-latest.args | 3 +- ...ostdev-scsi-virtio-scsi.x86_64-latest.args | 3 +- .../qemuxml2argvdata/hugepages-memaccess.args | 30 +-- .../hugepages-memaccess2.args | 12 +- .../hugepages-numa-nodeset-part.args | 5 +- .../hugepages-numa-nodeset.args | 20 +- .../hugepages-nvdimm.x86_64-latest.args | 15 +- tests/qemuxml2argvdata/hugepages-shared.args | 24 +-- .../hyperv-off.x86_64-latest.args | 3 +- .../hyperv-panic.x86_64-latest.args | 3 +- .../hyperv-stimer-direct.x86_64-latest.args | 3 +- .../hyperv.x86_64-latest.args | 3 +- .../intel-iommu-aw-bits.x86_64-latest.args | 4 +- ...ntel-iommu-caching-mode.x86_64-latest.args | 4 +- ...ntel-iommu-device-iotlb.x86_64-latest.args | 4 +- .../intel-iommu-eim.x86_64-latest.args | 4 +- .../intel-iommu.x86_64-latest.args | 3 +- ...threads-virtio-scsi-pci.x86_64-latest.args | 3 +- .../kvmclock+eoi-disabled.x86_64-latest.args | 3 +- ...luks-disks-source-qcow2.x86_64-latest.args | 4 +- ...memory-default-hugepage.x86_64-latest.args | 8 +- .../memfd-memory-numa.x86_64-latest.args | 8 +- .../memory-hotplug-dimm-addr.args | 6 +- .../qemuxml2argvdata/memory-hotplug-dimm.args | 6 +- ...y-hotplug-nvdimm-access.x86_64-latest.args | 8 +- ...ry-hotplug-nvdimm-align.x86_64-latest.args | 8 +- ...ry-hotplug-nvdimm-label.x86_64-latest.args | 8 +- ...ory-hotplug-nvdimm-pmem.x86_64-latest.args | 8 +- ...ory-hotplug-nvdimm-ppc64.ppc64-latest.args | 2 +- ...hotplug-nvdimm-readonly.x86_64-latest.args | 8 +- .../memory-hotplug-nvdimm.x86_64-latest.args | 6 +- .../mlock-off.x86_64-latest.args | 3 +- .../mlock-on.x86_64-latest.args | 3 +- .../net-vhostuser.x86_64-latest.args | 3 +- .../numatune-hmat.x86_64-latest.args | 4 +- .../os-firmware-bios.x86_64-latest.args | 4 +- ...os-firmware-efi-secboot.x86_64-latest.args | 4 +- .../os-firmware-efi.x86_64-latest.args | 4 +- .../qemuxml2argvdata/pages-dimm-discard.args | 4 +- .../parallel-unix-chardev.x86_64-latest.args | 3 +- ...cie-root-port-nohotplug.x86_64-latest.args | 3 +- .../pv-spinlock-disabled.x86_64-latest.args | 3 +- .../pv-spinlock-enabled.x86_64-latest.args | 3 +- .../qemu-ns.x86_64-latest.args | 3 +- .../serial-unix-chardev.x86_64-latest.args | 3 +- ...rtcard-passthrough-unix.x86_64-latest.args | 3 +- .../tpm-emulator-tpm2-enc.x86_64-latest.args | 4 +- .../tpm-emulator-tpm2.x86_64-latest.args | 4 +- .../tpm-emulator.x86_64-latest.args | 4 +- .../tpm-passthrough-crb.x86_64-latest.args | 4 +- .../tpm-passthrough.x86_64-latest.args | 4 +- .../tseg-explicit-size.x86_64-latest.args | 4 +- .../usb-redir-unix.x86_64-latest.args | 3 +- tests/qemuxml2argvdata/user-aliases.args | 16 +- ...vhost-user-fs-fd-memory.x86_64-latest.args | 4 +- ...vhost-user-fs-hugepages.x86_64-latest.args | 10 +- ...host-user-gpu-secondary.x86_64-latest.args | 3 +- .../vhost-user-vga.x86_64-latest.args | 3 +- .../vhost-vsock-auto.x86_64-latest.args | 4 +- .../vhost-vsock.x86_64-latest.args | 3 +- ...eo-bochs-display-device.x86_64-latest.args | 3 +- ...video-qxl-device-vram64.x86_64-latest.args | 3 +- ...o-qxl-sec-device-vram64.x86_64-latest.args | 3 +- ...eo-ramfb-display-device.x86_64-latest.args | 3 +- .../virtio-9p-multidevs.x86_64-latest.args | 3 +- ...virtio-non-transitional.x86_64-latest.args | 3 +- ...-options-controller-ats.x86_64-latest.args | 3 +- ...ptions-controller-iommu.x86_64-latest.args | 3 +- ...tions-controller-packed.x86_64-latest.args | 3 +- ...virtio-options-disk-ats.x86_64-latest.args | 3 +- ...rtio-options-disk-iommu.x86_64-latest.args | 3 +- ...tio-options-disk-packed.x86_64-latest.args | 3 +- .../virtio-options-fs-ats.x86_64-latest.args | 3 +- ...virtio-options-fs-iommu.x86_64-latest.args | 3 +- ...irtio-options-fs-packed.x86_64-latest.args | 3 +- ...irtio-options-input-ats.x86_64-latest.args | 3 +- ...tio-options-input-iommu.x86_64-latest.args | 3 +- ...io-options-input-packed.x86_64-latest.args | 3 +- ...-options-memballoon-ats.x86_64-latest.args | 3 +- ...ptions-memballoon-iommu.x86_64-latest.args | 3 +- ...tions-memballoon-packed.x86_64-latest.args | 3 +- .../virtio-options-net-ats.x86_64-latest.args | 3 +- ...irtio-options-net-iommu.x86_64-latest.args | 3 +- ...rtio-options-net-packed.x86_64-latest.args | 3 +- .../virtio-options-rng-ats.x86_64-latest.args | 3 +- ...irtio-options-rng-iommu.x86_64-latest.args | 3 +- ...rtio-options-rng-packed.x86_64-latest.args | 3 +- ...irtio-options-video-ats.x86_64-latest.args | 3 +- ...tio-options-video-iommu.x86_64-latest.args | 3 +- ...io-options-video-packed.x86_64-latest.args | 3 +- .../virtio-options.x86_64-latest.args | 3 +- .../virtio-rng-builtin.x86_64-latest.args | 3 +- .../virtio-rng-egd-unix.x86_64-latest.args | 3 +- .../virtio-transitional.x86_64-latest.args | 3 +- ...-default-cpu-kvm-pc-4.2.x86_64-latest.args | 4 +- ...default-cpu-kvm-q35-4.2.x86_64-latest.args | 4 +- ...-default-cpu-tcg-pc-4.2.x86_64-latest.args | 4 +- ...default-cpu-tcg-q35-4.2.x86_64-latest.args | 4 +- .../x86_64-pc-graphics.x86_64-latest.args | 3 +- .../x86_64-pc-headless.x86_64-latest.args | 3 +- .../x86_64-q35-graphics.x86_64-latest.args | 3 +- .../x86_64-q35-headless.x86_64-latest.args | 3 +- tests/testutilsqemu.c | 15 +- 168 files changed, 671 insertions(+), 357 deletions(-) -- 2.26.2

All three memory backends (-file, -ram and -memfd) have .prealloc attribute. Since we are setting it only for -file, the corresponding code lives only under if() that handles that specific backend. But in near future we will want to set the attribute for other backends too. Therefore, move the corresponding code outside of the if(). This causes some .argv files to be changed, but the only change happening there is move of the attribute (best viewed with: 'git show --color-words=.'). Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 11 +++---- .../qemuxml2argvdata/hugepages-memaccess.args | 30 +++++++++---------- .../hugepages-memaccess2.args | 12 ++++---- .../hugepages-numa-nodeset-part.args | 5 ++-- .../hugepages-numa-nodeset.args | 20 ++++++++----- .../hugepages-nvdimm.x86_64-latest.args | 9 +++--- tests/qemuxml2argvdata/hugepages-shared.args | 24 +++++++-------- .../memory-hotplug-dimm-addr.args | 6 ++-- .../qemuxml2argvdata/memory-hotplug-dimm.args | 6 ++-- ...y-hotplug-nvdimm-access.x86_64-latest.args | 4 +-- ...ry-hotplug-nvdimm-align.x86_64-latest.args | 4 +-- ...ry-hotplug-nvdimm-label.x86_64-latest.args | 4 +-- ...ory-hotplug-nvdimm-pmem.x86_64-latest.args | 4 +-- ...ory-hotplug-nvdimm-ppc64.ppc64-latest.args | 2 +- ...hotplug-nvdimm-readonly.x86_64-latest.args | 4 +-- .../memory-hotplug-nvdimm.x86_64-latest.args | 2 +- .../qemuxml2argvdata/pages-dimm-discard.args | 4 +-- tests/qemuxml2argvdata/user-aliases.args | 16 +++++----- ...vhost-user-fs-hugepages.x86_64-latest.args | 5 ++-- 19 files changed, 90 insertions(+), 82 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index bd98b0a97c..75fd17311f 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -3108,13 +3108,11 @@ qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, if (mem->nvdimmPath) { memPath = g_strdup(mem->nvdimmPath); - if (!priv->memPrealloc) - prealloc = true; + prealloc = true; } else if (useHugepage) { if (qemuGetDomainHupageMemPath(priv->driver, def, pagesize, &memPath) < 0) return -1; - if (!priv->memPrealloc) - prealloc = true; + prealloc = true; } else { /* We can have both pagesize and mem source. If that's the case, * prefer hugepages as those are more specific. */ @@ -3123,7 +3121,6 @@ qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, } if (virJSONValueObjectAdd(props, - "B:prealloc", prealloc, "s:mem-path", memPath, NULL) < 0) return -1; @@ -3148,6 +3145,10 @@ qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, backendType = "memory-backend-ram"; } + if (!priv->memPrealloc && + virJSONValueObjectAdd(props, "B:prealloc", prealloc, NULL) < 0) + return -1; + if (virJSONValueObjectAdd(props, "U:size", mem->size * 1024, NULL) < 0) return -1; diff --git a/tests/qemuxml2argvdata/hugepages-memaccess.args b/tests/qemuxml2argvdata/hugepages-memaccess.args index 7cfbce7c7c..3358a8c965 100644 --- a/tests/qemuxml2argvdata/hugepages-memaccess.args +++ b/tests/qemuxml2argvdata/hugepages-memaccess.args @@ -14,25 +14,25 @@ QEMU_AUDIO_DRV=none \ -m size=4194304k,slots=16,maxmem=8388608k \ -realtime mlock=off \ -smp 4,sockets=4,cores=1,threads=1 \ --object memory-backend-file,id=ram-node0,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,size=1073741824,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=ram-node0,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,prealloc=yes,\ +size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=0,cpus=0,memdev=ram-node0 \ --object memory-backend-file,id=ram-node1,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,size=1073741824,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=ram-node1,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,prealloc=yes,\ +size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=1,cpus=1,memdev=ram-node1 \ --object memory-backend-file,id=ram-node2,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,size=1073741824,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=ram-node2,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,prealloc=yes,\ +size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=2,cpus=2,memdev=ram-node2 \ --object memory-backend-file,id=ram-node3,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,size=1073741824,\ -host-nodes=3,policy=bind \ +-object memory-backend-file,id=ram-node3,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,prealloc=yes,\ +size=1073741824,host-nodes=3,policy=bind \ -numa node,nodeid=3,cpus=3,memdev=ram-node3 \ --object memory-backend-file,id=memdimm0,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,size=536870912,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=memdimm0,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,prealloc=yes,\ +size=536870912,host-nodes=0-3,policy=bind \ -device pc-dimm,node=1,memdev=memdimm0,id=dimm0,slot=0,addr=4294967296 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/hugepages-memaccess2.args b/tests/qemuxml2argvdata/hugepages-memaccess2.args index c1560e63c3..f74bf8dc9b 100644 --- a/tests/qemuxml2argvdata/hugepages-memaccess2.args +++ b/tests/qemuxml2argvdata/hugepages-memaccess2.args @@ -18,9 +18,9 @@ QEMU_AUDIO_DRV=none \ mem-path=/var/lib/libvirt/qemu/ram/-1-QEMUGuest1/ram-node0,share=no,\ size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=0,cpus=0,memdev=ram-node0 \ --object memory-backend-file,id=ram-node1,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,size=1073741824,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=ram-node1,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,prealloc=yes,\ +size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=1,cpus=1,memdev=ram-node1 \ -object memory-backend-file,id=ram-node2,\ mem-path=/var/lib/libvirt/qemu/ram/-1-QEMUGuest1/ram-node2,share=no,\ @@ -30,9 +30,9 @@ size=1073741824,host-nodes=0-3,policy=bind \ mem-path=/var/lib/libvirt/qemu/ram/-1-QEMUGuest1/ram-node3,share=no,\ size=1073741824,host-nodes=3,policy=bind \ -numa node,nodeid=3,cpus=3,memdev=ram-node3 \ --object memory-backend-file,id=memdimm0,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,size=536870912,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=memdimm0,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,prealloc=yes,\ +size=536870912,host-nodes=0-3,policy=bind \ -device pc-dimm,node=1,memdev=memdimm0,id=dimm0,slot=0,addr=4294967296 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/hugepages-numa-nodeset-part.args b/tests/qemuxml2argvdata/hugepages-numa-nodeset-part.args index 7849143e69..6debc99442 100644 --- a/tests/qemuxml2argvdata/hugepages-numa-nodeset-part.args +++ b/tests/qemuxml2argvdata/hugepages-numa-nodeset-part.args @@ -16,8 +16,9 @@ QEMU_AUDIO_DRV=none \ -smp 2,sockets=2,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=268435456 \ -numa node,nodeid=0,cpus=0,memdev=ram-node0 \ --object memory-backend-file,id=ram-node1,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-SomeDummyHugepagesGu,size=805306368 \ +-object memory-backend-file,id=ram-node1,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-SomeDummyHugepagesGu,prealloc=yes,\ +size=805306368 \ -numa node,nodeid=1,cpus=1,memdev=ram-node1 \ -uuid ef1bdff4-27f3-4e85-a807-5fb4d58463cc \ -display none \ diff --git a/tests/qemuxml2argvdata/hugepages-numa-nodeset.args b/tests/qemuxml2argvdata/hugepages-numa-nodeset.args index 7b510be6b3..6c05e54c63 100644 --- a/tests/qemuxml2argvdata/hugepages-numa-nodeset.args +++ b/tests/qemuxml2argvdata/hugepages-numa-nodeset.args @@ -14,17 +14,21 @@ QEMU_AUDIO_DRV=none \ -m 4096 \ -realtime mlock=off \ -smp 4,sockets=4,cores=1,threads=1 \ --object memory-backend-file,id=ram-node0,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,size=1073741824 \ +-object memory-backend-file,id=ram-node0,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=1073741824 \ -numa node,nodeid=0,cpus=0,memdev=ram-node0 \ --object memory-backend-file,id=ram-node1,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,size=1073741824 \ +-object memory-backend-file,id=ram-node1,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=1073741824 \ -numa node,nodeid=1,cpus=1,memdev=ram-node1 \ --object memory-backend-file,id=ram-node2,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,size=1073741824 \ +-object memory-backend-file,id=ram-node2,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=1073741824 \ -numa node,nodeid=2,cpus=2,memdev=ram-node2 \ --object memory-backend-file,id=ram-node3,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,size=1073741824 \ +-object memory-backend-file,id=ram-node3,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=1073741824 \ -numa node,nodeid=3,cpus=3,memdev=ram-node3 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args b/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args index e80a95c84b..969bb713b5 100644 --- a/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args @@ -17,11 +17,12 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -m size=1048576k,slots=16,maxmem=1099511627776k \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ --object memory-backend-file,id=ram-node0,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,size=1073741824 \ +-object memory-backend-file,id=ram-node0,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,prealloc=yes,\ +size=1073741824 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ -share=yes,size=536870912 \ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,share=yes,\ +prealloc=yes,size=536870912 \ -device nvdimm,node=0,memdev=memnvdimm0,id=nvdimm0,slot=0 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/hugepages-shared.args b/tests/qemuxml2argvdata/hugepages-shared.args index 545b86b223..a3cb6b9b9e 100644 --- a/tests/qemuxml2argvdata/hugepages-shared.args +++ b/tests/qemuxml2argvdata/hugepages-shared.args @@ -14,21 +14,21 @@ QEMU_AUDIO_DRV=none \ -m 4096 \ -realtime mlock=off \ -smp 4,sockets=4,cores=1,threads=1 \ --object memory-backend-file,id=ram-node0,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,size=1073741824,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=ram-node0,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=0,cpus=0,memdev=ram-node0 \ --object memory-backend-file,id=ram-node1,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,size=1073741824,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=ram-node1,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,prealloc=yes,\ +size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=1,cpus=1,memdev=ram-node1 \ --object memory-backend-file,id=ram-node2,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,size=1073741824,\ -host-nodes=0-3,policy=bind \ +-object memory-backend-file,id=ram-node2,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,share=no,prealloc=yes,\ +size=1073741824,host-nodes=0-3,policy=bind \ -numa node,nodeid=2,cpus=2,memdev=ram-node2 \ --object memory-backend-file,id=ram-node3,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,size=1073741824,\ -host-nodes=3,policy=bind \ +-object memory-backend-file,id=ram-node3,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=1073741824,host-nodes=3,policy=bind \ -numa node,nodeid=3,cpus=3,memdev=ram-node3 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-dimm-addr.args b/tests/qemuxml2argvdata/memory-hotplug-dimm-addr.args index 9ba3f8b7a0..465f1e5e7a 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-dimm-addr.args +++ b/tests/qemuxml2argvdata/memory-hotplug-dimm-addr.args @@ -15,9 +15,9 @@ QEMU_AUDIO_DRV=none \ -realtime mlock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -numa node,nodeid=0,cpus=0-1,mem=214 \ --object memory-backend-file,id=memdimm0,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,size=536870912,\ -host-nodes=1-3,policy=bind \ +-object memory-backend-file,id=memdimm0,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=536870912,host-nodes=1-3,policy=bind \ -device pc-dimm,node=0,memdev=memdimm0,id=dimm0,slot=0,addr=4294967296 \ -object memory-backend-ram,id=memdimm2,size=536870912 \ -device pc-dimm,node=0,memdev=memdimm2,id=dimm2,slot=2 \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-dimm.args b/tests/qemuxml2argvdata/memory-hotplug-dimm.args index 0ac48db399..6737bc5961 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-dimm.args +++ b/tests/qemuxml2argvdata/memory-hotplug-dimm.args @@ -17,9 +17,9 @@ QEMU_AUDIO_DRV=none \ -numa node,nodeid=0,cpus=0-1,mem=214 \ -object memory-backend-ram,id=memdimm0,size=536870912 \ -device pc-dimm,node=0,memdev=memdimm0,id=dimm0,slot=0 \ --object memory-backend-file,id=memdimm1,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,size=536870912,\ -host-nodes=1-3,policy=bind \ +-object memory-backend-file,id=memdimm1,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,prealloc=yes,\ +size=536870912,host-nodes=1-3,policy=bind \ -device pc-dimm,node=0,memdev=memdimm1,id=dimm1,slot=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args index faa85355d3..8d3fa2e867 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args @@ -19,8 +19,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ -share=no,size=536870912 \ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,share=no,\ +prealloc=yes,size=536870912 \ -device nvdimm,node=0,memdev=memnvdimm0,id=nvdimm0,slot=0 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args index 074d8f590b..4f22f78277 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args @@ -19,8 +19,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ -share=no,size=536870912,align=2097152 \ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,share=no,\ +prealloc=yes,size=536870912,align=2097152 \ -device nvdimm,node=0,memdev=memnvdimm0,id=nvdimm0,slot=0 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args index 522a5bd2fd..53dda234a2 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args @@ -19,8 +19,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ -share=no,size=536870912 \ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,share=no,\ +prealloc=yes,size=536870912 \ -device nvdimm,node=0,label-size=131072,memdev=memnvdimm0,id=nvdimm0,slot=0 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args index 630a60c0ae..cac02a6f6d 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args @@ -19,8 +19,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ -share=no,size=536870912,pmem=yes \ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,share=no,\ +prealloc=yes,size=536870912,pmem=yes \ -device nvdimm,node=0,memdev=memnvdimm0,id=nvdimm0,slot=0 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-ppc64.ppc64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-ppc64.ppc64-latest.args index 58e3f9e161..82b281132b 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-ppc64.ppc64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-ppc64.ppc64-latest.args @@ -18,7 +18,7 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -numa node,nodeid=0,cpus=0-1,mem=1024 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,prealloc=yes,\ size=805437440 \ -device nvdimm,node=0,label-size=131072,\ uuid=49545eb3-75e1-2d0a-acdd-f0294406c99e,memdev=memnvdimm0,id=nvdimm0,slot=0 \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args index e070bd74f9..5e44496e39 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args @@ -19,8 +19,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ -share=no,size=536870912 \ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,share=no,\ +prealloc=yes,size=536870912 \ -device nvdimm,node=0,unarmed=on,memdev=memnvdimm0,id=nvdimm0,slot=0 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args index 893360f9e6..94f8444d95 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args @@ -19,7 +19,7 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=1073741824 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ --object memory-backend-file,id=memnvdimm0,prealloc=yes,mem-path=/tmp/nvdimm,\ +-object memory-backend-file,id=memnvdimm0,mem-path=/tmp/nvdimm,prealloc=yes,\ size=536870912 \ -device nvdimm,node=0,memdev=memnvdimm0,id=nvdimm0,slot=0 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/pages-dimm-discard.args b/tests/qemuxml2argvdata/pages-dimm-discard.args index 96e9ffdec3..a615dc0c18 100644 --- a/tests/qemuxml2argvdata/pages-dimm-discard.args +++ b/tests/qemuxml2argvdata/pages-dimm-discard.args @@ -15,8 +15,8 @@ QEMU_AUDIO_DRV=none \ -realtime mlock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -numa node,nodeid=0,cpus=0-1,mem=1024 \ --object memory-backend-file,id=memdimm0,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-fedora,size=1073741824,\ +-object memory-backend-file,id=memdimm0,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-fedora,prealloc=yes,size=1073741824,\ host-nodes=1-3,policy=bind \ -device pc-dimm,node=0,memdev=memdimm0,id=dimm0,slot=0 \ -object memory-backend-file,id=memdimm1,\ diff --git a/tests/qemuxml2argvdata/user-aliases.args b/tests/qemuxml2argvdata/user-aliases.args index 88e540bc3c..e0eed48abf 100644 --- a/tests/qemuxml2argvdata/user-aliases.args +++ b/tests/qemuxml2argvdata/user-aliases.args @@ -16,17 +16,17 @@ file=/tmp/lib/domain--1-gentoo/master-key.aes \ -m 4096 \ -realtime mlock=off \ -smp 4,sockets=4,cores=1,threads=1 \ --object memory-backend-file,id=ram-node0,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,size=1073741824 \ +-object memory-backend-file,id=ram-node0,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,prealloc=yes,size=1073741824 \ -numa node,nodeid=0,cpus=0,memdev=ram-node0 \ --object memory-backend-file,id=ram-node1,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,size=1073741824 \ +-object memory-backend-file,id=ram-node1,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,prealloc=yes,size=1073741824 \ -numa node,nodeid=1,cpus=1,memdev=ram-node1 \ --object memory-backend-file,id=ram-node2,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,size=1073741824 \ +-object memory-backend-file,id=ram-node2,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,prealloc=yes,size=1073741824 \ -numa node,nodeid=2,cpus=2,memdev=ram-node2 \ --object memory-backend-file,id=ram-node3,prealloc=yes,\ -mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,size=1073741824 \ +-object memory-backend-file,id=ram-node3,\ +mem-path=/dev/hugepages1G/libvirt/qemu/-1-gentoo,prealloc=yes,size=1073741824 \ -numa node,nodeid=3,cpus=3,memdev=ram-node3 \ -uuid a75aca4b-a02f-2bcb-4a91-c93cd848c34b \ -no-user-config \ diff --git a/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args b/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args index 258fa7813f..e4f5db7a63 100644 --- a/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args +++ b/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args @@ -17,8 +17,9 @@ file=/tmp/lib/domain--1-guest/master-key.aes \ -m 2048 \ -overcommit mem-lock=off \ -smp 2,sockets=2,cores=1,threads=1 \ --object memory-backend-file,id=ram-node0,prealloc=yes,\ -mem-path=/dev/hugepages2M/libvirt/qemu/-1-guest,share=yes,size=2147483648 \ +-object memory-backend-file,id=ram-node0,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-guest,share=yes,prealloc=yes,\ +size=2147483648 \ -numa node,nodeid=0,cpus=0-1,memdev=ram-node0 \ -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \ -display none \ -- 2.26.2

On a Tuesday in 2020, Michal Privoznik wrote:
All three memory backends (-file, -ram and -memfd) have .prealloc attribute. Since we are setting it only for -file, the corresponding code lives only under if() that handles that specific backend. But in near future we will want to set the attribute for other backends too. Therefore, move the corresponding code outside of the if().
This causes some .argv files to be changed, but the only change happening there is move of the attribute (best viewed with: 'git show --color-words=.').
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 11 +++---- .../qemuxml2argvdata/hugepages-memaccess.args | 30 +++++++++---------- .../hugepages-memaccess2.args | 12 ++++---- .../hugepages-numa-nodeset-part.args | 5 ++-- .../hugepages-numa-nodeset.args | 20 ++++++++----- .../hugepages-nvdimm.x86_64-latest.args | 9 +++--- tests/qemuxml2argvdata/hugepages-shared.args | 24 +++++++-------- .../memory-hotplug-dimm-addr.args | 6 ++-- .../qemuxml2argvdata/memory-hotplug-dimm.args | 6 ++-- ...y-hotplug-nvdimm-access.x86_64-latest.args | 4 +-- ...ry-hotplug-nvdimm-align.x86_64-latest.args | 4 +-- ...ry-hotplug-nvdimm-label.x86_64-latest.args | 4 +-- ...ory-hotplug-nvdimm-pmem.x86_64-latest.args | 4 +-- ...ory-hotplug-nvdimm-ppc64.ppc64-latest.args | 2 +- ...hotplug-nvdimm-readonly.x86_64-latest.args | 4 +-- .../memory-hotplug-nvdimm.x86_64-latest.args | 2 +- .../qemuxml2argvdata/pages-dimm-discard.args | 4 +-- tests/qemuxml2argvdata/user-aliases.args | 16 +++++----- ...vhost-user-fs-hugepages.x86_64-latest.args | 5 ++-- 19 files changed, 90 insertions(+), 82 deletions(-)
Reviewed-by: Ján Tomko <jtomko@redhat.com> Jano

If user specifies immediate memory allocation in the domain XML, they want QEMU to fully allocate its memory. And if the memory was allocated using plain '-m' then we would honour it. But, if a memory backend is used, then we don't set the prealloc attribute of the backend. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 75fd17311f..19c86fb00d 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -3027,6 +3027,9 @@ qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, if (discard == VIR_TRISTATE_BOOL_ABSENT) discard = def->mem.discard; + if (def->mem.allocation == VIR_DOMAIN_MEMORY_ALLOCATION_IMMEDIATE) + prealloc = true; + if (virDomainNumatuneGetMode(def->numa, mem->targetNode, &mode) < 0 && virDomainNumatuneGetMode(def->numa, -1, &mode) < 0) mode = VIR_DOMAIN_NUMATUNE_MEM_STRICT; -- 2.26.2

On a Tuesday in 2020, Michal Privoznik wrote:
If user specifies immediate memory allocation in the domain XML, they want QEMU to fully allocate its memory. And if the memory was allocated using plain '-m' then we would honour it. But, if a memory backend is used, then we don't set the prealloc attribute of the backend.
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 3 +++ 1 file changed, 3 insertions(+)
Reviewed-by: Ján Tomko <jtomko@redhat.com> Jano

If a domain was using hugepages through memory-backend-file or via -mem-path, we would turn prealloc on. But we are not doing that for memory-backend-memfd. Fix this, because we need QEMU to fully allocate hugepages. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 19c86fb00d..b673645826 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -3097,10 +3097,13 @@ qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, if (def->mem.source == VIR_DOMAIN_MEMORY_SOURCE_MEMFD) { backendType = "memory-backend-memfd"; - if (useHugepage && - (virJSONValueObjectAdd(props, "b:hugetlb", useHugepage, NULL) < 0 || - virJSONValueObjectAdd(props, "U:hugetlbsize", pagesize << 10, NULL) < 0)) { - return -1; + if (useHugepage) { + if (virJSONValueObjectAdd(props, "b:hugetlb", useHugepage, NULL) < 0 || + virJSONValueObjectAdd(props, "U:hugetlbsize", pagesize << 10, NULL) < 0) { + return -1; + } + + prealloc = true; } if (qemuBuildMemoryBackendPropsShare(props, memAccess) < 0) -- 2.26.2

On a Tuesday in 2020, Michal Privoznik wrote:
If a domain was using hugepages through memory-backend-file or via -mem-path, we would turn prealloc on. But we are not doing that for memory-backend-memfd. Fix this, because we need QEMU to fully allocate hugepages.
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-)
Reviewed-by: Ján Tomko <jtomko@redhat.com> Jano

The objects at @def and @mem pointers is only read and not written. Make the arguments const to make that explicit. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 4 ++-- src/qemu/qemu_command.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index b673645826..ecbdd226a4 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -2976,8 +2976,8 @@ qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, const char *alias, virQEMUDriverConfigPtr cfg, qemuDomainObjPrivatePtr priv, - virDomainDefPtr def, - virDomainMemoryDefPtr mem, + const virDomainDef *def, + const virDomainMemoryDef *mem, bool force) { const char *backendType = "memory-backend-file"; diff --git a/src/qemu/qemu_command.h b/src/qemu/qemu_command.h index 89d99b111f..8a30f2852c 100644 --- a/src/qemu/qemu_command.h +++ b/src/qemu/qemu_command.h @@ -150,8 +150,8 @@ int qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, const char *alias, virQEMUDriverConfigPtr cfg, qemuDomainObjPrivatePtr priv, - virDomainDefPtr def, - virDomainMemoryDefPtr mem, + const virDomainDef *def, + const virDomainMemoryDef *mem, bool force); char *qemuBuildMemoryDeviceStr(virDomainMemoryDefPtr mem, -- 2.26.2

On a Tuesday in 2020, Michal Privoznik wrote:
The objects at @def and @mem pointers is only read and not written. Make the arguments const to make that explicit.
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 4 ++-- src/qemu/qemu_command.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
Better than nothing(TM). Reviewed-by: Ján Tomko <jtomko@redhat.com> Jano

This capability corresponds to '-machine memory-backend=' command line argument. Unfortunately, it is not possible for us to detect the capability via QMP and therefore we have to have a version check. The QEMU capability was introduced in v5.1.0-3-gc556600598. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_capabilities.c | 7 +++++++ src/qemu/qemu_capabilities.h | 3 +++ tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml | 1 + 3 files changed, 11 insertions(+) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index dcfd7cdd4e..d0a7c7b30e 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -597,6 +597,9 @@ VIR_ENUM_IMPL(virQEMUCaps, "spapr-tpm-proxy", "numa.hmat", "blockdev-hostdev-scsi", + + /* 380 */ + "machine.memory-backend", ); @@ -5104,6 +5107,10 @@ virQEMUCapsInitQMPVersionCaps(virQEMUCapsPtr qemuCaps) /* TCG couldn't be disabled nor queried until QEMU 2.10 */ if (qemuCaps->version < 2010000) virQEMUCapsSet(qemuCaps, QEMU_CAPS_TCG); + + /* no way to query for -machine memory-backend */ + if (qemuCaps->version >= 5001050) + virQEMUCapsSet(qemuCaps, QEMU_CAPS_MACHINE_MEMORY_BACKEND); } diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index 5d08941538..9b2842e84b 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -578,6 +578,9 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */ QEMU_CAPS_NUMA_HMAT, /* -numa hmat */ QEMU_CAPS_BLOCKDEV_HOSTDEV_SCSI, /* -blockdev used for (i)SCSI hostdevs */ + /* 380 */ + QEMU_CAPS_MACHINE_MEMORY_BACKEND, /* -machine memory-backend */ + QEMU_CAPS_LAST /* this must always be the last item */ } virQEMUCapsFlags; diff --git a/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml b/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml index 151bd18137..11eb15ca6a 100644 --- a/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml @@ -242,6 +242,7 @@ <flag name='intel-iommu.aw-bits'/> <flag name='numa.hmat'/> <flag name='blockdev-hostdev-scsi'/> + <flag name='machine.memory-backend'/> <version>5001050</version> <kvmVersion>0</kvmVersion> <microcodeVersion>43100243</microcodeVersion> -- 2.26.2

On a Tuesday in 2020, Michal Privoznik wrote:
This capability corresponds to '-machine memory-backend=' command line argument. Unfortunately, it is not possible for us to detect the capability via QMP and therefore we have to have a version check.
The QEMU capability was introduced in v5.1.0-3-gc556600598.
Please rephrase this or drop the period at the end, e.g.: QEMU commit v5.1.0-3-gc556600598 introduced the capability. (to make it easier to select)
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_capabilities.c | 7 +++++++ src/qemu/qemu_capabilities.h | 3 +++ tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml | 1 + 3 files changed, 11 insertions(+)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index dcfd7cdd4e..d0a7c7b30e 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -597,6 +597,9 @@ VIR_ENUM_IMPL(virQEMUCaps, "spapr-tpm-proxy", "numa.hmat", "blockdev-hostdev-scsi", + + /* 380 */ + "machine.memory-backend", );
@@ -5104,6 +5107,10 @@ virQEMUCapsInitQMPVersionCaps(virQEMUCapsPtr qemuCaps) /* TCG couldn't be disabled nor queried until QEMU 2.10 */ if (qemuCaps->version < 2010000) virQEMUCapsSet(qemuCaps, QEMU_CAPS_TCG); + + /* no way to query for -machine memory-backend */ + if (qemuCaps->version >= 5001050)
That's a git version. Also, the above mentioned commit introduces the 'default-ram-id' property, which does show up in our capability replies file. Can't we safely assume that its presence also means that -machine memory-backend is supported? Jano
+ virQEMUCapsSet(qemuCaps, QEMU_CAPS_MACHINE_MEMORY_BACKEND); }
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index 5d08941538..9b2842e84b 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -578,6 +578,9 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */ QEMU_CAPS_NUMA_HMAT, /* -numa hmat */ QEMU_CAPS_BLOCKDEV_HOSTDEV_SCSI, /* -blockdev used for (i)SCSI hostdevs */
+ /* 380 */ + QEMU_CAPS_MACHINE_MEMORY_BACKEND, /* -machine memory-backend */ + QEMU_CAPS_LAST /* this must always be the last item */ } virQEMUCapsFlags;
diff --git a/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml b/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml index 151bd18137..11eb15ca6a 100644 --- a/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml @@ -242,6 +242,7 @@ <flag name='intel-iommu.aw-bits'/> <flag name='numa.hmat'/> <flag name='blockdev-hostdev-scsi'/> + <flag name='machine.memory-backend'/> <version>5001050</version> <kvmVersion>0</kvmVersion> <microcodeVersion>43100243</microcodeVersion> -- 2.26.2

On 9/8/20 1:21 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
This capability corresponds to '-machine memory-backend=' command line argument. Unfortunately, it is not possible for us to detect the capability via QMP and therefore we have to have a version check.
The QEMU capability was introduced in v5.1.0-3-gc556600598.
Please rephrase this or drop the period at the end, e.g.:
QEMU commit v5.1.0-3-gc556600598 introduced the capability.
(to make it easier to select)
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_capabilities.c | 7 +++++++ src/qemu/qemu_capabilities.h | 3 +++ tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml | 1 + 3 files changed, 11 insertions(+)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index dcfd7cdd4e..d0a7c7b30e 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -597,6 +597,9 @@ VIR_ENUM_IMPL(virQEMUCaps, "spapr-tpm-proxy", "numa.hmat", "blockdev-hostdev-scsi", + + /* 380 */ + "machine.memory-backend", );
@@ -5104,6 +5107,10 @@ virQEMUCapsInitQMPVersionCaps(virQEMUCapsPtr qemuCaps) /* TCG couldn't be disabled nor queried until QEMU 2.10 */ if (qemuCaps->version < 2010000) virQEMUCapsSet(qemuCaps, QEMU_CAPS_TCG); + + /* no way to query for -machine memory-backend */ + if (qemuCaps->version >= 5001050)
That's a git version.
Also, the above mentioned commit introduces the 'default-ram-id' property, which does show up in our capability replies file.
Can't we safely assume that its presence also means that -machine memory-backend is supported?
Good point. We can do that. However, I will need to do a slight change to 6/7 to qemuTestCapsCacheInsert() because there I'm filling default-ram-id for all qemuCaps, even old versions that don't have it in real world. So basically, I will need to move this version check into qemuTestCapsCacheInsert() but I guess that's okay if I put a comment next to it. Michal

The machine structure has another (optional) attribute: default-ram-id, which specifies the alias of the default RAM object. While the alias is private, it can never change in order to not break migration. QEMU uses the alias when allocating regular, not NUMA memory. In order to switch to new command line and maintain migration, save this ID. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_capabilities.c | 35 +++- src/qemu/qemu_capabilities.h | 3 + src/qemu/qemu_capspriv.h | 3 +- src/qemu/qemu_monitor.c | 1 + src/qemu/qemu_monitor.h | 1 + src/qemu/qemu_monitor_json.c | 11 + .../caps_5.2.0.x86_64.xml | 196 +++++++++--------- tests/testutilsqemu.c | 15 +- 8 files changed, 161 insertions(+), 104 deletions(-) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index d0a7c7b30e..cc05c04560 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -613,6 +613,7 @@ struct _virQEMUCapsMachineType { bool qemuDefault; char *defaultCPU; bool numaMemSupported; + char *defaultRAMid; }; typedef struct _virQEMUCapsHostCPUData virQEMUCapsHostCPUData; @@ -1890,6 +1891,7 @@ virQEMUCapsAccelCopyMachineTypes(virQEMUCapsAccelPtr dst, dst->machineTypes[i].hotplugCpus = src->machineTypes[i].hotplugCpus; dst->machineTypes[i].qemuDefault = src->machineTypes[i].qemuDefault; dst->machineTypes[i].numaMemSupported = src->machineTypes[i].numaMemSupported; + dst->machineTypes[i].defaultRAMid = g_strdup(src->machineTypes[i].defaultRAMid); } } @@ -1967,6 +1969,7 @@ virQEMUCapsAccelClear(virQEMUCapsAccelPtr caps) VIR_FREE(caps->machineTypes[i].name); VIR_FREE(caps->machineTypes[i].alias); VIR_FREE(caps->machineTypes[i].defaultCPU); + VIR_FREE(caps->machineTypes[i].defaultRAMid); } VIR_FREE(caps->machineTypes); @@ -2553,6 +2556,25 @@ virQEMUCapsGetMachineNumaMemSupported(virQEMUCapsPtr qemuCaps, } +const char * +virQEMUCapsGetMachineDefaultRAMid(virQEMUCapsPtr qemuCaps, + virDomainVirtType virtType, + const char *name) +{ + virQEMUCapsAccelPtr accel; + size_t i; + + accel = virQEMUCapsGetAccel(qemuCaps, virtType); + + for (i = 0; i < accel->nmachineTypes; i++) { + if (STREQ(accel->machineTypes[i].name, name)) + return accel->machineTypes[i].defaultRAMid; + } + + return NULL; +} + + /** * virQEMUCapsSetGICCapabilities: * @qemuCaps: QEMU capabilities @@ -2789,7 +2811,8 @@ virQEMUCapsAddMachine(virQEMUCapsPtr qemuCaps, int maxCpus, bool hotplugCpus, bool isDefault, - bool numaMemSupported) + bool numaMemSupported, + const char *defaultRAMid) { virQEMUCapsAccelPtr accel = virQEMUCapsGetAccel(qemuCaps, virtType); virQEMUCapsMachineTypePtr mach; @@ -2810,6 +2833,8 @@ virQEMUCapsAddMachine(virQEMUCapsPtr qemuCaps, mach->qemuDefault = isDefault; mach->numaMemSupported = numaMemSupported; + + mach->defaultRAMid = g_strdup(defaultRAMid); } /** @@ -2856,7 +2881,8 @@ virQEMUCapsProbeQMPMachineTypes(virQEMUCapsPtr qemuCaps, machines[i]->maxCpus, machines[i]->hotplugCpus, machines[i]->isDefault, - machines[i]->numaMemSupported); + machines[i]->numaMemSupported, + machines[i]->defaultRAMid); if (preferredMachine && (STREQ_NULLABLE(machines[i]->alias, preferredMachine) || @@ -4083,6 +4109,7 @@ virQEMUCapsLoadMachines(virQEMUCapsAccelPtr caps, VIR_FREE(str); caps->machineTypes[i].defaultCPU = virXMLPropString(nodes[i], "defaultCPU"); + caps->machineTypes[i].defaultRAMid = virXMLPropString(nodes[i], "defaultRAMid"); } return 0; @@ -4567,6 +4594,8 @@ virQEMUCapsFormatMachines(virQEMUCapsAccelPtr caps, caps->machineTypes[i].defaultCPU); if (caps->machineTypes[i].numaMemSupported) virBufferAddLit(buf, " numaMemSupported='yes'"); + virBufferEscapeString(buf, " defaultRAMid='%s'", + caps->machineTypes[i].defaultRAMid); virBufferAddLit(buf, "/>\n"); } } @@ -6350,7 +6379,7 @@ virQEMUCapsStripMachineAliasesForVirtType(virQEMUCapsPtr qemuCaps, if (name) { virQEMUCapsAddMachine(qemuCaps, virtType, name, NULL, mach->defaultCPU, mach->maxCpus, mach->hotplugCpus, mach->qemuDefault, - mach->numaMemSupported); + mach->numaMemSupported, mach->defaultRAMid); } } } diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index 9b2842e84b..69b3ec8747 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -691,6 +691,9 @@ const char *virQEMUCapsGetMachineDefaultCPU(virQEMUCapsPtr qemuCaps, bool virQEMUCapsGetMachineNumaMemSupported(virQEMUCapsPtr qemuCaps, virDomainVirtType virtType, const char *name); +const char *virQEMUCapsGetMachineDefaultRAMid(virQEMUCapsPtr qemuCaps, + virDomainVirtType virtType, + const char *name); void virQEMUCapsFilterByMachineType(virQEMUCapsPtr qemuCaps, virDomainVirtType virtType, diff --git a/src/qemu/qemu_capspriv.h b/src/qemu/qemu_capspriv.h index f6c06ea008..15fc79e88b 100644 --- a/src/qemu/qemu_capspriv.h +++ b/src/qemu/qemu_capspriv.h @@ -119,4 +119,5 @@ virQEMUCapsAddMachine(virQEMUCapsPtr qemuCaps, int maxCpus, bool hotplugCpus, bool isDefault, - bool numaMemSupported); + bool numaMemSupported, + const char *defaultRAMid); diff --git a/src/qemu/qemu_monitor.c b/src/qemu/qemu_monitor.c index 718ac50c08..8b0bf7a709 100644 --- a/src/qemu/qemu_monitor.c +++ b/src/qemu/qemu_monitor.c @@ -3525,6 +3525,7 @@ qemuMonitorMachineInfoFree(qemuMonitorMachineInfoPtr machine) VIR_FREE(machine->name); VIR_FREE(machine->alias); VIR_FREE(machine->defaultCPU); + VIR_FREE(machine->defaultRAMid); VIR_FREE(machine); } diff --git a/src/qemu/qemu_monitor.h b/src/qemu/qemu_monitor.h index d20a15c202..38eadfb041 100644 --- a/src/qemu/qemu_monitor.h +++ b/src/qemu/qemu_monitor.h @@ -1099,6 +1099,7 @@ struct _qemuMonitorMachineInfo { bool hotplugCpus; char *defaultCPU; bool numaMemSupported; + char *defaultRAMid; }; int qemuMonitorGetMachines(qemuMonitorPtr mon, diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c index 9cdf6c0f7f..03459b3fe8 100644 --- a/src/qemu/qemu_monitor_json.c +++ b/src/qemu/qemu_monitor_json.c @@ -5638,6 +5638,17 @@ int qemuMonitorJSONGetMachines(qemuMonitorPtr mon, } else { info->numaMemSupported = true; } + + if (virJSONValueObjectHasKey(child, "default-ram-id")) { + if (!(tmp = virJSONValueObjectGetString(child, "default-ram-id"))) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("query-machines reply has malformed " + "'default-ram-id' data")); + goto cleanup; + } + + info->defaultRAMid = g_strdup(tmp); + } } ret = n; diff --git a/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml b/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml index 11eb15ca6a..93a4238a7b 100644 --- a/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml @@ -1405,55 +1405,55 @@ </cpu> <cpu type='kvm' name='486-v1' typename='486-v1-x86_64-cpu' usable='yes'/> <cpu type='kvm' name='486' typename='486-x86_64-cpu' usable='yes'/> - <machine type='kvm' name='pc-i440fx-5.2' alias='pc' hotplugCpus='yes' maxCpus='255' default='yes' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='kvm' name='pc-q35-5.2' alias='q35' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='kvm' name='pc-i440fx-2.12' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-4.2' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-4.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-1.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-1.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.10' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-1.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-5.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='kvm' name='pc-q35-2.9' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.11' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-3.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-4.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-1.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-4.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-5.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='kvm' name='pc-i440fx-2.9' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='isapc' hotplugCpus='yes' maxCpus='1' defaultCPU='486-x86_64-cpu'/> - <machine type='kvm' name='pc-i440fx-1.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-3.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.12' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-1.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-4.0.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-1.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-5.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.8' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.10' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-3.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-4.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='microvm' maxCpus='288' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='kvm' name='pc-i440fx-2.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-1.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-4.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-5.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-2.8' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-i440fx-3.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='kvm' name='pc-q35-2.11' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> + <machine type='kvm' name='pc-i440fx-5.2' alias='pc' hotplugCpus='yes' maxCpus='255' default='yes' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-5.2' alias='q35' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.12' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-4.2' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-4.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-1.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-1.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.10' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-1.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-5.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.9' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.11' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-3.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-4.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-1.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-4.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-5.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.9' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='isapc' hotplugCpus='yes' maxCpus='1' defaultCPU='486-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-1.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-3.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.12' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-1.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-4.0.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-1.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-5.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.8' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.10' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-3.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-4.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='microvm' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='microvm.ram'/> + <machine type='kvm' name='pc-i440fx-2.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-1.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-4.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-5.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-2.8' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-i440fx-3.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='kvm' name='pc-q35-2.11' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> <hostCPU type='tcg' model='base' migratability='yes'> <property name='vmx-entry-load-rtit-ctl' type='boolean' value='false'/> <property name='cmov' type='boolean' value='true' migratable='yes'/> @@ -3142,53 +3142,53 @@ </cpu> <cpu type='tcg' name='486-v1' typename='486-v1-x86_64-cpu' usable='yes'/> <cpu type='tcg' name='486' typename='486-x86_64-cpu' usable='yes'/> - <machine type='tcg' name='pc-i440fx-5.2' alias='pc' hotplugCpus='yes' maxCpus='255' default='yes' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='tcg' name='pc-q35-5.2' alias='q35' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='tcg' name='pc-i440fx-2.12' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-4.2' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-4.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-1.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-1.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.10' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-1.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-5.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='tcg' name='pc-q35-2.9' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.11' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-3.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-4.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-1.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-4.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-5.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='tcg' name='pc-i440fx-2.9' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='isapc' hotplugCpus='yes' maxCpus='1' defaultCPU='486-x86_64-cpu'/> - <machine type='tcg' name='pc-i440fx-1.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-3.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.12' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-1.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-4.0.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-1.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-5.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.8' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.10' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-3.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-4.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='microvm' maxCpus='288' defaultCPU='qemu64-x86_64-cpu'/> - <machine type='tcg' name='pc-i440fx-2.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-1.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-4.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-5.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-2.8' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-i440fx-3.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> - <machine type='tcg' name='pc-q35-2.11' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes'/> + <machine type='tcg' name='pc-i440fx-5.2' alias='pc' hotplugCpus='yes' maxCpus='255' default='yes' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-5.2' alias='q35' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.12' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-4.2' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-4.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-1.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-1.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.10' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-1.7' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-5.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.9' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.11' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-3.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-4.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-1.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-4.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-5.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.9' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='isapc' hotplugCpus='yes' maxCpus='1' defaultCPU='486-x86_64-cpu' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-1.4' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-3.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.12' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.1' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-1.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-4.0.1' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-1.6' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-5.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.8' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.10' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-3.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-4.0' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='microvm' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' defaultRAMid='microvm.ram'/> + <machine type='tcg' name='pc-i440fx-2.3' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-1.2' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-4.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-5.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-2.8' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.5' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-i440fx-3.0' hotplugCpus='yes' maxCpus='255' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> + <machine type='tcg' name='pc-q35-2.11' hotplugCpus='yes' maxCpus='288' defaultCPU='qemu64-x86_64-cpu' numaMemSupported='yes' defaultRAMid='pc.ram'/> </qemuCaps> diff --git a/tests/testutilsqemu.c b/tests/testutilsqemu.c index 51ac59bade..036a7f270a 100644 --- a/tests/testutilsqemu.c +++ b/tests/testutilsqemu.c @@ -99,6 +99,15 @@ static const char *const *kvm_machines[VIR_ARCH_LAST] = { [VIR_ARCH_S390X] = s390x_machines, }; +static const char *qemu_default_ram_id[VIR_ARCH_LAST] = { + [VIR_ARCH_I686] = "pc.ram", + [VIR_ARCH_X86_64] = "pc.ram", + [VIR_ARCH_AARCH64] = "mach-virt.ram", + [VIR_ARCH_ARMV7L] = "vexpress.highmem", + [VIR_ARCH_PPC64] = "ppc_spapr.ram", + [VIR_ARCH_PPC] = "ppc_spapr.ram", + [VIR_ARCH_S390X] = "s390.ram" +}; char * virFindFileInPath(const char *file) @@ -342,7 +351,8 @@ int qemuTestCapsCacheInsert(virFileCachePtr cache, 0, false, false, - true); + true, + qemu_default_ram_id[i]); virQEMUCapsSet(tmpCaps, QEMU_CAPS_TCG); } for (j = 0; kvm_machines[i][j] != NULL; j++) { @@ -354,7 +364,8 @@ int qemuTestCapsCacheInsert(virFileCachePtr cache, 0, false, false, - true); + true, + qemu_default_ram_id[i]); virQEMUCapsSet(tmpCaps, QEMU_CAPS_KVM); } } -- 2.26.2

On a Tuesday in 2020, Michal Privoznik wrote:
The machine structure has another (optional) attribute: default-ram-id, which specifies the alias of the default RAM object. While the alias is private, it can never change in order to not break migration. QEMU uses the alias when allocating regular, not NUMA memory. In order to switch to new command line and maintain migration, save this ID.
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_capabilities.c | 35 +++- src/qemu/qemu_capabilities.h | 3 + src/qemu/qemu_capspriv.h | 3 +- src/qemu/qemu_monitor.c | 1 + src/qemu/qemu_monitor.h | 1 + src/qemu/qemu_monitor_json.c | 11 + .../caps_5.2.0.x86_64.xml | 196 +++++++++--------- tests/testutilsqemu.c | 15 +- 8 files changed, 161 insertions(+), 104 deletions(-)
Reviewed-by: Ján Tomko <jtomko@redhat.com> Jano

So far, Libvirt configures memory-backend-* for memory hotplug, possibly NUMA nodes and in a few other cases. This patch switches to constructing the memory-backend-* command line for all cases. To keep ability to migrate guests a little hack is used: the ID of the object is set to the one that QEMU uses internally anyways. These IDs are stable (first started to appear somewhere around v0.13.0-rc0~96) and can't change. In fact, this patch does exactly what QEMU does internally. The reason for moving the logic into Libvirt is that QEMU wants to deprecate the old style of specifying memory. So far, only x84_64 test cases are changed, because tests for other architectures use older capabilities, which still lack the QEMU_CAPS_MACHINE_MEMORY_BACKEND capability and they don't report the RAM ID. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1836043 Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 69 ++++++++++++++++--- .../blkdeviotune-group-num.x86_64-latest.args | 3 +- ...blkdeviotune-max-length.x86_64-latest.args | 3 +- .../blkdeviotune-max.x86_64-latest.args | 3 +- .../channel-unix-guestfwd.x86_64-latest.args | 3 +- .../console-virtio-unix.x86_64-latest.args | 3 +- .../controller-virtio-scsi.x86_64-latest.args | 3 +- ...-Icelake-Server-pconfig.x86_64-latest.args | 3 +- .../cpu-translation.x86_64-latest.args | 3 +- .../cputune-cpuset-big-id.x86_64-latest.args | 3 +- .../disk-aio-io_uring.x86_64-latest.args | 3 +- .../disk-aio.x86_64-latest.args | 3 +- ...-backing-chains-noindex.x86_64-latest.args | 3 +- .../disk-cache.x86_64-latest.args | 4 +- .../disk-cdrom-bus-other.x86_64-latest.args | 3 +- ...m-empty-network-invalid.x86_64-latest.args | 3 +- .../disk-cdrom-network.x86_64-latest.args | 3 +- .../disk-cdrom-tray.x86_64-latest.args | 3 +- .../disk-cdrom.x86_64-latest.args | 3 +- .../disk-copy_on_read.x86_64-latest.args | 3 +- .../disk-detect-zeroes.x86_64-latest.args | 3 +- .../disk-discard.x86_64-latest.args | 3 +- .../disk-error-policy.x86_64-latest.args | 3 +- .../disk-floppy-q35-2_11.x86_64-latest.args | 4 +- .../disk-floppy-q35-2_9.x86_64-latest.args | 4 +- .../disk-floppy.x86_64-latest.args | 3 +- .../disk-network-gluster.x86_64-latest.args | 3 +- .../disk-network-http.x86_64-latest.args | 3 +- .../disk-network-iscsi.x86_64-latest.args | 3 +- .../disk-network-nbd.x86_64-latest.args | 3 +- .../disk-network-rbd.x86_64-latest.args | 3 +- .../disk-network-sheepdog.x86_64-latest.args | 3 +- ...isk-network-source-auth.x86_64-latest.args | 3 +- ...isk-network-tlsx509-nbd.x86_64-latest.args | 3 +- .../disk-nvme.x86_64-latest.args | 3 +- .../disk-readonly-disk.x86_64-latest.args | 3 +- .../disk-scsi-device-auto.x86_64-latest.args | 3 +- .../disk-scsi.x86_64-latest.args | 3 +- .../disk-shared.x86_64-latest.args | 3 +- .../disk-slices.x86_64-latest.args | 3 +- ...irtio-scsi-reservations.x86_64-latest.args | 3 +- .../eoi-disabled.x86_64-latest.args | 3 +- .../eoi-enabled.x86_64-latest.args | 3 +- .../floppy-drive-fat.x86_64-latest.args | 3 +- .../qemuxml2argvdata/fs9p.x86_64-latest.args | 3 +- .../genid-auto.x86_64-latest.args | 3 +- .../qemuxml2argvdata/genid.x86_64-latest.args | 3 +- ...egl-headless-rendernode.x86_64-latest.args | 3 +- .../graphics-egl-headless.x86_64-latest.args | 3 +- ...pice-gl-auto-rendernode.x86_64-latest.args | 3 +- ...graphics-vnc-tls-secret.x86_64-latest.args | 3 +- .../graphics-vnc-tls.x86_64-latest.args | 3 +- ...tdev-mdev-display-ramfb.x86_64-latest.args | 3 +- ...play-spice-egl-headless.x86_64-latest.args | 3 +- ...ev-display-spice-opengl.x86_64-latest.args | 3 +- ...isplay-vnc-egl-headless.x86_64-latest.args | 3 +- ...ostdev-mdev-display-vnc.x86_64-latest.args | 3 +- .../hostdev-scsi-lsi.x86_64-latest.args | 3 +- ...ostdev-scsi-virtio-scsi.x86_64-latest.args | 3 +- .../hugepages-nvdimm.x86_64-latest.args | 6 +- .../hyperv-off.x86_64-latest.args | 3 +- .../hyperv-panic.x86_64-latest.args | 3 +- .../hyperv-stimer-direct.x86_64-latest.args | 3 +- .../hyperv.x86_64-latest.args | 3 +- .../intel-iommu-aw-bits.x86_64-latest.args | 4 +- ...ntel-iommu-caching-mode.x86_64-latest.args | 4 +- ...ntel-iommu-device-iotlb.x86_64-latest.args | 4 +- .../intel-iommu-eim.x86_64-latest.args | 4 +- .../intel-iommu.x86_64-latest.args | 3 +- ...threads-virtio-scsi-pci.x86_64-latest.args | 3 +- .../kvmclock+eoi-disabled.x86_64-latest.args | 3 +- ...luks-disks-source-qcow2.x86_64-latest.args | 4 +- ...memory-default-hugepage.x86_64-latest.args | 8 ++- .../memfd-memory-numa.x86_64-latest.args | 8 ++- ...y-hotplug-nvdimm-access.x86_64-latest.args | 4 +- ...ry-hotplug-nvdimm-align.x86_64-latest.args | 4 +- ...ry-hotplug-nvdimm-label.x86_64-latest.args | 4 +- ...ory-hotplug-nvdimm-pmem.x86_64-latest.args | 4 +- ...hotplug-nvdimm-readonly.x86_64-latest.args | 4 +- .../memory-hotplug-nvdimm.x86_64-latest.args | 4 +- .../mlock-off.x86_64-latest.args | 3 +- .../mlock-on.x86_64-latest.args | 3 +- .../net-vhostuser.x86_64-latest.args | 3 +- .../numatune-hmat.x86_64-latest.args | 4 +- .../os-firmware-bios.x86_64-latest.args | 4 +- ...os-firmware-efi-secboot.x86_64-latest.args | 4 +- .../os-firmware-efi.x86_64-latest.args | 4 +- .../parallel-unix-chardev.x86_64-latest.args | 3 +- ...cie-root-port-nohotplug.x86_64-latest.args | 3 +- .../pv-spinlock-disabled.x86_64-latest.args | 3 +- .../pv-spinlock-enabled.x86_64-latest.args | 3 +- .../qemu-ns.x86_64-latest.args | 3 +- .../serial-unix-chardev.x86_64-latest.args | 3 +- ...rtcard-passthrough-unix.x86_64-latest.args | 3 +- .../tpm-emulator-tpm2-enc.x86_64-latest.args | 4 +- .../tpm-emulator-tpm2.x86_64-latest.args | 4 +- .../tpm-emulator.x86_64-latest.args | 4 +- .../tpm-passthrough-crb.x86_64-latest.args | 4 +- .../tpm-passthrough.x86_64-latest.args | 4 +- .../tseg-explicit-size.x86_64-latest.args | 4 +- .../usb-redir-unix.x86_64-latest.args | 3 +- ...vhost-user-fs-fd-memory.x86_64-latest.args | 4 +- ...vhost-user-fs-hugepages.x86_64-latest.args | 5 +- ...host-user-gpu-secondary.x86_64-latest.args | 3 +- .../vhost-user-vga.x86_64-latest.args | 3 +- .../vhost-vsock-auto.x86_64-latest.args | 4 +- .../vhost-vsock.x86_64-latest.args | 3 +- ...eo-bochs-display-device.x86_64-latest.args | 3 +- ...video-qxl-device-vram64.x86_64-latest.args | 3 +- ...o-qxl-sec-device-vram64.x86_64-latest.args | 3 +- ...eo-ramfb-display-device.x86_64-latest.args | 3 +- .../virtio-9p-multidevs.x86_64-latest.args | 3 +- ...virtio-non-transitional.x86_64-latest.args | 3 +- ...-options-controller-ats.x86_64-latest.args | 3 +- ...ptions-controller-iommu.x86_64-latest.args | 3 +- ...tions-controller-packed.x86_64-latest.args | 3 +- ...virtio-options-disk-ats.x86_64-latest.args | 3 +- ...rtio-options-disk-iommu.x86_64-latest.args | 3 +- ...tio-options-disk-packed.x86_64-latest.args | 3 +- .../virtio-options-fs-ats.x86_64-latest.args | 3 +- ...virtio-options-fs-iommu.x86_64-latest.args | 3 +- ...irtio-options-fs-packed.x86_64-latest.args | 3 +- ...irtio-options-input-ats.x86_64-latest.args | 3 +- ...tio-options-input-iommu.x86_64-latest.args | 3 +- ...io-options-input-packed.x86_64-latest.args | 3 +- ...-options-memballoon-ats.x86_64-latest.args | 3 +- ...ptions-memballoon-iommu.x86_64-latest.args | 3 +- ...tions-memballoon-packed.x86_64-latest.args | 3 +- .../virtio-options-net-ats.x86_64-latest.args | 3 +- ...irtio-options-net-iommu.x86_64-latest.args | 3 +- ...rtio-options-net-packed.x86_64-latest.args | 3 +- .../virtio-options-rng-ats.x86_64-latest.args | 3 +- ...irtio-options-rng-iommu.x86_64-latest.args | 3 +- ...rtio-options-rng-packed.x86_64-latest.args | 3 +- ...irtio-options-video-ats.x86_64-latest.args | 3 +- ...tio-options-video-iommu.x86_64-latest.args | 3 +- ...io-options-video-packed.x86_64-latest.args | 3 +- .../virtio-options.x86_64-latest.args | 3 +- .../virtio-rng-builtin.x86_64-latest.args | 3 +- .../virtio-rng-egd-unix.x86_64-latest.args | 3 +- .../virtio-transitional.x86_64-latest.args | 3 +- ...-default-cpu-kvm-pc-4.2.x86_64-latest.args | 4 +- ...default-cpu-kvm-q35-4.2.x86_64-latest.args | 4 +- ...-default-cpu-tcg-pc-4.2.x86_64-latest.args | 4 +- ...default-cpu-tcg-q35-4.2.x86_64-latest.args | 4 +- .../x86_64-pc-graphics.x86_64-latest.args | 3 +- .../x86_64-pc-headless.x86_64-latest.args | 3 +- .../x86_64-q35-graphics.x86_64-latest.args | 3 +- .../x86_64-q35-headless.x86_64-latest.args | 3 +- 149 files changed, 395 insertions(+), 163 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index ecbdd226a4..b62dc78893 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -7015,6 +7015,14 @@ qemuBuildMachineCommandLine(virCommandPtr cmd, if (virDomainNumaHasHMAT(def->numa)) virBufferAddLit(&buf, ",hmat=on"); + if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_MACHINE_MEMORY_BACKEND)) { + const char *defaultRAMid = virQEMUCapsGetMachineDefaultRAMid(qemuCaps, + def->virtType, + def->os.machine); + if (defaultRAMid) + virBufferAsprintf(&buf, ",memory-backend=%s", defaultRAMid); + } + virCommandAddArgBuffer(cmd, &buf); return 0; @@ -7124,12 +7132,42 @@ qemuBuildMemPathStr(const virDomainDef *def, } +static int +qemuBuildMemCommandLineMemoryBackendNew(virCommandPtr cmd, + const virDomainDef *def, + qemuDomainObjPrivatePtr priv, + const char *defaultRAMid) +{ + g_autoptr(virQEMUDriverConfig) cfg = virQEMUDriverGetConfig(priv->driver); + g_autoptr(virJSONValue) props = NULL; + g_auto(virBuffer) buf = VIR_BUFFER_INITIALIZER; + virDomainMemoryDef mem = { 0 }; + + mem.size = virDomainDefGetMemoryInitial(def); + mem.targetNode = -1; + mem.info.alias = (char *) defaultRAMid; + + if (qemuBuildMemoryBackendProps(&props, defaultRAMid, cfg, + priv, def, &mem, false) < 0) + return -1; + + if (virQEMUBuildObjectCommandlineFromJSON(&buf, props) < 0) + return -1; + + virCommandAddArg(cmd, "-object"); + virCommandAddArgBuffer(cmd, &buf); + return 0; +} + + static int qemuBuildMemCommandLine(virCommandPtr cmd, const virDomainDef *def, virQEMUCapsPtr qemuCaps, qemuDomainObjPrivatePtr priv) { + const char *defaultRAMid = NULL; + virCommandAddArg(cmd, "-m"); if (virDomainDefHasMemoryHotplug(def)) { @@ -7144,19 +7182,28 @@ qemuBuildMemCommandLine(virCommandPtr cmd, virDomainDefGetMemoryInitial(def) / 1024); } - if (def->mem.allocation == VIR_DOMAIN_MEMORY_ALLOCATION_IMMEDIATE) { - virCommandAddArgList(cmd, "-mem-prealloc", NULL); - priv->memPrealloc = true; + defaultRAMid = virQEMUCapsGetMachineDefaultRAMid(qemuCaps, + def->virtType, + def->os.machine); + + if (defaultRAMid && + virQEMUCapsGet(qemuCaps, QEMU_CAPS_MACHINE_MEMORY_BACKEND)) { + qemuBuildMemCommandLineMemoryBackendNew(cmd, def, priv, defaultRAMid); + } else { + if (def->mem.allocation == VIR_DOMAIN_MEMORY_ALLOCATION_IMMEDIATE) { + virCommandAddArgList(cmd, "-mem-prealloc", NULL); + priv->memPrealloc = true; + } + + /* + * Add '-mem-path' (and '-mem-prealloc') parameter here if + * the hugepages and no numa node is specified. + */ + if (!virDomainNumaGetNodeCount(def->numa) && + qemuBuildMemPathStr(def, cmd, priv) < 0) + return -1; } - /* - * Add '-mem-path' (and '-mem-prealloc') parameter here if - * the hugepages and no numa node is specified. - */ - if (!virDomainNumaGetNodeCount(def->numa) && - qemuBuildMemPathStr(def, cmd, priv) < 0) - return -1; - if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_OVERCOMMIT)) { virCommandAddArg(cmd, "-overcommit"); virCommandAddArgFormat(cmd, "mem-lock=%s", def->mem.locked ? "on" : "off"); diff --git a/tests/qemuxml2argvdata/blkdeviotune-group-num.x86_64-latest.args b/tests/qemuxml2argvdata/blkdeviotune-group-num.x86_64-latest.args index fe8a845aae..79012e5b60 100644 --- a/tests/qemuxml2argvdata/blkdeviotune-group-num.x86_64-latest.args +++ b/tests/qemuxml2argvdata/blkdeviotune-group-num.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/blkdeviotune-max-length.x86_64-latest.args b/tests/qemuxml2argvdata/blkdeviotune-max-length.x86_64-latest.args index fe8a845aae..79012e5b60 100644 --- a/tests/qemuxml2argvdata/blkdeviotune-max-length.x86_64-latest.args +++ b/tests/qemuxml2argvdata/blkdeviotune-max-length.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/blkdeviotune-max.x86_64-latest.args b/tests/qemuxml2argvdata/blkdeviotune-max.x86_64-latest.args index fe8a845aae..79012e5b60 100644 --- a/tests/qemuxml2argvdata/blkdeviotune-max.x86_64-latest.args +++ b/tests/qemuxml2argvdata/blkdeviotune-max.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/channel-unix-guestfwd.x86_64-latest.args b/tests/qemuxml2argvdata/channel-unix-guestfwd.x86_64-latest.args index 95ac94ab7d..f500bfe2ae 100644 --- a/tests/qemuxml2argvdata/channel-unix-guestfwd.x86_64-latest.args +++ b/tests/qemuxml2argvdata/channel-unix-guestfwd.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/console-virtio-unix.x86_64-latest.args b/tests/qemuxml2argvdata/console-virtio-unix.x86_64-latest.args index dbad074eb3..5e64598959 100644 --- a/tests/qemuxml2argvdata/console-virtio-unix.x86_64-latest.args +++ b/tests/qemuxml2argvdata/console-virtio-unix.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args b/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args index 454da17e2c..1d7583b981 100644 --- a/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/controller-virtio-scsi.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 8,sockets=8,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/cpu-Icelake-Server-pconfig.x86_64-latest.args b/tests/qemuxml2argvdata/cpu-Icelake-Server-pconfig.x86_64-latest.args index 88d05a482a..a512623af6 100644 --- a/tests/qemuxml2argvdata/cpu-Icelake-Server-pconfig.x86_64-latest.args +++ b/tests/qemuxml2argvdata/cpu-Icelake-Server-pconfig.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-test/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu Icelake-Server \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args b/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args index 9322b826f4..84c0d05b34 100644 --- a/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args +++ b/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args @@ -12,11 +12,12 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu Haswell,pclmulqdq=on,ds-cpl=on,tsc-adjust=on,fxsr-opt=on,lahf-lm=on,\ cmp-legacy=on,nodeid-msr=on,perfctr-core=on,perfctr-nb=on,kvm-pv-eoi=on,\ kvm-pv-unhalt=on \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-fade-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/cputune-cpuset-big-id.x86_64-latest.args b/tests/qemuxml2argvdata/cputune-cpuset-big-id.x86_64-latest.args index b086ebe776..0ec8ba038d 100644 --- a/tests/qemuxml2argvdata/cputune-cpuset-big-id.x86_64-latest.args +++ b/tests/qemuxml2argvdata/cputune-cpuset-big-id.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-aio-io_uring.x86_64-latest.args b/tests/qemuxml2argvdata/disk-aio-io_uring.x86_64-latest.args index 8596639f60..69c8742e95 100644 --- a/tests/qemuxml2argvdata/disk-aio-io_uring.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-aio-io_uring.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args b/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args index 487018cf3e..6f9b81071a 100644 --- a/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-aio.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args b/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args index 6e01f55577..0f6d70a855 100644 --- a/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-backing-chains-noindex.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args index 931e344028..e66abd9d4f 100644 --- a/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cache.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc-i440fx-1.5,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-1.5,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-cdrom-bus-other.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom-bus-other.x86_64-latest.args index be091f150f..a77a851941 100644 --- a/tests/qemuxml2argvdata/disk-cdrom-bus-other.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom-bus-other.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-cdrom-empty-network-invalid.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom-empty-network-invalid.x86_64-latest.args index 81f250600e..94ffa9f9e4 100644 --- a/tests/qemuxml2argvdata/disk-cdrom-empty-network-invalid.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom-empty-network-invalid.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args index 1a102949df..3c4f3993f6 100644 --- a/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom-network.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc-1.2,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-1.2,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args index 3e56168acb..4e4e0aa62a 100644 --- a/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom-tray.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-test/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 3fa02811-7832-34bd-004d-1ff56a9286ff \ diff --git a/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args b/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args index 9c8097c4a6..0d375ffd1c 100644 --- a/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-cdrom.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args b/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args index 701038404d..493b478cf8 100644 --- a/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-copy_on_read.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-test/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 468404ad-d49c-40f2-9e14-02294f9c1be3 \ diff --git a/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args b/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args index 8e8d92a6f7..97cc49225f 100644 --- a/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-detect-zeroes.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-test/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 92d7a226-cfae-425b-a6d3-00bbf9ec5c9e \ diff --git a/tests/qemuxml2argvdata/disk-discard.x86_64-latest.args b/tests/qemuxml2argvdata/disk-discard.x86_64-latest.args index 408124dc95..1aa06c7469 100644 --- a/tests/qemuxml2argvdata/disk-discard.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-discard.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-test/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 92d7a226-cfae-425b-a6d3-00bbf9ec5c9e \ diff --git a/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args b/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args index e8f5ea10df..c0079efc0a 100644 --- a/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-error-policy.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args b/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args index a624998480..7e35f6a6cd 100644 --- a/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-floppy-q35-2_11.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc-q35-2.11,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-q35-2.11,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args b/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args index ec3210cdc8..47ef5db354 100644 --- a/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-floppy-q35-2_9.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc-q35-2.9,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-q35-2.9,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args b/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args index fbca6c90ec..96756502df 100644 --- a/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-floppy.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args index 4e68f1b628..1e992fb6d0 100644 --- a/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-gluster.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-http.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-http.x86_64-latest.args index 814f747dad..954f1824dd 100644 --- a/tests/qemuxml2argvdata/disk-network-http.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-http.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args index 9848128092..ab60fc5f4a 100644 --- a/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-iscsi.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args index 8c9bbed130..5e5c23656a 100644 --- a/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-nbd.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args index 29409df722..e91f009d35 100644 --- a/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-rbd.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args index a5e197f45b..4418906dc7 100644 --- a/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-sheepdog.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args index 0ad49ab0fd..257ca1376c 100644 --- a/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-source-auth.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-network-tlsx509-nbd.x86_64-latest.args b/tests/qemuxml2argvdata/disk-network-tlsx509-nbd.x86_64-latest.args index b44832b5e5..8ec4a8ab22 100644 --- a/tests/qemuxml2argvdata/disk-network-tlsx509-nbd.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-network-tlsx509-nbd.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-nvme.x86_64-latest.args b/tests/qemuxml2argvdata/disk-nvme.x86_64-latest.args index a0b5c5950c..3146ad1251 100644 --- a/tests/qemuxml2argvdata/disk-nvme.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-nvme.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args b/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args index f67ebf0069..7a83ac4afe 100644 --- a/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-readonly-disk.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args b/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args index 634d929a01..354686c5fa 100644 --- a/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-scsi-device-auto.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args b/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args index 489f53d80e..da4ef333c0 100644 --- a/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-scsi.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args b/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args index 4bae8ae5c9..4cae79c005 100644 --- a/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-shared.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-slices.x86_64-latest.args b/tests/qemuxml2argvdata/disk-slices.x86_64-latest.args index cd2f5847c4..c4e1384f4d 100644 --- a/tests/qemuxml2argvdata/disk-slices.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-slices.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args b/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args index bfd7a92530..a6e6c12d65 100644 --- a/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args +++ b/tests/qemuxml2argvdata/disk-virtio-scsi-reservations.x86_64-latest.args @@ -14,9 +14,10 @@ QEMU_AUDIO_DRV=none \ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -object pr-manager-helper,id=pr-helper0,\ path=/tmp/lib/domain--1-QEMUGuest1/pr-helper0.sock \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 8,sockets=8,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/eoi-disabled.x86_64-latest.args b/tests/qemuxml2argvdata/eoi-disabled.x86_64-latest.args index c34f2e78c2..a2593d155a 100644 --- a/tests/qemuxml2argvdata/eoi-disabled.x86_64-latest.args +++ b/tests/qemuxml2argvdata/eoi-disabled.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64,kvm-pv-eoi=off \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/eoi-enabled.x86_64-latest.args b/tests/qemuxml2argvdata/eoi-enabled.x86_64-latest.args index 2ee3ef5031..d0befba30f 100644 --- a/tests/qemuxml2argvdata/eoi-enabled.x86_64-latest.args +++ b/tests/qemuxml2argvdata/eoi-enabled.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64,kvm-pv-eoi=on \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args b/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args index c47f2ea717..12f0b9cb64 100644 --- a/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args +++ b/tests/qemuxml2argvdata/floppy-drive-fat.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/fs9p.x86_64-latest.args b/tests/qemuxml2argvdata/fs9p.x86_64-latest.args index 700ae69203..e340218e1a 100644 --- a/tests/qemuxml2argvdata/fs9p.x86_64-latest.args +++ b/tests/qemuxml2argvdata/fs9p.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/genid-auto.x86_64-latest.args b/tests/qemuxml2argvdata/genid-auto.x86_64-latest.args index 7c39132ff8..8f08342a0b 100644 --- a/tests/qemuxml2argvdata/genid-auto.x86_64-latest.args +++ b/tests/qemuxml2argvdata/genid-auto.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/genid.x86_64-latest.args b/tests/qemuxml2argvdata/genid.x86_64-latest.args index 5bfb8db9f9..7dd7d1f616 100644 --- a/tests/qemuxml2argvdata/genid.x86_64-latest.args +++ b/tests/qemuxml2argvdata/genid.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args b/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args index 390a8d16b7..e6025557da 100644 --- a/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-egl-headless-rendernode.x86_64-latest.args @@ -11,9 +11,10 @@ XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args b/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args index 390a8d16b7..e6025557da 100644 --- a/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-egl-headless.x86_64-latest.args @@ -11,9 +11,10 @@ XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/graphics-spice-gl-auto-rendernode.x86_64-latest.args b/tests/qemuxml2argvdata/graphics-spice-gl-auto-rendernode.x86_64-latest.args index c0d08964d6..9329e56b12 100644 --- a/tests/qemuxml2argvdata/graphics-spice-gl-auto-rendernode.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-spice-gl-auto-rendernode.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=spice \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls-secret.x86_64-latest.args b/tests/qemuxml2argvdata/graphics-vnc-tls-secret.x86_64-latest.args index 5a73408bf9..b3251fbed4 100644 --- a/tests/qemuxml2argvdata/graphics-vnc-tls-secret.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-vnc-tls-secret.x86_64-latest.args @@ -13,9 +13,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args b/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args index f435b9a152..cea42c4d1b 100644 --- a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args @@ -13,9 +13,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hostdev-mdev-display-ramfb.x86_64-latest.args b/tests/qemuxml2argvdata/hostdev-mdev-display-ramfb.x86_64-latest.args index bb12d314b9..f1a3026474 100644 --- a/tests/qemuxml2argvdata/hostdev-mdev-display-ramfb.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hostdev-mdev-display-ramfb.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest2/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hostdev-mdev-display-spice-egl-headless.x86_64-latest.args b/tests/qemuxml2argvdata/hostdev-mdev-display-spice-egl-headless.x86_64-latest.args index 090b644abb..580cbd9489 100644 --- a/tests/qemuxml2argvdata/hostdev-mdev-display-spice-egl-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hostdev-mdev-display-spice-egl-headless.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=spice \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest2/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hostdev-mdev-display-spice-opengl.x86_64-latest.args b/tests/qemuxml2argvdata/hostdev-mdev-display-spice-opengl.x86_64-latest.args index 201ccccc7f..345bddfc43 100644 --- a/tests/qemuxml2argvdata/hostdev-mdev-display-spice-opengl.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hostdev-mdev-display-spice-opengl.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=spice \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest2/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hostdev-mdev-display-vnc-egl-headless.x86_64-latest.args b/tests/qemuxml2argvdata/hostdev-mdev-display-vnc-egl-headless.x86_64-latest.args index 0809fdce45..cef437a228 100644 --- a/tests/qemuxml2argvdata/hostdev-mdev-display-vnc-egl-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hostdev-mdev-display-vnc-egl-headless.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest2/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hostdev-mdev-display-vnc.x86_64-latest.args b/tests/qemuxml2argvdata/hostdev-mdev-display-vnc.x86_64-latest.args index 58a7549935..68c28fc41e 100644 --- a/tests/qemuxml2argvdata/hostdev-mdev-display-vnc.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hostdev-mdev-display-vnc.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest2/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hostdev-scsi-lsi.x86_64-latest.args b/tests/qemuxml2argvdata/hostdev-scsi-lsi.x86_64-latest.args index d4599f6002..de4e02fb55 100644 --- a/tests/qemuxml2argvdata/hostdev-scsi-lsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hostdev-scsi-lsi.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest2/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9466-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hostdev-scsi-virtio-scsi.x86_64-latest.args b/tests/qemuxml2argvdata/hostdev-scsi-virtio-scsi.x86_64-latest.args index f86cbd7314..6bfbbadb9d 100644 --- a/tests/qemuxml2argvdata/hostdev-scsi-virtio-scsi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hostdev-scsi-virtio-scsi.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest2/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9466-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args b/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args index 969bb713b5..192b033e9e 100644 --- a/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hugepages-nvdimm.x86_64-latest.args @@ -12,9 +12,13 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m size=1048576k,slots=16,maxmem=1099511627776k \ +-object memory-backend-file,id=pc.ram,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-QEMUGuest1,share=yes,prealloc=yes,\ +size=1073741824 \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-file,id=ram-node0,\ diff --git a/tests/qemuxml2argvdata/hyperv-off.x86_64-latest.args b/tests/qemuxml2argvdata/hyperv-off.x86_64-latest.args index ea3fc775bb..ce7af1bd3a 100644 --- a/tests/qemuxml2argvdata/hyperv-off.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hyperv-off.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hyperv-panic.x86_64-latest.args b/tests/qemuxml2argvdata/hyperv-panic.x86_64-latest.args index 41527208ab..870fa38d82 100644 --- a/tests/qemuxml2argvdata/hyperv-panic.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hyperv-panic.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64,hv-crash \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hyperv-stimer-direct.x86_64-latest.args b/tests/qemuxml2argvdata/hyperv-stimer-direct.x86_64-latest.args index bdcf33c1bf..f64bad579d 100644 --- a/tests/qemuxml2argvdata/hyperv-stimer-direct.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hyperv-stimer-direct.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64,hv-vpindex,hv-synic,hv-stimer,hv-stimer-direct \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/hyperv.x86_64-latest.args b/tests/qemuxml2argvdata/hyperv.x86_64-latest.args index 7382553860..c6cba06981 100644 --- a/tests/qemuxml2argvdata/hyperv.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hyperv.x86_64-latest.args @@ -12,11 +12,12 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu 'qemu64,hv-relaxed,hv-vapic,hv-spinlocks=0x2fff,hv-vpindex,hv-runtime,\ hv-synic,hv-stimer,hv-reset,hv-vendor-id=KVM Hv,hv-frequencies,\ hv-reenlightenment,hv-tlbflush,hv-ipi,hv-evmcs' \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/intel-iommu-aw-bits.x86_64-latest.args b/tests/qemuxml2argvdata/intel-iommu-aw-bits.x86_64-latest.args index 0ce0952b51..211ea3d572 100644 --- a/tests/qemuxml2argvdata/intel-iommu-aw-bits.x86_64-latest.args +++ b/tests/qemuxml2argvdata/intel-iommu-aw-bits.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split \ +-machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/intel-iommu-caching-mode.x86_64-latest.args b/tests/qemuxml2argvdata/intel-iommu-caching-mode.x86_64-latest.args index c232121595..cea414a7f5 100644 --- a/tests/qemuxml2argvdata/intel-iommu-caching-mode.x86_64-latest.args +++ b/tests/qemuxml2argvdata/intel-iommu-caching-mode.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split \ +-machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/intel-iommu-device-iotlb.x86_64-latest.args b/tests/qemuxml2argvdata/intel-iommu-device-iotlb.x86_64-latest.args index addb45a0b3..ef2fa61db8 100644 --- a/tests/qemuxml2argvdata/intel-iommu-device-iotlb.x86_64-latest.args +++ b/tests/qemuxml2argvdata/intel-iommu-device-iotlb.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split \ +-machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/intel-iommu-eim.x86_64-latest.args b/tests/qemuxml2argvdata/intel-iommu-eim.x86_64-latest.args index 98650baaaa..43e666d14f 100644 --- a/tests/qemuxml2argvdata/intel-iommu-eim.x86_64-latest.args +++ b/tests/qemuxml2argvdata/intel-iommu-eim.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split \ +-machine q35,accel=kvm,usb=off,dump-guest-core=off,kernel_irqchip=split,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 288,sockets=288,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/intel-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/intel-iommu.x86_64-latest.args index 92d25f6d41..5fe3ed0c26 100644 --- a/tests/qemuxml2argvdata/intel-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/intel-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine q35,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args b/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args index d00867a09b..a2f4d5e609 100644 --- a/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args +++ b/tests/qemuxml2argvdata/iothreads-virtio-scsi-pci.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -object iothread,id=iothread1 \ diff --git a/tests/qemuxml2argvdata/kvmclock+eoi-disabled.x86_64-latest.args b/tests/qemuxml2argvdata/kvmclock+eoi-disabled.x86_64-latest.args index c4cd5f5beb..8842d2a448 100644 --- a/tests/qemuxml2argvdata/kvmclock+eoi-disabled.x86_64-latest.args +++ b/tests/qemuxml2argvdata/kvmclock+eoi-disabled.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64,kvmclock=off,kvm-pv-eoi=off \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/luks-disks-source-qcow2.x86_64-latest.args b/tests/qemuxml2argvdata/luks-disks-source-qcow2.x86_64-latest.args index 3ce9f81006..6e469d1953 100644 --- a/tests/qemuxml2argvdata/luks-disks-source-qcow2.x86_64-latest.args +++ b/tests/qemuxml2argvdata/luks-disks-source-qcow2.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-encryptdisk/master-key.aes \ --machine pc-i440fx-2.1,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.1,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 496898a6-e6ff-f7c8-5dc2-3cf410945ee9 \ diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \ diff --git a/tests/qemuxml2argvdata/memfd-memory-numa.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-numa.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-numa.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-numa.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args index 8d3fa2e867..c5c5befdd5 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-access.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m size=219136k,slots=16,maxmem=1099511627776k \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args index 4f22f78277..418bf1158d 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-align.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m size=219136k,slots=16,maxmem=1099511627776k \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args index 53dda234a2..66477a2b09 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-label.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m size=219136k,slots=16,maxmem=1099511627776k \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args index cac02a6f6d..759d749c2e 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-pmem.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m size=219136k,slots=16,maxmem=1099511627776k \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args index 5e44496e39..b195b8625c 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm-readonly.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m size=219136k,slots=16,maxmem=1099511627776k \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=224395264 \ diff --git a/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args b/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args index 94f8444d95..ae416d7c7f 100644 --- a/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memory-hotplug-nvdimm.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,nvdimm=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m size=1048576k,slots=16,maxmem=1099511627776k \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 2,sockets=2,dies=1,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=1073741824 \ diff --git a/tests/qemuxml2argvdata/mlock-off.x86_64-latest.args b/tests/qemuxml2argvdata/mlock-off.x86_64-latest.args index 967fe4c826..2772c82ff6 100644 --- a/tests/qemuxml2argvdata/mlock-off.x86_64-latest.args +++ b/tests/qemuxml2argvdata/mlock-off.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/mlock-on.x86_64-latest.args b/tests/qemuxml2argvdata/mlock-on.x86_64-latest.args index 167214fd64..f77d866055 100644 --- a/tests/qemuxml2argvdata/mlock-on.x86_64-latest.args +++ b/tests/qemuxml2argvdata/mlock-on.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=on \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/net-vhostuser.x86_64-latest.args b/tests/qemuxml2argvdata/net-vhostuser.x86_64-latest.args index 27fa24a64f..d889d34168 100644 --- a/tests/qemuxml2argvdata/net-vhostuser.x86_64-latest.args +++ b/tests/qemuxml2argvdata/net-vhostuser.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/numatune-hmat.x86_64-latest.args b/tests/qemuxml2argvdata/numatune-hmat.x86_64-latest.args index c52015caa8..be4a9ed871 100644 --- a/tests/qemuxml2argvdata/numatune-hmat.x86_64-latest.args +++ b/tests/qemuxml2argvdata/numatune-hmat.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off,hmat=on \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,hmat=on,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 12288 \ +-object memory-backend-ram,id=pc.ram,size=12884901888 \ -overcommit mem-lock=off \ -smp 12,sockets=12,cores=1,threads=1 \ -object memory-backend-ram,id=ram-node0,size=2147483648 \ diff --git a/tests/qemuxml2argvdata/os-firmware-bios.x86_64-latest.args b/tests/qemuxml2argvdata/os-firmware-bios.x86_64-latest.args index 4391c6eda2..ab94f309df 100644 --- a/tests/qemuxml2argvdata/os-firmware-bios.x86_64-latest.args +++ b/tests/qemuxml2argvdata/os-firmware-bios.x86_64-latest.args @@ -12,10 +12,12 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-fedora/master-key.aes \ --machine pc-q35-4.0,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-q35-4.0,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -bios /usr/share/seabios/bios-256k.bin \ -m 8 \ +-object memory-backend-ram,id=pc.ram,size=8388608 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 63840878-0deb-4095-97e6-fc444d9bc9fa \ diff --git a/tests/qemuxml2argvdata/os-firmware-efi-secboot.x86_64-latest.args b/tests/qemuxml2argvdata/os-firmware-efi-secboot.x86_64-latest.args index f8af2100ea..1eb5aad17b 100644 --- a/tests/qemuxml2argvdata/os-firmware-efi-secboot.x86_64-latest.args +++ b/tests/qemuxml2argvdata/os-firmware-efi-secboot.x86_64-latest.args @@ -24,10 +24,12 @@ file=/tmp/lib/domain--1-fedora/master-key.aes \ -blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,\ "driver":"raw","file":"libvirt-pflash1-storage"}' \ -machine pc-q35-4.0,accel=kvm,usb=off,smm=on,dump-guest-core=off,\ -pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format \ +pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,\ +memory-backend=pc.ram \ -cpu qemu64 \ -global driver=cfi.pflash01,property=secure,value=on \ -m 8 \ +-object memory-backend-ram,id=pc.ram,size=8388608 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 63840878-0deb-4095-97e6-fc444d9bc9fa \ diff --git a/tests/qemuxml2argvdata/os-firmware-efi.x86_64-latest.args b/tests/qemuxml2argvdata/os-firmware-efi.x86_64-latest.args index a06213eb19..9b8cbc45b9 100644 --- a/tests/qemuxml2argvdata/os-firmware-efi.x86_64-latest.args +++ b/tests/qemuxml2argvdata/os-firmware-efi.x86_64-latest.args @@ -24,9 +24,11 @@ file=/tmp/lib/domain--1-fedora/master-key.aes \ -blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,\ "driver":"raw","file":"libvirt-pflash1-storage"}' \ -machine pc-q35-4.0,accel=kvm,usb=off,smm=on,dump-guest-core=off,\ -pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format \ +pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 8 \ +-object memory-backend-ram,id=pc.ram,size=8388608 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 63840878-0deb-4095-97e6-fc444d9bc9fa \ diff --git a/tests/qemuxml2argvdata/parallel-unix-chardev.x86_64-latest.args b/tests/qemuxml2argvdata/parallel-unix-chardev.x86_64-latest.args index b3383da9a7..ea333ef5f8 100644 --- a/tests/qemuxml2argvdata/parallel-unix-chardev.x86_64-latest.args +++ b/tests/qemuxml2argvdata/parallel-unix-chardev.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/pcie-root-port-nohotplug.x86_64-latest.args b/tests/qemuxml2argvdata/pcie-root-port-nohotplug.x86_64-latest.args index 0f81b31ad9..619b03a3eb 100644 --- a/tests/qemuxml2argvdata/pcie-root-port-nohotplug.x86_64-latest.args +++ b/tests/qemuxml2argvdata/pcie-root-port-nohotplug.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine q35,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 2048 \ +-object memory-backend-ram,id=pc.ram,size=2147483648 \ -overcommit mem-lock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -uuid 11dbdcdd-4c3b-482b-8903-9bdb8c0a2774 \ diff --git a/tests/qemuxml2argvdata/pv-spinlock-disabled.x86_64-latest.args b/tests/qemuxml2argvdata/pv-spinlock-disabled.x86_64-latest.args index eb449837bf..30f45b8a04 100644 --- a/tests/qemuxml2argvdata/pv-spinlock-disabled.x86_64-latest.args +++ b/tests/qemuxml2argvdata/pv-spinlock-disabled.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64,kvm-pv-unhalt=off \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/pv-spinlock-enabled.x86_64-latest.args b/tests/qemuxml2argvdata/pv-spinlock-enabled.x86_64-latest.args index af14fa05a9..beb0e5f2ef 100644 --- a/tests/qemuxml2argvdata/pv-spinlock-enabled.x86_64-latest.args +++ b/tests/qemuxml2argvdata/pv-spinlock-enabled.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64,kvm-pv-unhalt=on \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 6,sockets=6,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/qemu-ns.x86_64-latest.args b/tests/qemuxml2argvdata/qemu-ns.x86_64-latest.args index 7864f90402..aefe486298 100644 --- a/tests/qemuxml2argvdata/qemu-ns.x86_64-latest.args +++ b/tests/qemuxml2argvdata/qemu-ns.x86_64-latest.args @@ -14,9 +14,10 @@ BAR='' \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/serial-unix-chardev.x86_64-latest.args b/tests/qemuxml2argvdata/serial-unix-chardev.x86_64-latest.args index 05d42adda1..07b7aba42f 100644 --- a/tests/qemuxml2argvdata/serial-unix-chardev.x86_64-latest.args +++ b/tests/qemuxml2argvdata/serial-unix-chardev.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/smartcard-passthrough-unix.x86_64-latest.args b/tests/qemuxml2argvdata/smartcard-passthrough-unix.x86_64-latest.args index 4f1e3242ed..3e0262e49c 100644 --- a/tests/qemuxml2argvdata/smartcard-passthrough-unix.x86_64-latest.args +++ b/tests/qemuxml2argvdata/smartcard-passthrough-unix.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/tpm-emulator-tpm2-enc.x86_64-latest.args b/tests/qemuxml2argvdata/tpm-emulator-tpm2-enc.x86_64-latest.args index 2455e14cfe..90505c7a76 100644 --- a/tests/qemuxml2argvdata/tpm-emulator-tpm2-enc.x86_64-latest.args +++ b/tests/qemuxml2argvdata/tpm-emulator-tpm2-enc.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-TPM-VM/master-key.aes \ --machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 2048 \ +-object memory-backend-ram,id=pc.ram,size=2147483648 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 11d7cd22-da89-3094-6212-079a48a309a1 \ diff --git a/tests/qemuxml2argvdata/tpm-emulator-tpm2.x86_64-latest.args b/tests/qemuxml2argvdata/tpm-emulator-tpm2.x86_64-latest.args index 2455e14cfe..90505c7a76 100644 --- a/tests/qemuxml2argvdata/tpm-emulator-tpm2.x86_64-latest.args +++ b/tests/qemuxml2argvdata/tpm-emulator-tpm2.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-TPM-VM/master-key.aes \ --machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 2048 \ +-object memory-backend-ram,id=pc.ram,size=2147483648 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 11d7cd22-da89-3094-6212-079a48a309a1 \ diff --git a/tests/qemuxml2argvdata/tpm-emulator.x86_64-latest.args b/tests/qemuxml2argvdata/tpm-emulator.x86_64-latest.args index 2455e14cfe..90505c7a76 100644 --- a/tests/qemuxml2argvdata/tpm-emulator.x86_64-latest.args +++ b/tests/qemuxml2argvdata/tpm-emulator.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-TPM-VM/master-key.aes \ --machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 2048 \ +-object memory-backend-ram,id=pc.ram,size=2147483648 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 11d7cd22-da89-3094-6212-079a48a309a1 \ diff --git a/tests/qemuxml2argvdata/tpm-passthrough-crb.x86_64-latest.args b/tests/qemuxml2argvdata/tpm-passthrough-crb.x86_64-latest.args index 5508e4defb..911d0c660c 100644 --- a/tests/qemuxml2argvdata/tpm-passthrough-crb.x86_64-latest.args +++ b/tests/qemuxml2argvdata/tpm-passthrough-crb.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-TPM-VM/master-key.aes \ --machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 2048 \ +-object memory-backend-ram,id=pc.ram,size=2147483648 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 11d7cd22-da89-3094-6212-079a48a309a1 \ diff --git a/tests/qemuxml2argvdata/tpm-passthrough.x86_64-latest.args b/tests/qemuxml2argvdata/tpm-passthrough.x86_64-latest.args index 60edf86dbd..5da7d13a3d 100644 --- a/tests/qemuxml2argvdata/tpm-passthrough.x86_64-latest.args +++ b/tests/qemuxml2argvdata/tpm-passthrough.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-TPM-VM/master-key.aes \ --machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.12,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 2048 \ +-object memory-backend-ram,id=pc.ram,size=2147483648 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid 11d7cd22-da89-3094-6212-079a48a309a1 \ diff --git a/tests/qemuxml2argvdata/tseg-explicit-size.x86_64-latest.args b/tests/qemuxml2argvdata/tseg-explicit-size.x86_64-latest.args index 53dab283cc..2e931dfe9a 100644 --- a/tests/qemuxml2argvdata/tseg-explicit-size.x86_64-latest.args +++ b/tests/qemuxml2argvdata/tseg-explicit-size.x86_64-latest.args @@ -12,10 +12,12 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc-q35-2.10,accel=tcg,usb=off,smm=on,dump-guest-core=off \ +-machine pc-q35-2.10,accel=tcg,usb=off,smm=on,dump-guest-core=off,\ +memory-backend=pc.ram \ -global mch.extended-tseg-mbytes=48 \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/usb-redir-unix.x86_64-latest.args b/tests/qemuxml2argvdata/usb-redir-unix.x86_64-latest.args index d6abba6817..1d247b0337 100644 --- a/tests/qemuxml2argvdata/usb-redir-unix.x86_64-latest.args +++ b/tests/qemuxml2argvdata/usb-redir-unix.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/vhost-user-fs-fd-memory.x86_64-latest.args b/tests/qemuxml2argvdata/vhost-user-fs-fd-memory.x86_64-latest.args index dd5f68abc5..13359c91fe 100644 --- a/tests/qemuxml2argvdata/vhost-user-fs-fd-memory.x86_64-latest.args +++ b/tests/qemuxml2argvdata/vhost-user-fs-fd-memory.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ +-object memory-backend-file,id=pc.ram,\ +mem-path=/var/lib/libvirt/qemu/ram/-1-guest/pc.ram,share=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -object memory-backend-file,id=ram-node0,\ diff --git a/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args b/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args index e4f5db7a63..59f45d466b 100644 --- a/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args +++ b/tests/qemuxml2argvdata/vhost-user-fs-hugepages.x86_64-latest.args @@ -12,9 +12,12 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine q35,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 2048 \ +-object memory-backend-file,id=pc.ram,\ +mem-path=/dev/hugepages2M/libvirt/qemu/-1-guest,share=yes,prealloc=yes,\ +size=2147483648 \ -overcommit mem-lock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -object memory-backend-file,id=ram-node0,\ diff --git a/tests/qemuxml2argvdata/vhost-user-gpu-secondary.x86_64-latest.args b/tests/qemuxml2argvdata/vhost-user-gpu-secondary.x86_64-latest.args index e99a5342dc..e7d3315b8f 100644 --- a/tests/qemuxml2argvdata/vhost-user-gpu-secondary.x86_64-latest.args +++ b/tests/qemuxml2argvdata/vhost-user-gpu-secondary.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-memfd,id=pc.ram,share=yes,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -object memory-backend-memfd,id=ram-node0,share=yes,size=224395264 \ diff --git a/tests/qemuxml2argvdata/vhost-user-vga.x86_64-latest.args b/tests/qemuxml2argvdata/vhost-user-vga.x86_64-latest.args index 277bf8c646..df5b1b481d 100644 --- a/tests/qemuxml2argvdata/vhost-user-vga.x86_64-latest.args +++ b/tests/qemuxml2argvdata/vhost-user-vga.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-memfd,id=pc.ram,share=yes,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -object memory-backend-memfd,id=ram-node0,share=yes,size=224395264 \ diff --git a/tests/qemuxml2argvdata/vhost-vsock-auto.x86_64-latest.args b/tests/qemuxml2argvdata/vhost-vsock-auto.x86_64-latest.args index e083b872c5..bc9102eab3 100644 --- a/tests/qemuxml2argvdata/vhost-vsock-auto.x86_64-latest.args +++ b/tests/qemuxml2argvdata/vhost-vsock-auto.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-test/master-key.aes \ --machine pc-i440fx-2.9,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.9,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid bba65c0e-c049-934f-b6aa-4e2c0582acdf \ diff --git a/tests/qemuxml2argvdata/vhost-vsock.x86_64-latest.args b/tests/qemuxml2argvdata/vhost-vsock.x86_64-latest.args index 8b3538a56a..a461d4d242 100644 --- a/tests/qemuxml2argvdata/vhost-vsock.x86_64-latest.args +++ b/tests/qemuxml2argvdata/vhost-vsock.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-test/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid bba65c0e-c049-934f-b6aa-4e2c0582acdf \ diff --git a/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args b/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args index b7fef1fe08..094c96aad6 100644 --- a/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args +++ b/tests/qemuxml2argvdata/video-bochs-display-device.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/video-qxl-device-vram64.x86_64-latest.args b/tests/qemuxml2argvdata/video-qxl-device-vram64.x86_64-latest.args index f12cef8549..6f38fae69c 100644 --- a/tests/qemuxml2argvdata/video-qxl-device-vram64.x86_64-latest.args +++ b/tests/qemuxml2argvdata/video-qxl-device-vram64.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/video-qxl-sec-device-vram64.x86_64-latest.args b/tests/qemuxml2argvdata/video-qxl-sec-device-vram64.x86_64-latest.args index d651b69902..e79c21eaf0 100644 --- a/tests/qemuxml2argvdata/video-qxl-sec-device-vram64.x86_64-latest.args +++ b/tests/qemuxml2argvdata/video-qxl-sec-device-vram64.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/video-ramfb-display-device.x86_64-latest.args b/tests/qemuxml2argvdata/video-ramfb-display-device.x86_64-latest.args index 6fe792f46d..5e4d4db341 100644 --- a/tests/qemuxml2argvdata/video-ramfb-display-device.x86_64-latest.args +++ b/tests/qemuxml2argvdata/video-ramfb-display-device.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 1024 \ +-object memory-backend-ram,id=pc.ram,size=1073741824 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-9p-multidevs.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-9p-multidevs.x86_64-latest.args index 5a2e1fafe1..4e453a2b05 100644 --- a/tests/qemuxml2argvdata/virtio-9p-multidevs.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-9p-multidevs.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args index 1fe7901479..8674a4b99d 100644 --- a/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-non-transitional.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine q35,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-controller-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-controller-ats.x86_64-latest.args index 734e239617..6552ee68f0 100644 --- a/tests/qemuxml2argvdata/virtio-options-controller-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-controller-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-controller-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-controller-iommu.x86_64-latest.args index 3403a515ca..15eb4b5c49 100644 --- a/tests/qemuxml2argvdata/virtio-options-controller-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-controller-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-controller-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-controller-packed.x86_64-latest.args index 6d0e9f3167..ae605a6ef0 100644 --- a/tests/qemuxml2argvdata/virtio-options-controller-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-controller-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-disk-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-disk-ats.x86_64-latest.args index cf82457eb6..908b5724d4 100644 --- a/tests/qemuxml2argvdata/virtio-options-disk-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-disk-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-disk-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-disk-iommu.x86_64-latest.args index 70a5ee13a1..3a030d8efb 100644 --- a/tests/qemuxml2argvdata/virtio-options-disk-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-disk-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-disk-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-disk-packed.x86_64-latest.args index 09ac4d559b..0cc82a2e46 100644 --- a/tests/qemuxml2argvdata/virtio-options-disk-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-disk-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-fs-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-fs-ats.x86_64-latest.args index 6fb1e9f7e2..92b8e248eb 100644 --- a/tests/qemuxml2argvdata/virtio-options-fs-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-fs-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-fs-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-fs-iommu.x86_64-latest.args index 46d9eb4fca..62c2d347f3 100644 --- a/tests/qemuxml2argvdata/virtio-options-fs-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-fs-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-fs-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-fs-packed.x86_64-latest.args index 6856f3899d..79aa5ca1a0 100644 --- a/tests/qemuxml2argvdata/virtio-options-fs-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-fs-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-input-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-input-ats.x86_64-latest.args index fe753ac550..27375c96ba 100644 --- a/tests/qemuxml2argvdata/virtio-options-input-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-input-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-input-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-input-iommu.x86_64-latest.args index 66ed22e1cd..b38a8f3f9b 100644 --- a/tests/qemuxml2argvdata/virtio-options-input-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-input-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-input-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-input-packed.x86_64-latest.args index 866a461794..38a402ef5a 100644 --- a/tests/qemuxml2argvdata/virtio-options-input-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-input-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-memballoon-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-memballoon-ats.x86_64-latest.args index f5ddb86840..9b4ef3711c 100644 --- a/tests/qemuxml2argvdata/virtio-options-memballoon-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-memballoon-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-memballoon-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-memballoon-iommu.x86_64-latest.args index 6a62e28dc9..ead878573d 100644 --- a/tests/qemuxml2argvdata/virtio-options-memballoon-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-memballoon-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-memballoon-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-memballoon-packed.x86_64-latest.args index 7b6c5f3694..3c32335896 100644 --- a/tests/qemuxml2argvdata/virtio-options-memballoon-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-memballoon-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-net-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-net-ats.x86_64-latest.args index 065033e3b3..12c0764d56 100644 --- a/tests/qemuxml2argvdata/virtio-options-net-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-net-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-net-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-net-iommu.x86_64-latest.args index fd97172249..f2d626a35f 100644 --- a/tests/qemuxml2argvdata/virtio-options-net-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-net-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-net-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-net-packed.x86_64-latest.args index f60ebdd50c..e6453534d4 100644 --- a/tests/qemuxml2argvdata/virtio-options-net-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-net-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-rng-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-rng-ats.x86_64-latest.args index aa7b46831b..cd4807b6c4 100644 --- a/tests/qemuxml2argvdata/virtio-options-rng-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-rng-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-rng-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-rng-iommu.x86_64-latest.args index 7e0dbf151d..66fb11bf7a 100644 --- a/tests/qemuxml2argvdata/virtio-options-rng-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-rng-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-rng-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-rng-packed.x86_64-latest.args index 0958aaeae4..3feff0eb58 100644 --- a/tests/qemuxml2argvdata/virtio-options-rng-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-rng-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-video-ats.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-video-ats.x86_64-latest.args index 9b85c9cb20..3ec61dab11 100644 --- a/tests/qemuxml2argvdata/virtio-options-video-ats.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-video-ats.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-video-iommu.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-video-iommu.x86_64-latest.args index d8a664d8d9..cfd3024e02 100644 --- a/tests/qemuxml2argvdata/virtio-options-video-iommu.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-video-iommu.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options-video-packed.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options-video-packed.x86_64-latest.args index 4e82d1880f..c5719bb1e6 100644 --- a/tests/qemuxml2argvdata/virtio-options-video-packed.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options-video-packed.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-options.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-options.x86_64-latest.args index 66bbd7df64..e230e926a4 100644 --- a/tests/qemuxml2argvdata/virtio-options.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-options.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-rng-builtin.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-rng-builtin.x86_64-latest.args index fe01d661e0..f8e37ce7f8 100644 --- a/tests/qemuxml2argvdata/virtio-rng-builtin.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-rng-builtin.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-rng-egd-unix.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-rng-egd-unix.x86_64-latest.args index 37fb988b75..192d84413f 100644 --- a/tests/qemuxml2argvdata/virtio-rng-egd-unix.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-rng-egd-unix.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine pc,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args b/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args index 01cb9f8308..c526d7aec5 100644 --- a/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args +++ b/tests/qemuxml2argvdata/virtio-transitional.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ --machine q35,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 214 \ +-object memory-backend-ram,id=pc.ram,size=224395264 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ diff --git a/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-pc-4.2.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-pc-4.2.x86_64-latest.args index 3d9f246000..ad770d204f 100644 --- a/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-pc-4.2.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-pc-4.2.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine pc-i440fx-4.2,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-4.2,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \ diff --git a/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-q35-4.2.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-q35-4.2.x86_64-latest.args index 1066522ed5..81df0cb959 100644 --- a/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-q35-4.2.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-default-cpu-kvm-q35-4.2.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine pc-q35-4.2,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-q35-4.2,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \ diff --git a/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-pc-4.2.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-pc-4.2.x86_64-latest.args index e547001eb5..ffc52d85b0 100644 --- a/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-pc-4.2.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-pc-4.2.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine pc-i440fx-4.2,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-i440fx-4.2,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \ diff --git a/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-q35-4.2.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-q35-4.2.x86_64-latest.args index 6549f6251e..eda728f1f8 100644 --- a/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-q35-4.2.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-default-cpu-tcg-q35-4.2.x86_64-latest.args @@ -12,9 +12,11 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine pc-q35-4.2,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc-q35-4.2,accel=tcg,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \ diff --git a/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args index 4049ee6b27..5458fc6e10 100644 --- a/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-pc-graphics.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 2c0abd3d-8f18-42c0-a132-9708213aaac9 \ diff --git a/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args index 47887c0c18..d2246d0a02 100644 --- a/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-pc-headless.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine pc,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \ diff --git a/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args index 6425325a5b..e9d4e2c320 100644 --- a/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-q35-graphics.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine q35,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 61288c03-0b0d-4f1e-9496-0f0256f2e013 \ diff --git a/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args b/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args index 63254b500c..8bec37539f 100644 --- a/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args +++ b/tests/qemuxml2argvdata/x86_64-q35-headless.x86_64-latest.args @@ -12,9 +12,10 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-guest/master-key.aes \ --machine q35,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=tcg,usb=off,dump-guest-core=off,memory-backend=pc.ram \ -cpu qemu64 \ -m 4096 \ +-object memory-backend-ram,id=pc.ram,size=4294967296 \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \ -- 2.26.2

On a Tuesday in 2020, Michal Privoznik wrote:
So far, Libvirt configures memory-backend-* for memory hotplug,
*libvirt
possibly NUMA nodes and in a few other cases. This patch switches to constructing the memory-backend-* command line for all cases. To keep ability to migrate guests a little hack is used: the ID of the object is set to the one that QEMU uses internally anyways. These IDs are stable (first started to appear somewhere around v0.13.0-rc0~96) and can't change.
In fact, this patch does exactly what QEMU does internally. The reason for moving the logic into Libvirt is that QEMU wants to
*libvirt
deprecate the old style of specifying memory.
So far, only x84_64 test cases are changed, because tests for other architectures use older capabilities, which still lack the QEMU_CAPS_MACHINE_MEMORY_BACKEND capability and they don't report the RAM ID.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1836043
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_command.c | 69 ++++++++++++++++--- .../blkdeviotune-group-num.x86_64-latest.args | 3 +- ...blkdeviotune-max-length.x86_64-latest.args | 3 +- .../blkdeviotune-max.x86_64-latest.args | 3 +- .../channel-unix-guestfwd.x86_64-latest.args | 3 +- .../console-virtio-unix.x86_64-latest.args | 3 +- .../controller-virtio-scsi.x86_64-latest.args | 3 +- ...-Icelake-Server-pconfig.x86_64-latest.args | 3 +- .../cpu-translation.x86_64-latest.args | 3 +- .../cputune-cpuset-big-id.x86_64-latest.args | 3 +- .../disk-aio-io_uring.x86_64-latest.args | 3 +- .../disk-aio.x86_64-latest.args | 3 +- ...-backing-chains-noindex.x86_64-latest.args | 3 +- .../disk-cache.x86_64-latest.args | 4 +- .../disk-cdrom-bus-other.x86_64-latest.args | 3 +- ...m-empty-network-invalid.x86_64-latest.args | 3 +- .../disk-cdrom-network.x86_64-latest.args | 3 +- .../disk-cdrom-tray.x86_64-latest.args | 3 +- .../disk-cdrom.x86_64-latest.args | 3 +- .../disk-copy_on_read.x86_64-latest.args | 3 +- .../disk-detect-zeroes.x86_64-latest.args | 3 +- .../disk-discard.x86_64-latest.args | 3 +- .../disk-error-policy.x86_64-latest.args | 3 +- .../disk-floppy-q35-2_11.x86_64-latest.args | 4 +- .../disk-floppy-q35-2_9.x86_64-latest.args | 4 +- .../disk-floppy.x86_64-latest.args | 3 +- .../disk-network-gluster.x86_64-latest.args | 3 +- .../disk-network-http.x86_64-latest.args | 3 +- .../disk-network-iscsi.x86_64-latest.args | 3 +- .../disk-network-nbd.x86_64-latest.args | 3 +- .../disk-network-rbd.x86_64-latest.args | 3 +- .../disk-network-sheepdog.x86_64-latest.args | 3 +- ...isk-network-source-auth.x86_64-latest.args | 3 +- ...isk-network-tlsx509-nbd.x86_64-latest.args | 3 +- .../disk-nvme.x86_64-latest.args | 3 +- .../disk-readonly-disk.x86_64-latest.args | 3 +- .../disk-scsi-device-auto.x86_64-latest.args | 3 +- .../disk-scsi.x86_64-latest.args | 3 +- .../disk-shared.x86_64-latest.args | 3 +- .../disk-slices.x86_64-latest.args | 3 +- ...irtio-scsi-reservations.x86_64-latest.args | 3 +- .../eoi-disabled.x86_64-latest.args | 3 +- .../eoi-enabled.x86_64-latest.args | 3 +- .../floppy-drive-fat.x86_64-latest.args | 3 +- .../qemuxml2argvdata/fs9p.x86_64-latest.args | 3 +- .../genid-auto.x86_64-latest.args | 3 +- .../qemuxml2argvdata/genid.x86_64-latest.args | 3 +- ...egl-headless-rendernode.x86_64-latest.args | 3 +- .../graphics-egl-headless.x86_64-latest.args | 3 +- ...pice-gl-auto-rendernode.x86_64-latest.args | 3 +- ...graphics-vnc-tls-secret.x86_64-latest.args | 3 +- .../graphics-vnc-tls.x86_64-latest.args | 3 +- ...tdev-mdev-display-ramfb.x86_64-latest.args | 3 +- ...play-spice-egl-headless.x86_64-latest.args | 3 +- ...ev-display-spice-opengl.x86_64-latest.args | 3 +- ...isplay-vnc-egl-headless.x86_64-latest.args | 3 +- ...ostdev-mdev-display-vnc.x86_64-latest.args | 3 +- .../hostdev-scsi-lsi.x86_64-latest.args | 3 +- ...ostdev-scsi-virtio-scsi.x86_64-latest.args | 3 +- .../hugepages-nvdimm.x86_64-latest.args | 6 +- .../hyperv-off.x86_64-latest.args | 3 +- .../hyperv-panic.x86_64-latest.args | 3 +- .../hyperv-stimer-direct.x86_64-latest.args | 3 +- .../hyperv.x86_64-latest.args | 3 +- .../intel-iommu-aw-bits.x86_64-latest.args | 4 +- ...ntel-iommu-caching-mode.x86_64-latest.args | 4 +- ...ntel-iommu-device-iotlb.x86_64-latest.args | 4 +- .../intel-iommu-eim.x86_64-latest.args | 4 +- .../intel-iommu.x86_64-latest.args | 3 +- ...threads-virtio-scsi-pci.x86_64-latest.args | 3 +- .../kvmclock+eoi-disabled.x86_64-latest.args | 3 +- ...luks-disks-source-qcow2.x86_64-latest.args | 4 +- ...memory-default-hugepage.x86_64-latest.args | 8 ++- .../memfd-memory-numa.x86_64-latest.args | 8 ++- ...y-hotplug-nvdimm-access.x86_64-latest.args | 4 +- ...ry-hotplug-nvdimm-align.x86_64-latest.args | 4 +- ...ry-hotplug-nvdimm-label.x86_64-latest.args | 4 +- ...ory-hotplug-nvdimm-pmem.x86_64-latest.args | 4 +- ...hotplug-nvdimm-readonly.x86_64-latest.args | 4 +- .../memory-hotplug-nvdimm.x86_64-latest.args | 4 +- .../mlock-off.x86_64-latest.args | 3 +- .../mlock-on.x86_64-latest.args | 3 +- .../net-vhostuser.x86_64-latest.args | 3 +- .../numatune-hmat.x86_64-latest.args | 4 +- .../os-firmware-bios.x86_64-latest.args | 4 +- ...os-firmware-efi-secboot.x86_64-latest.args | 4 +- .../os-firmware-efi.x86_64-latest.args | 4 +- .../parallel-unix-chardev.x86_64-latest.args | 3 +- ...cie-root-port-nohotplug.x86_64-latest.args | 3 +- .../pv-spinlock-disabled.x86_64-latest.args | 3 +- .../pv-spinlock-enabled.x86_64-latest.args | 3 +- .../qemu-ns.x86_64-latest.args | 3 +- .../serial-unix-chardev.x86_64-latest.args | 3 +- ...rtcard-passthrough-unix.x86_64-latest.args | 3 +- .../tpm-emulator-tpm2-enc.x86_64-latest.args | 4 +- .../tpm-emulator-tpm2.x86_64-latest.args | 4 +- .../tpm-emulator.x86_64-latest.args | 4 +- .../tpm-passthrough-crb.x86_64-latest.args | 4 +- .../tpm-passthrough.x86_64-latest.args | 4 +- .../tseg-explicit-size.x86_64-latest.args | 4 +- .../usb-redir-unix.x86_64-latest.args | 3 +- ...vhost-user-fs-fd-memory.x86_64-latest.args | 4 +- ...vhost-user-fs-hugepages.x86_64-latest.args | 5 +- ...host-user-gpu-secondary.x86_64-latest.args | 3 +- .../vhost-user-vga.x86_64-latest.args | 3 +- .../vhost-vsock-auto.x86_64-latest.args | 4 +- .../vhost-vsock.x86_64-latest.args | 3 +- ...eo-bochs-display-device.x86_64-latest.args | 3 +- ...video-qxl-device-vram64.x86_64-latest.args | 3 +- ...o-qxl-sec-device-vram64.x86_64-latest.args | 3 +- ...eo-ramfb-display-device.x86_64-latest.args | 3 +- .../virtio-9p-multidevs.x86_64-latest.args | 3 +- ...virtio-non-transitional.x86_64-latest.args | 3 +- ...-options-controller-ats.x86_64-latest.args | 3 +- ...ptions-controller-iommu.x86_64-latest.args | 3 +- ...tions-controller-packed.x86_64-latest.args | 3 +- ...virtio-options-disk-ats.x86_64-latest.args | 3 +- ...rtio-options-disk-iommu.x86_64-latest.args | 3 +- ...tio-options-disk-packed.x86_64-latest.args | 3 +- .../virtio-options-fs-ats.x86_64-latest.args | 3 +- ...virtio-options-fs-iommu.x86_64-latest.args | 3 +- ...irtio-options-fs-packed.x86_64-latest.args | 3 +- ...irtio-options-input-ats.x86_64-latest.args | 3 +- ...tio-options-input-iommu.x86_64-latest.args | 3 +- ...io-options-input-packed.x86_64-latest.args | 3 +- ...-options-memballoon-ats.x86_64-latest.args | 3 +- ...ptions-memballoon-iommu.x86_64-latest.args | 3 +- ...tions-memballoon-packed.x86_64-latest.args | 3 +- .../virtio-options-net-ats.x86_64-latest.args | 3 +- ...irtio-options-net-iommu.x86_64-latest.args | 3 +- ...rtio-options-net-packed.x86_64-latest.args | 3 +- .../virtio-options-rng-ats.x86_64-latest.args | 3 +- ...irtio-options-rng-iommu.x86_64-latest.args | 3 +- ...rtio-options-rng-packed.x86_64-latest.args | 3 +- ...irtio-options-video-ats.x86_64-latest.args | 3 +- ...tio-options-video-iommu.x86_64-latest.args | 3 +- ...io-options-video-packed.x86_64-latest.args | 3 +- .../virtio-options.x86_64-latest.args | 3 +- .../virtio-rng-builtin.x86_64-latest.args | 3 +- .../virtio-rng-egd-unix.x86_64-latest.args | 3 +- .../virtio-transitional.x86_64-latest.args | 3 +- ...-default-cpu-kvm-pc-4.2.x86_64-latest.args | 4 +- ...default-cpu-kvm-q35-4.2.x86_64-latest.args | 4 +- ...-default-cpu-tcg-pc-4.2.x86_64-latest.args | 4 +- ...default-cpu-tcg-q35-4.2.x86_64-latest.args | 4 +- .../x86_64-pc-graphics.x86_64-latest.args | 3 +- .../x86_64-pc-headless.x86_64-latest.args | 3 +- .../x86_64-q35-graphics.x86_64-latest.args | 3 +- .../x86_64-q35-headless.x86_64-latest.args | 3 +- 149 files changed, 395 insertions(+), 163 deletions(-)
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index ecbdd226a4..b62dc78893 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -7015,6 +7015,14 @@ qemuBuildMachineCommandLine(virCommandPtr cmd, if (virDomainNumaHasHMAT(def->numa)) virBufferAddLit(&buf, ",hmat=on");
+ if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_MACHINE_MEMORY_BACKEND)) { + const char *defaultRAMid = virQEMUCapsGetMachineDefaultRAMid(qemuCaps, + def->virtType, + def->os.machine); + if (defaultRAMid) + virBufferAsprintf(&buf, ",memory-backend=%s", defaultRAMid); + } + virCommandAddArgBuffer(cmd, &buf);
return 0; @@ -7124,12 +7132,42 @@ qemuBuildMemPathStr(const virDomainDef *def, }
+static int +qemuBuildMemCommandLineMemoryBackendNew(virCommandPtr cmd,
s/BackendNew/DefaultBackend/ or MachineBackend 'New' does not age well.
+ const virDomainDef *def, + qemuDomainObjPrivatePtr priv, + const char *defaultRAMid) +{ + g_autoptr(virQEMUDriverConfig) cfg = virQEMUDriverGetConfig(priv->driver); + g_autoptr(virJSONValue) props = NULL; + g_auto(virBuffer) buf = VIR_BUFFER_INITIALIZER; + virDomainMemoryDef mem = { 0 }; + + mem.size = virDomainDefGetMemoryInitial(def); + mem.targetNode = -1; + mem.info.alias = (char *) defaultRAMid; + + if (qemuBuildMemoryBackendProps(&props, defaultRAMid, cfg, + priv, def, &mem, false) < 0) + return -1; + + if (virQEMUBuildObjectCommandlineFromJSON(&buf, props) < 0) + return -1; + + virCommandAddArg(cmd, "-object"); + virCommandAddArgBuffer(cmd, &buf); + return 0; +} + + static int qemuBuildMemCommandLine(virCommandPtr cmd, const virDomainDef *def, virQEMUCapsPtr qemuCaps, qemuDomainObjPrivatePtr priv) { + const char *defaultRAMid = NULL; + virCommandAddArg(cmd, "-m");
if (virDomainDefHasMemoryHotplug(def)) { @@ -7144,19 +7182,28 @@ qemuBuildMemCommandLine(virCommandPtr cmd, virDomainDefGetMemoryInitial(def) / 1024); }
- if (def->mem.allocation == VIR_DOMAIN_MEMORY_ALLOCATION_IMMEDIATE) { - virCommandAddArgList(cmd, "-mem-prealloc", NULL); - priv->memPrealloc = true; + defaultRAMid = virQEMUCapsGetMachineDefaultRAMid(qemuCaps, + def->virtType, + def->os.machine); + + if (defaultRAMid && + virQEMUCapsGet(qemuCaps, QEMU_CAPS_MACHINE_MEMORY_BACKEND)) { + qemuBuildMemCommandLineMemoryBackendNew(cmd, def, priv, defaultRAMid); + } else { + if (def->mem.allocation == VIR_DOMAIN_MEMORY_ALLOCATION_IMMEDIATE) { + virCommandAddArgList(cmd, "-mem-prealloc", NULL); + priv->memPrealloc = true; + } + + /* + * Add '-mem-path' (and '-mem-prealloc') parameter here if + * the hugepages and no numa node is specified. + */ + if (!virDomainNumaGetNodeCount(def->numa) && + qemuBuildMemPathStr(def, cmd, priv) < 0) + return -1; }
- /* - * Add '-mem-path' (and '-mem-prealloc') parameter here if - * the hugepages and no numa node is specified. - */ - if (!virDomainNumaGetNodeCount(def->numa) && - qemuBuildMemPathStr(def, cmd, priv) < 0) - return -1; - if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_OVERCOMMIT)) { virCommandAddArg(cmd, "-overcommit"); virCommandAddArgFormat(cmd, "mem-lock=%s", def->mem.locked ? "on" : "off");
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases? Jano

On 9/8/20 3:55 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases?
Ah, good question. Honestly, I don't remember, it was slightly longer ago that I've written these patches. Igor, do you perhaps remember whether libvirt needs to specify both: -machine memory-backend=$id and -object memory-backend-*,id=$id? Michal

On Tue, 15 Sep 2020 10:54:46 +0200 Michal Privoznik <mprivozn@redhat.com> wrote:
On 9/8/20 3:55 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases?
Ah, good question. Honestly, I don't remember, it was slightly longer ago that I've written these patches. Igor, do you perhaps remember whether libvirt needs to specify both: -machine memory-backend=$id and -object memory-backend-*,id=$id?
the later defines backend and the former uses it, short answer is yes. you do not need --mem-prealloc if you explicitly set "prealloc=yes" on backend. I'd prefer if libvirt stopped using old -mem-prealloc and -mem-path in favor of explicit properties on backend, so QEMU could deprecate it and drop aliasing code which uses global properties hack. also if ' -machine memory-backend=' is used and '-m' sets only initial ram size, then '-m' can be omitted as size will be derived from used backend.
Michal

On Tue, Sep 15, 2020 at 11:53:56AM +0200, Igor Mammedov wrote:
On Tue, 15 Sep 2020 10:54:46 +0200 Michal Privoznik <mprivozn@redhat.com> wrote:
On 9/8/20 3:55 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases?
Ah, good question. Honestly, I don't remember, it was slightly longer ago that I've written these patches. Igor, do you perhaps remember whether libvirt needs to specify both: -machine memory-backend=$id and -object memory-backend-*,id=$id?
the later defines backend and the former uses it, short answer is yes.
you do not need --mem-prealloc if you explicitly set "prealloc=yes" on backend.
I'd prefer if libvirt stopped using old -mem-prealloc and -mem-path in favor of explicit properties on backend, so QEMU could deprecate it and drop aliasing code which uses global properties hack.
IIRC, we tried todo that in the past and the change to use a backend impacted migration ABI compatibility. Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|

On 9/15/20 11:59 AM, Daniel P. Berrangé wrote:
On Tue, Sep 15, 2020 at 11:53:56AM +0200, Igor Mammedov wrote:
On Tue, 15 Sep 2020 10:54:46 +0200 Michal Privoznik <mprivozn@redhat.com> wrote:
On 9/8/20 3:55 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases?
Ah, good question. Honestly, I don't remember, it was slightly longer ago that I've written these patches. Igor, do you perhaps remember whether libvirt needs to specify both: -machine memory-backend=$id and -object memory-backend-*,id=$id?
the later defines backend and the former uses it, short answer is yes.
you do not need --mem-prealloc if you explicitly set "prealloc=yes" on backend.
I'd prefer if libvirt stopped using old -mem-prealloc and -mem-path in favor of explicit properties on backend, so QEMU could deprecate it and drop aliasing code which uses global properties hack.
IIRC, we tried todo that in the past and the change to use a backend impacted migration ABI compatibility.
Yes, but the problem there was that the memory IDs were not the same. That is: -m + -mem-path would create a memory-backend-file equivalent and set its ID to pc.ram (assuming this is x86 - hence default-ram-id exposure and tracking). But libvirt did generate different ID back then which was incompatible. Michal

On 9/15/20 12:07 PM, Michal Privoznik wrote:
On 9/15/20 11:59 AM, Daniel P. Berrangé wrote:
On Tue, Sep 15, 2020 at 11:53:56AM +0200, Igor Mammedov wrote:
On Tue, 15 Sep 2020 10:54:46 +0200 Michal Privoznik <mprivozn@redhat.com> wrote:
On 9/8/20 3:55 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args
b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args
index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args
@@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases?
Ah, good question. Honestly, I don't remember, it was slightly longer ago that I've written these patches. Igor, do you perhaps remember whether libvirt needs to specify both: -machine memory-backend=$id and -object memory-backend-*,id=$id?
the later defines backend and the former uses it, short answer is yes.
you do not need --mem-prealloc if you explicitly set "prealloc=yes" on backend.
I'd prefer if libvirt stopped using old -mem-prealloc and -mem-path in favor of explicit properties on backend, so QEMU could deprecate it and drop aliasing code which uses global properties hack.
IIRC, we tried todo that in the past and the change to use a backend impacted migration ABI compatibility.
Yes, but the problem there was that the memory IDs were not the same. That is: -m + -mem-path would create a memory-backend-file equivalent and set its ID to pc.ram (assuming this is x86 - hence default-ram-id exposure and tracking). But libvirt did generate different ID back then which was incompatible.
I remembered this discussion happening but couldn't find anywhere on the list. Of course, because it happened in bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1836043#c4 Michal

On Tue, 15 Sep 2020 10:59:04 +0100 Daniel P. Berrangé <berrange@redhat.com> wrote:
On Tue, Sep 15, 2020 at 11:53:56AM +0200, Igor Mammedov wrote:
On Tue, 15 Sep 2020 10:54:46 +0200 Michal Privoznik <mprivozn@redhat.com> wrote:
On 9/8/20 3:55 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases?
Ah, good question. Honestly, I don't remember, it was slightly longer ago that I've written these patches. Igor, do you perhaps remember whether libvirt needs to specify both: -machine memory-backend=$id and -object memory-backend-*,id=$id?
the later defines backend and the former uses it, short answer is yes.
you do not need --mem-prealloc if you explicitly set "prealloc=yes" on backend.
I'd prefer if libvirt stopped using old -mem-prealloc and -mem-path in favor of explicit properties on backend, so QEMU could deprecate it and drop aliasing code which uses global properties hack.
IIRC, we tried todo that in the past and the change to use a backend impacted migration ABI compatibility.
for new machine types, that shouldn't happen as they use memory-backend internally (assuming CLI isn't messed up). old machine types should cope with switch too, the only thing we were not able to convert "-numa node,mem" => "-numa memdev" due to odd sizes 'mem' allowed, that's why "-numa node,mem" were preserved for old machine types.
Regards, Daniel

On 9/15/20 11:53 AM, Igor Mammedov wrote:
On Tue, 15 Sep 2020 10:54:46 +0200 Michal Privoznik <mprivozn@redhat.com> wrote:
On 9/8/20 3:55 PM, Ján Tomko wrote:
On a Tuesday in 2020, Michal Privoznik wrote:
diff --git a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args index 5d256c42bc..b43e7d9c3c 100644 --- a/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args +++ b/tests/qemuxml2argvdata/memfd-memory-default-hugepage.x86_64-latest.args @@ -12,14 +12,16 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,\ file=/tmp/lib/domain--1-instance-00000092/master-key.aes \ --machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off \ +-machine pc-i440fx-2.3,accel=kvm,usb=off,dump-guest-core=off,\ +memory-backend=pc.ram \ -cpu qemu64 \ -m 14336 \ --mem-prealloc \ +-object memory-backend-memfd,id=pc.ram,hugetlb=yes,hugetlbsize=2097152,\ +share=yes,prealloc=yes,size=15032385536 \ -overcommit mem-lock=off \ -smp 8,sockets=1,dies=1,cores=8,threads=1 \ -object memory-backend-memfd,id=ram-node0,hugetlb=yes,hugetlbsize=2097152,\ -share=yes,size=15032385536,host-nodes=3,policy=preferred \ +share=yes,prealloc=yes,size=15032385536,host-nodes=3,policy=preferred \ -numa node,nodeid=0,cpus=0-7,memdev=ram-node0 \ -uuid 126f2720-6f8e-45ab-a886-ec9277079a67 \ -display none \
Should we format all the fields twice in these cases?
Ah, good question. Honestly, I don't remember, it was slightly longer ago that I've written these patches. Igor, do you perhaps remember whether libvirt needs to specify both: -machine memory-backend=$id and -object memory-backend-*,id=$id?
the later defines backend and the former uses it, short answer is yes.
Ah, good point. That's the thing I didn't remember.
you do not need --mem-prealloc if you explicitly set "prealloc=yes" on backend.
Yes, we are not doing this for quite some time now. https://gitlab.com/libvirt/libvirt/-/commit/c658764decf357ef2a064f09235fb6b8...
I'd prefer if libvirt stopped using old -mem-prealloc and -mem-path in favor of explicit properties on backend, so QEMU could deprecate it and drop aliasing code which uses global properties hack.
That is the whole intent of this series. The only problem was that we couldn't just switch to memory-backend-* because that was incompatible with -mem-path + -m. And the discussion led us to this solution. Michal
participants (4)
-
Daniel P. Berrangé
-
Igor Mammedov
-
Ján Tomko
-
Michal Privoznik