[PATCH 0/6] qemu: Fixes and capability update for 6.1 release

full version is at: git fetch https://gitlab.com/pipo.sk/libvirt.git qemu-caps-bump Posting this one early since it's updating tests to prevent spurious changes and improve testing of host-model cpus. Peter Krempa (6): qemuxml2argvdata: Don't use 'host-model' cpu in 'hugepages-memaccess3' qemuxml2argvtest: Unify 'cpu-tsc-frequency' and 'cpu-tsc-high-frequency' case qemuxml2argvtest: Slightly modernize "cpu-host-model" case qemuxml2argvtest: Add 'cpu-host-model' cases for all x86-64 real qemu caps versions qemucapabilitiesdata: Update qemu caps dump for 6.1.0 release qemuxml2argvtest: Add LATEST version of 'cpu-host-model' .../domaincapsdata/qemu_6.1.0-q35.x86_64.xml | 4 +- tests/domaincapsdata/qemu_6.1.0.x86_64.xml | 4 +- .../caps_6.1.0.x86_64.replies | 508 +++++++++--------- .../caps_6.1.0.x86_64.xml | 12 +- tests/qemuxml2argvdata/cpu-host-model.args | 14 +- .../cpu-host-model.x86_64-2.11.0.args | 35 ++ .../cpu-host-model.x86_64-2.12.0.args | 35 ++ .../cpu-host-model.x86_64-3.0.0.args | 35 ++ .../cpu-host-model.x86_64-3.1.0.args | 35 ++ .../cpu-host-model.x86_64-4.0.0.args | 35 ++ .../cpu-host-model.x86_64-4.1.0.args | 35 ++ .../cpu-host-model.x86_64-4.2.0.args | 35 ++ .../cpu-host-model.x86_64-5.0.0.args | 35 ++ .../cpu-host-model.x86_64-5.1.0.args | 35 ++ .../cpu-host-model.x86_64-5.2.0.args | 36 ++ ....args => cpu-host-model.x86_64-6.0.0.args} | 11 +- .../cpu-host-model.x86_64-6.1.0.args | 36 ++ .../cpu-host-model.x86_64-latest.args | 36 ++ tests/qemuxml2argvdata/cpu-host-model.xml | 14 +- tests/qemuxml2argvdata/cpu-tsc-frequency.args | 2 +- .../cpu-tsc-frequency.x86_64-4.0.0.args | 2 +- tests/qemuxml2argvdata/cpu-tsc-frequency.xml | 2 +- .../cpu-tsc-high-frequency.xml | 35 -- .../hugepages-memaccess3.x86_64-latest.args | 2 +- .../qemuxml2argvdata/hugepages-memaccess3.xml | 3 - tests/qemuxml2argvtest.c | 28 +- 26 files changed, 740 insertions(+), 324 deletions(-) create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-2.11.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-2.12.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-3.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-3.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.2.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.2.0.args rename tests/qemuxml2argvdata/{cpu-tsc-high-frequency.x86_64-latest.args => cpu-host-model.x86_64-6.0.0.args} (72%) create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-latest.args delete mode 100644 tests/qemuxml2argvdata/cpu-tsc-high-frequency.xml -- 2.31.1

The test case doesn't really test anything about the specific CPU. Using a host-model cpu with DO_TEST_CAPS_LATEST results in commandline changes every time qemu updates the cpu definiton. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- tests/qemuxml2argvdata/hugepages-memaccess3.x86_64-latest.args | 2 +- tests/qemuxml2argvdata/hugepages-memaccess3.xml | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/tests/qemuxml2argvdata/hugepages-memaccess3.x86_64-latest.args b/tests/qemuxml2argvdata/hugepages-memaccess3.x86_64-latest.args index f6c5e116d8..ae5b48aa1c 100644 --- a/tests/qemuxml2argvdata/hugepages-memaccess3.x86_64-latest.args +++ b/tests/qemuxml2argvdata/hugepages-memaccess3.x86_64-latest.args @@ -11,7 +11,7 @@ XDG_CONFIG_HOME=/tmp/lib/domain--1-fedora/.config \ -S \ -object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/tmp/lib/domain--1-fedora/master-key.aes"}' \ -machine pc-i440fx-2.9,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ --cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on,svm=off,npt=off,nrip-save=off \ +-cpu qemu64 \ -m 4096 \ -object '{"qom-type":"memory-backend-file","id":"pc.ram","mem-path":"/dev/hugepages2M/libvirt/qemu/-1-fedora","share":true,"x-use-canonical-path-for-ramblock-id":false,"prealloc":true,"size":4294967296}' \ -overcommit mem-lock=off \ diff --git a/tests/qemuxml2argvdata/hugepages-memaccess3.xml b/tests/qemuxml2argvdata/hugepages-memaccess3.xml index 43c3ec688b..a9d2cd9da0 100644 --- a/tests/qemuxml2argvdata/hugepages-memaccess3.xml +++ b/tests/qemuxml2argvdata/hugepages-memaccess3.xml @@ -12,9 +12,6 @@ <type arch='x86_64' machine='pc-i440fx-2.9'>hvm</type> <bootmenu enable='yes'/> </os> - <cpu mode='host-model' check='partial'> - <model fallback='allow'/> - </cpu> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>destroy</on_crash> -- 2.31.1

Use the larger number in the original test to avoid having two files. Additionally this avoids use of 'host-model' with DO_TEST_CAPS_LATEST in cases when it isn't necessary for the purpose of the test as the CPU model tends to change. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- tests/qemuxml2argvdata/cpu-tsc-frequency.args | 2 +- .../cpu-tsc-frequency.x86_64-4.0.0.args | 2 +- tests/qemuxml2argvdata/cpu-tsc-frequency.xml | 2 +- .../cpu-tsc-high-frequency.x86_64-latest.args | 33 ----------------- .../cpu-tsc-high-frequency.xml | 35 ------------------- tests/qemuxml2argvtest.c | 1 - 6 files changed, 3 insertions(+), 72 deletions(-) delete mode 100644 tests/qemuxml2argvdata/cpu-tsc-high-frequency.x86_64-latest.args delete mode 100644 tests/qemuxml2argvdata/cpu-tsc-high-frequency.xml diff --git a/tests/qemuxml2argvdata/cpu-tsc-frequency.args b/tests/qemuxml2argvdata/cpu-tsc-frequency.args index 1f582f720c..2a031b6ef0 100644 --- a/tests/qemuxml2argvdata/cpu-tsc-frequency.args +++ b/tests/qemuxml2argvdata/cpu-tsc-frequency.args @@ -11,7 +11,7 @@ QEMU_AUDIO_DRV=none \ -name guest=QEMUGuest1,debug-threads=on \ -S \ -machine pc,accel=kvm,usb=off,dump-guest-core=off \ --cpu Haswell,+vme,+ds,+acpi,+ss,+ht,+tm,+pbe,+dtes64,+monitor,+ds_cpl,+vmx,+smx,+est,+tm2,+xtpr,+pdcm,+f16c,+rdrand,+pdpe1gb,+abm,+lahf_lm,+invtsc,tsc-frequency=3504000000 \ +-cpu Haswell,+vme,+ds,+acpi,+ss,+ht,+tm,+pbe,+dtes64,+monitor,+ds_cpl,+vmx,+smx,+est,+tm2,+xtpr,+pdcm,+f16c,+rdrand,+pdpe1gb,+abm,+lahf_lm,+invtsc,tsc-frequency=4567890000 \ -m 214 \ -realtime mlock=off \ -smp 1,sockets=1,cores=1,threads=1 \ diff --git a/tests/qemuxml2argvdata/cpu-tsc-frequency.x86_64-4.0.0.args b/tests/qemuxml2argvdata/cpu-tsc-frequency.x86_64-4.0.0.args index cc78591c97..91b6e7943b 100644 --- a/tests/qemuxml2argvdata/cpu-tsc-frequency.x86_64-4.0.0.args +++ b/tests/qemuxml2argvdata/cpu-tsc-frequency.x86_64-4.0.0.args @@ -12,7 +12,7 @@ QEMU_AUDIO_DRV=none \ -S \ -object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -machine pc-i440fx-4.0,accel=kvm,usb=off,dump-guest-core=off \ --cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc_adjust=on,clflushopt=on,umip=on,ssbd=on,xsaves=on,pdpe1gb=on,invtsc=on,tsc-frequency=3504000000 \ +-cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc_adjust=on,clflushopt=on,umip=on,ssbd=on,xsaves=on,pdpe1gb=on,invtsc=on,tsc-frequency=4567890000 \ -m 214 \ -overcommit mem-lock=off \ -smp 1,sockets=1,cores=1,threads=1 \ diff --git a/tests/qemuxml2argvdata/cpu-tsc-frequency.xml b/tests/qemuxml2argvdata/cpu-tsc-frequency.xml index adb118c527..afaef6e8e5 100644 --- a/tests/qemuxml2argvdata/cpu-tsc-frequency.xml +++ b/tests/qemuxml2argvdata/cpu-tsc-frequency.xml @@ -18,7 +18,7 @@ <feature policy='require' name='invtsc'/> </cpu> <clock offset='utc'> - <timer name='tsc' frequency='3504000000'/> + <timer name='tsc' frequency='4567890000'/> </clock> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> diff --git a/tests/qemuxml2argvdata/cpu-tsc-high-frequency.x86_64-latest.args b/tests/qemuxml2argvdata/cpu-tsc-high-frequency.x86_64-latest.args deleted file mode 100644 index c39817af98..0000000000 --- a/tests/qemuxml2argvdata/cpu-tsc-high-frequency.x86_64-latest.args +++ /dev/null @@ -1,33 +0,0 @@ -LC_ALL=C \ -PATH=/bin \ -HOME=/tmp/lib/domain--1-QEMUGuest1 \ -USER=test \ -LOGNAME=test \ -XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ -XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ -XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ -/usr/bin/qemu-system-x86_64 \ --name guest=QEMUGuest1,debug-threads=on \ --S \ --object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/tmp/lib/domain--1-QEMUGuest1/master-key.aes"}' \ --machine pc,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ --cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on,svm=off,npt=off,nrip-save=off,invtsc=on,tsc-frequency=4567890000 \ --m 214 \ --object '{"qom-type":"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 \ --display none \ --no-user-config \ --nodefaults \ --chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ --mon chardev=charmonitor,id=monitor,mode=control \ --rtc base=utc \ --no-shutdown \ --no-acpi \ --boot strict=on \ --device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 \ --audiodev id=audio1,driver=none \ --device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \ --sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ --msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-tsc-high-frequency.xml b/tests/qemuxml2argvdata/cpu-tsc-high-frequency.xml deleted file mode 100644 index afaef6e8e5..0000000000 --- a/tests/qemuxml2argvdata/cpu-tsc-high-frequency.xml +++ /dev/null @@ -1,35 +0,0 @@ -<domain type='kvm'> - <name>QEMUGuest1</name> - <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid> - <title>A description of the test machine.</title> - <description> - A test of qemu's minimal configuration. - This test also tests the description and title elements. - </description> - <memory unit='KiB'>219100</memory> - <currentMemory unit='KiB'>219100</currentMemory> - <vcpu placement='static'>1</vcpu> - <os> - <type arch='x86_64' machine='pc'>hvm</type> - <boot dev='hd'/> - </os> - <cpu mode='host-model'> - <model fallback='allow'/> - <feature policy='require' name='invtsc'/> - </cpu> - <clock offset='utc'> - <timer name='tsc' frequency='4567890000'/> - </clock> - <on_poweroff>destroy</on_poweroff> - <on_reboot>restart</on_reboot> - <on_crash>destroy</on_crash> - <devices> - <emulator>/usr/bin/qemu-system-x86_64</emulator> - <controller type='usb' index='0'/> - <controller type='ide' index='0'/> - <controller type='pci' index='0' model='pci-root'/> - <input type='mouse' bus='ps2'/> - <input type='keyboard' bus='ps2'/> - <memballoon model='virtio'/> - </devices> -</domain> diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index 4ce7ed5f00..4e7d1da216 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -2102,7 +2102,6 @@ mymain(void) DO_TEST_CAPS_VER("cpu-host-model-cmt", "4.0.0"); DO_TEST("cpu-tsc-frequency", QEMU_CAPS_KVM); DO_TEST_CAPS_VER("cpu-tsc-frequency", "4.0.0"); - DO_TEST_CAPS_LATEST("cpu-tsc-high-frequency"); DO_TEST_CAPS_VER("cpu-translation", "4.0.0"); DO_TEST_CAPS_LATEST("cpu-translation"); qemuTestSetHostCPU(&driver, driver.hostarch, NULL); -- 2.31.1

Switch to q35 in anticipation of using DO_TEST_CAPS* in further patches. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- tests/qemuxml2argvdata/cpu-host-model.args | 14 ++++++++++---- tests/qemuxml2argvdata/cpu-host-model.xml | 14 ++++++++------ tests/qemuxml2argvtest.c | 7 ++++++- 3 files changed, 24 insertions(+), 11 deletions(-) diff --git a/tests/qemuxml2argvdata/cpu-host-model.args b/tests/qemuxml2argvdata/cpu-host-model.args index 651952d7fb..f4511fef83 100644 --- a/tests/qemuxml2argvdata/cpu-host-model.args +++ b/tests/qemuxml2argvdata/cpu-host-model.args @@ -10,11 +10,11 @@ QEMU_AUDIO_DRV=none \ /usr/bin/qemu-system-x86_64 \ -name guest=QEMUGuest1,debug-threads=on \ -S \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ +-machine q35,accel=kvm,usb=off,dump-guest-core=off \ -cpu core2duo,+ds,+acpi,+ss,+ht,+tm,+pbe,+ds_cpl,+vmx,+est,+tm2,+cx16,+xtpr,+lahf_lm \ -m 214 \ -realtime mlock=off \ --smp 6,sockets=6,cores=1,threads=1 \ +-smp 1,sockets=1,cores=1,threads=1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -display none \ -no-user-config \ @@ -24,6 +24,12 @@ QEMU_AUDIO_DRV=none \ -rtc base=utc \ -no-shutdown \ -no-acpi \ --usb \ --device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \ +-device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \ +-device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x0 \ +-device ioh3420,port=0x8,chassis=3,id=pci.3,bus=pcie.0,addr=0x1 \ +-device ich9-usb-ehci1,id=usb,bus=pcie.0,addr=0x1d.0x7 \ +-device ich9-usb-uhci1,masterbus=usb.0,firstport=0,bus=pcie.0,multifunction=on,addr=0x1d \ +-device ich9-usb-uhci2,masterbus=usb.0,firstport=2,bus=pcie.0,addr=0x1d.0x1 \ +-device ich9-usb-uhci3,masterbus=usb.0,firstport=4,bus=pcie.0,addr=0x1d.0x2 \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x1 \ -msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.xml b/tests/qemuxml2argvdata/cpu-host-model.xml index 21697eda0f..29ea4e3e68 100644 --- a/tests/qemuxml2argvdata/cpu-host-model.xml +++ b/tests/qemuxml2argvdata/cpu-host-model.xml @@ -1,19 +1,21 @@ -<domain type='qemu'> +<domain type='kvm'> <name>QEMUGuest1</name> <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid> <memory unit='KiB'>219100</memory> <currentMemory unit='KiB'>219100</currentMemory> - <vcpu placement='static'>6</vcpu> + <vcpu placement='static'>1</vcpu> <os> - <type arch='x86_64' machine='pc'>hvm</type> - <boot dev='network'/> + <type arch='x86_64' machine='q35'>hvm</type> </os> - <cpu mode='host-model'/> + <cpu mode='host-model'> + <model fallback='allow'/> + </cpu> <clock offset='utc'/> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>destroy</on_crash> <devices> - <emulator>/usr/bin/qemu-system-x86_64</emulator> + <emulator>/usr/bin/qemu-system-x86_64</emulator> + <controller type='pci' index='0' model='pcie-root'/> </devices> </domain> diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index 4e7d1da216..aa3da0ef93 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -2077,7 +2077,12 @@ mymain(void) DO_TEST_FAILURE("cpu-numa-memshared", QEMU_CAPS_OBJECT_MEMORY_RAM); DO_TEST_PARSE_ERROR_NOCAPS("cpu-numa-memshared-1"); DO_TEST("cpu-numa-memshared", QEMU_CAPS_OBJECT_MEMORY_FILE); - DO_TEST_NOCAPS("cpu-host-model"); + DO_TEST("cpu-host-model", + QEMU_CAPS_DEVICE_PCI_BRIDGE, + QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, + QEMU_CAPS_DEVICE_IOH3420, + QEMU_CAPS_ICH9_AHCI, + QEMU_CAPS_ICH9_USB_EHCI1); DO_TEST_NOCAPS("cpu-host-model-vendor"); DO_TEST_FULL("cpu-host-model-fallback", "", ARG_FLAGS, FLAG_SKIP_LEGACY_CPUS, ARG_END); -- 2.31.1

The host model expansion depends on the capability data, so in this case it makes sense to have specific invocations of the test for all qemu versions we have. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- .../cpu-host-model.x86_64-2.11.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-2.12.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-3.0.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-3.1.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-4.0.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-4.1.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-4.2.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-5.0.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-5.1.0.args | 35 ++++++++++++++++++ .../cpu-host-model.x86_64-5.2.0.args | 36 +++++++++++++++++++ .../cpu-host-model.x86_64-6.0.0.args | 36 +++++++++++++++++++ .../cpu-host-model.x86_64-6.1.0.args | 36 +++++++++++++++++++ tests/qemuxml2argvtest.c | 16 +++++++++ 13 files changed, 439 insertions(+) create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-2.11.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-2.12.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-3.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-3.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.2.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.2.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-6.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-2.11.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-2.11.0.args new file mode 100644 index 0000000000..bd3a9e26d2 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-2.11.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +QEMU_AUDIO_DRV=none \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-2.11,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Skylake-Client,ss=on,vmx=on,hypervisor=on,tsc_adjust=on,clflushopt=on,umip=on,xsaves=on,pdpe1gb=on \ +-m 214 \ +-realtime mlock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,path=/tmp/lib/domain--1-QEMUGuest1/monitor.sock,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-2.12.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-2.12.0.args new file mode 100644 index 0000000000..6bf18db474 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-2.12.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +QEMU_AUDIO_DRV=none \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-2.12,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Haswell-noTSX,vme=on,ss=on,f16c=on,rdrand=on,hypervisor=on,arat=on,tsc_adjust=on,xsaveopt=on,pdpe1gb=on,abm=on \ +-m 214 \ +-realtime mlock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-3.0.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-3.0.0.args new file mode 100644 index 0000000000..cb378765b0 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-3.0.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +QEMU_AUDIO_DRV=none \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-3.0,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc_adjust=on,clflushopt=on,umip=on,xsaves=on,pdpe1gb=on,topoext=on \ +-m 214 \ +-realtime mlock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-3.1.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-3.1.0.args new file mode 100644 index 0000000000..9af5a7fffa --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-3.1.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +QEMU_AUDIO_DRV=none \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-3.1,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc_adjust=on,clflushopt=on,umip=on,xsaves=on,pdpe1gb=on \ +-m 214 \ +-overcommit mem-lock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.0.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.0.0.args new file mode 100644 index 0000000000..28af7263a2 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.0.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +QEMU_AUDIO_DRV=none \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-4.0,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc_adjust=on,clflushopt=on,umip=on,ssbd=on,xsaves=on,pdpe1gb=on \ +-m 214 \ +-overcommit mem-lock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.1.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.1.0.args new file mode 100644 index 0000000000..b6a9afb359 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.1.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +QEMU_AUDIO_DRV=none \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-4.1,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc-adjust=on,clflushopt=on,umip=on,md-clear=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,pdpe1gb=on,skip-l1dfl-vmentry=on \ +-m 214 \ +-overcommit mem-lock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.2.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.2.0.args new file mode 100644 index 0000000000..69dc442bfc --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-4.2.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-4.2,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc-adjust=on,clflushopt=on,umip=on,md-clear=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,pdpe1gb=on,skip-l1dfl-vmentry=on,pschange-mc-no=on \ +-m 214 \ +-overcommit mem-lock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-audiodev id=audio1,driver=none \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.0.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.0.0.args new file mode 100644 index 0000000000..3ce594ba13 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.0.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-5.0,accel=kvm,usb=off,dump-guest-core=off \ +-cpu Skylake-Client-IBRS,ss=on,vmx=on,hypervisor=on,tsc-adjust=on,clflushopt=on,umip=on,md-clear=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,pdpe1gb=on,skip-l1dfl-vmentry=on,pschange-mc-no=on \ +-m 214 \ +-overcommit mem-lock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-audiodev id=audio1,driver=none \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.1.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.1.0.args new file mode 100644 index 0000000000..6c6ebb03f6 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.1.0.args @@ -0,0 +1,35 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-5.1,accel=kvm,usb=off,dump-guest-core=off \ +-cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on \ +-m 214 \ +-overcommit mem-lock=off \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-audiodev id=audio1,driver=none \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.2.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.2.0.args new file mode 100644 index 0000000000..c943457ced --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-5.2.0.args @@ -0,0 +1,36 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object secret,id=masterKey0,format=raw,file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ +-machine pc-q35-5.2,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ +-cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=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-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-audiodev id=audio1,driver=none \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.0.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.0.0.args new file mode 100644 index 0000000000..702cd70bd8 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.0.0.args @@ -0,0 +1,36 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/tmp/lib/domain--1-QEMUGuest1/master-key.aes"}' \ +-machine pc-q35-6.0,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ +-cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on \ +-m 214 \ +-object '{"qom-type":"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 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-audiodev id=audio1,driver=none \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args new file mode 100644 index 0000000000..4cd3392b55 --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args @@ -0,0 +1,36 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/tmp/lib/domain--1-QEMUGuest1/master-key.aes"}' \ +-machine pc-q35-6.1,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ +-cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on,svm=off,npt=off,nrip-save=off \ +-m 214 \ +-object '{"qom-type":"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 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-audiodev id=audio1,driver=none \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index aa3da0ef93..f0d1a71a81 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -2083,6 +2083,22 @@ mymain(void) QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_ICH9_AHCI, QEMU_CAPS_ICH9_USB_EHCI1); + + /* host-model cpu expansion depends on the cpu reported by qemu and thus + * we invoke it for all real capability dumps we have */ + DO_TEST_CAPS_VER("cpu-host-model", "2.11.0"); + DO_TEST_CAPS_VER("cpu-host-model", "2.12.0"); + DO_TEST_CAPS_VER("cpu-host-model", "3.0.0"); + DO_TEST_CAPS_VER("cpu-host-model", "3.1.0"); + DO_TEST_CAPS_VER("cpu-host-model", "4.0.0"); + DO_TEST_CAPS_VER("cpu-host-model", "4.1.0"); + DO_TEST_CAPS_VER("cpu-host-model", "4.2.0"); + DO_TEST_CAPS_VER("cpu-host-model", "5.0.0"); + DO_TEST_CAPS_VER("cpu-host-model", "5.1.0"); + DO_TEST_CAPS_VER("cpu-host-model", "5.2.0"); + DO_TEST_CAPS_VER("cpu-host-model", "6.0.0"); + DO_TEST_CAPS_VER("cpu-host-model", "6.1.0"); + DO_TEST_NOCAPS("cpu-host-model-vendor"); DO_TEST_FULL("cpu-host-model-fallback", "", ARG_FLAGS, FLAG_SKIP_LEGACY_CPUS, ARG_END); -- 2.31.1

(Note that this is rc4, the commit will be updated when 6.1.0 releases) --- .../domaincapsdata/qemu_6.1.0-q35.x86_64.xml | 4 +- tests/domaincapsdata/qemu_6.1.0.x86_64.xml | 4 +- .../caps_6.1.0.x86_64.replies | 508 +++++++++--------- .../caps_6.1.0.x86_64.xml | 12 +- .../cpu-host-model.x86_64-6.1.0.args | 2 +- 5 files changed, 263 insertions(+), 267 deletions(-) diff --git a/tests/domaincapsdata/qemu_6.1.0-q35.x86_64.xml b/tests/domaincapsdata/qemu_6.1.0-q35.x86_64.xml index 98b9c06cd1..bae2187aa2 100644 --- a/tests/domaincapsdata/qemu_6.1.0-q35.x86_64.xml +++ b/tests/domaincapsdata/qemu_6.1.0-q35.x86_64.xml @@ -56,13 +56,11 @@ <feature policy='require' name='invtsc'/> <feature policy='require' name='amd-ssbd'/> <feature policy='require' name='virt-ssbd'/> + <feature policy='require' name='svme-addr-chk'/> <feature policy='require' name='rdctl-no'/> <feature policy='require' name='skip-l1dfl-vmentry'/> <feature policy='require' name='mds-no'/> <feature policy='require' name='pschange-mc-no'/> - <feature policy='disable' name='svm'/> - <feature policy='disable' name='npt'/> - <feature policy='disable' name='nrip-save'/> </mode> <mode name='custom' supported='yes'> <model usable='yes'>qemu64</model> diff --git a/tests/domaincapsdata/qemu_6.1.0.x86_64.xml b/tests/domaincapsdata/qemu_6.1.0.x86_64.xml index 91a845204b..5a261f2d0e 100644 --- a/tests/domaincapsdata/qemu_6.1.0.x86_64.xml +++ b/tests/domaincapsdata/qemu_6.1.0.x86_64.xml @@ -55,13 +55,11 @@ <feature policy='require' name='invtsc'/> <feature policy='require' name='amd-ssbd'/> <feature policy='require' name='virt-ssbd'/> + <feature policy='require' name='svme-addr-chk'/> <feature policy='require' name='rdctl-no'/> <feature policy='require' name='skip-l1dfl-vmentry'/> <feature policy='require' name='mds-no'/> <feature policy='require' name='pschange-mc-no'/> - <feature policy='disable' name='svm'/> - <feature policy='disable' name='npt'/> - <feature policy='disable' name='nrip-save'/> </mode> <mode name='custom' supported='yes'> <model usable='yes'>qemu64</model> diff --git a/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.replies b/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.replies index 17bd3dd21b..52bf2bd8ca 100644 --- a/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.replies @@ -17,11 +17,11 @@ { "return": { "qemu": { - "micro": 90, + "micro": 94, "minor": 0, "major": 6 }, - "package": "v6.1.0-rc0-48-g7b7ca8ebde" + "package": "v6.1.0-rc4" }, "id": "libvirt-2" } [...trimmed...] diff --git a/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.xml b/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.xml index 1fad52ba90..315e41298c 100644 --- a/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_6.1.0.x86_64.xml @@ -256,14 +256,14 @@ <flag name='virtio-vga-gl'/> <flag name='confidential-guest-support'/> <flag name='query-display-options'/> - <version>6000090</version> + <version>6000094</version> <kvmVersion>0</kvmVersion> <microcodeVersion>43100243</microcodeVersion> - <package>v6.1.0-rc0-48-g7b7ca8ebde</package> + <package>v6.1.0-rc4</package> <arch>x86_64</arch> <hostCPU type='kvm' model='base' migratability='yes'> <property name='vmx-entry-load-rtit-ctl' type='boolean' value='false'/> - <property name='svme-addr-chk' type='boolean' value='false'/> + <property name='svme-addr-chk' type='boolean' value='true' migratable='yes'/> <property name='cmov' type='boolean' value='true' migratable='yes'/> <property name='ia64' type='boolean' value='false'/> <property name='ssb-no' type='boolean' value='false'/> @@ -359,7 +359,7 @@ <property name='avx-vnni' type='boolean' value='false'/> <property name='3dnowext' type='boolean' value='false'/> <property name='amd-no-ssb' type='boolean' value='false'/> - <property name='npt' type='boolean' value='false'/> + <property name='npt' type='boolean' value='true' migratable='yes'/> <property name='rdctl-no' type='boolean' value='true' migratable='yes'/> <property name='vmx-invvpid' type='boolean' value='false'/> <property name='clwb' type='boolean' value='true' migratable='yes'/> @@ -401,7 +401,7 @@ <property name='vmx-vpid' type='boolean' value='false'/> <property name='syscall' type='boolean' value='true' migratable='yes'/> <property name='avx512dq' type='boolean' value='false'/> - <property name='svm' type='boolean' value='false'/> + <property name='svm' type='boolean' value='true' migratable='yes'/> <property name='invtsc' type='boolean' value='true' migratable='no'/> <property name='vmx-monitor-exit' type='boolean' value='false'/> <property name='sse2' type='boolean' value='true' migratable='yes'/> @@ -427,7 +427,7 @@ <property name='vmx-exit-clear-rtit-ctl' type='boolean' value='false'/> <property name='model' type='number' value='113'/> <property name='movbe' type='boolean' value='true' migratable='yes'/> - <property name='nrip-save' type='boolean' value='false'/> + <property name='nrip-save' type='boolean' value='true' migratable='yes'/> <property name='ssse3' type='boolean' value='true' migratable='yes'/> <property name='sse4a' type='boolean' value='true' migratable='yes'/> <property name='kvm-msi-ext-dest-id' type='boolean' value='false'/> diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args index 4cd3392b55..fee116de1e 100644 --- a/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args @@ -11,7 +11,7 @@ XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ -S \ -object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/tmp/lib/domain--1-QEMUGuest1/master-key.aes"}' \ -machine pc-q35-6.1,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ --cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on,svm=off,npt=off,nrip-save=off \ +-cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,svme-addr-chk=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on \ -m 214 \ -object '{"qom-type":"memory-backend-ram","id":"pc.ram","size":224395264}' \ -overcommit mem-lock=off \ -- 2.31.1

This one will be slightly unstable given that CPU features are being modified frequently in qemu especially when used with a modern cpu. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- .../cpu-host-model.x86_64-latest.args | 36 +++++++++++++++++++ tests/qemuxml2argvtest.c | 4 +++ 2 files changed, 40 insertions(+) create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-latest.args diff --git a/tests/qemuxml2argvdata/cpu-host-model.x86_64-latest.args b/tests/qemuxml2argvdata/cpu-host-model.x86_64-latest.args new file mode 100644 index 0000000000..c9eb5a42ab --- /dev/null +++ b/tests/qemuxml2argvdata/cpu-host-model.x86_64-latest.args @@ -0,0 +1,36 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/tmp/lib/domain--1-QEMUGuest1 \ +USER=test \ +LOGNAME=test \ +XDG_DATA_HOME=/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=QEMUGuest1,debug-threads=on \ +-S \ +-object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/tmp/lib/domain--1-QEMUGuest1/master-key.aes"}' \ +-machine q35,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram \ +-cpu EPYC-Rome,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,stibp=on,arch-capabilities=on,ssbd=on,xsaves=on,cmp-legacy=on,amd-ssbd=on,virt-ssbd=on,svme-addr-chk=on,rdctl-no=on,skip-l1dfl-vmentry=on,mds-no=on,pschange-mc-no=on \ +-m 214 \ +-object '{"qom-type":"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 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=charmonitor,fd=1729,server=on,wait=off \ +-mon chardev=charmonitor,id=monitor,mode=control \ +-rtc base=utc \ +-no-shutdown \ +-no-acpi \ +-boot strict=on \ +-device pcie-root-port,port=0x8,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,addr=0x1 \ +-device pcie-root-port,port=0x9,chassis=2,id=pci.2,bus=pcie.0,addr=0x1.0x1 \ +-device pcie-root-port,port=0xa,chassis=3,id=pci.3,bus=pcie.0,addr=0x1.0x2 \ +-device qemu-xhci,id=usb,bus=pci.1,addr=0x0 \ +-audiodev id=audio1,driver=none \ +-device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x0 \ +-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ +-msg timestamp=on diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index f0d1a71a81..baac497201 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -2099,6 +2099,10 @@ mymain(void) DO_TEST_CAPS_VER("cpu-host-model", "6.0.0"); DO_TEST_CAPS_VER("cpu-host-model", "6.1.0"); + /* For this specific test we accept the increased likelyhood of changes + * if qemu updates the CPU model */ + DO_TEST_CAPS_LATEST("cpu-host-model"); + DO_TEST_NOCAPS("cpu-host-model-vendor"); DO_TEST_FULL("cpu-host-model-fallback", "", ARG_FLAGS, FLAG_SKIP_LEGACY_CPUS, ARG_END); -- 2.31.1

On a Wednesday in 2021, Peter Krempa wrote:
full version is at:
git fetch https://gitlab.com/pipo.sk/libvirt.git qemu-caps-bump
Posting this one early since it's updating tests to prevent spurious changes and improve testing of host-model cpus.
Peter Krempa (6): qemuxml2argvdata: Don't use 'host-model' cpu in 'hugepages-memaccess3' qemuxml2argvtest: Unify 'cpu-tsc-frequency' and 'cpu-tsc-high-frequency' case qemuxml2argvtest: Slightly modernize "cpu-host-model" case qemuxml2argvtest: Add 'cpu-host-model' cases for all x86-64 real qemu caps versions qemucapabilitiesdata: Update qemu caps dump for 6.1.0 release qemuxml2argvtest: Add LATEST version of 'cpu-host-model'
.../domaincapsdata/qemu_6.1.0-q35.x86_64.xml | 4 +- tests/domaincapsdata/qemu_6.1.0.x86_64.xml | 4 +- .../caps_6.1.0.x86_64.replies | 508 +++++++++--------- .../caps_6.1.0.x86_64.xml | 12 +-
[...]
.../hugepages-memaccess3.x86_64-latest.args | 2 +- .../qemuxml2argvdata/hugepages-memaccess3.xml | 3 - tests/qemuxml2argvtest.c | 28 +- 26 files changed, 740 insertions(+), 324 deletions(-) create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-2.11.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-2.12.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-3.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-3.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-4.2.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.0.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-5.2.0.args rename tests/qemuxml2argvdata/{cpu-tsc-high-frequency.x86_64-latest.args => cpu-host-model.x86_64-6.0.0.args} (72%) create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-6.1.0.args create mode 100644 tests/qemuxml2argvdata/cpu-host-model.x86_64-latest.args delete mode 100644 tests/qemuxml2argvdata/cpu-tsc-high-frequency.xml
Reviewed-by: Ján Tomko <jtomko@redhat.com> Jano
participants (2)
-
Ján Tomko
-
Peter Krempa