[PATCH] qemuxmlconftest: Add new cpu host model expansions tests

Michal Privoznik via Devel posted 1 patch 1 week, 2 days ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/ee0e633a8e23a10dcb72a55392915338079b4e1c.1777985720.git.mprivozn@redhat.com
...host-model-fallback-kvm.x86_64-10.2.0.args | 33 +++++++++++++
...-host-model-fallback-kvm.x86_64-10.2.0.xml | 29 +++++++++++
...host-model-fallback-kvm.x86_64-11.0.0.args | 33 +++++++++++++
...-host-model-fallback-kvm.x86_64-11.0.0.xml | 29 +++++++++++
...host-model-fallback-tcg.x86_64-10.2.0.args | 33 +++++++++++++
...-host-model-fallback-tcg.x86_64-10.2.0.xml | 29 +++++++++++
...host-model-fallback-tcg.x86_64-11.0.0.args | 33 +++++++++++++
...-host-model-fallback-tcg.x86_64-11.0.0.xml | 29 +++++++++++
.../cpu-host-model-kvm.x86_64-10.2.0.args     | 38 +++++++++++++++
.../cpu-host-model-kvm.x86_64-10.2.0.xml      | 48 +++++++++++++++++++
.../cpu-host-model-kvm.x86_64-11.0.0.args     | 38 +++++++++++++++
.../cpu-host-model-kvm.x86_64-11.0.0.xml      | 48 +++++++++++++++++++
...st-model-nofallback-kvm.x86_64-10.2.0.args | 33 +++++++++++++
...ost-model-nofallback-kvm.x86_64-10.2.0.xml | 29 +++++++++++
...st-model-nofallback-kvm.x86_64-11.0.0.args | 33 +++++++++++++
...ost-model-nofallback-kvm.x86_64-11.0.0.xml | 29 +++++++++++
...st-model-nofallback-tcg.x86_64-10.2.0.args | 33 +++++++++++++
...ost-model-nofallback-tcg.x86_64-10.2.0.xml | 29 +++++++++++
...st-model-nofallback-tcg.x86_64-11.0.0.args | 33 +++++++++++++
...ost-model-nofallback-tcg.x86_64-11.0.0.xml | 29 +++++++++++
.../cpu-host-model-tcg.x86_64-10.2.0.args     | 38 +++++++++++++++
.../cpu-host-model-tcg.x86_64-10.2.0.xml      | 48 +++++++++++++++++++
.../cpu-host-model-tcg.x86_64-11.0.0.args     | 38 +++++++++++++++
.../cpu-host-model-tcg.x86_64-11.0.0.xml      | 48 +++++++++++++++++++
tests/qemuxmlconftest.c                       | 12 +++++
25 files changed, 852 insertions(+)
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.xml
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.args
create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.xml
[PATCH] qemuxmlconftest: Add new cpu host model expansions tests
Posted by Michal Privoznik via Devel 1 week, 2 days ago
From: Michal Privoznik <mprivozn@redhat.com>

In qemuxmlconftest there's a section which aim on testing
'host-model' cpu mode expansion. Since this depends on what QEMU
reports (and thus can change with its version) we have a test
case for each QEMU version supported. Unfortunately, when adding
capabilities for new QEMUs this section was forgotten. Add
missing test cases (10.2.0 and 11.0.0).

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
---
 ...host-model-fallback-kvm.x86_64-10.2.0.args | 33 +++++++++++++
 ...-host-model-fallback-kvm.x86_64-10.2.0.xml | 29 +++++++++++
 ...host-model-fallback-kvm.x86_64-11.0.0.args | 33 +++++++++++++
 ...-host-model-fallback-kvm.x86_64-11.0.0.xml | 29 +++++++++++
 ...host-model-fallback-tcg.x86_64-10.2.0.args | 33 +++++++++++++
 ...-host-model-fallback-tcg.x86_64-10.2.0.xml | 29 +++++++++++
 ...host-model-fallback-tcg.x86_64-11.0.0.args | 33 +++++++++++++
 ...-host-model-fallback-tcg.x86_64-11.0.0.xml | 29 +++++++++++
 .../cpu-host-model-kvm.x86_64-10.2.0.args     | 38 +++++++++++++++
 .../cpu-host-model-kvm.x86_64-10.2.0.xml      | 48 +++++++++++++++++++
 .../cpu-host-model-kvm.x86_64-11.0.0.args     | 38 +++++++++++++++
 .../cpu-host-model-kvm.x86_64-11.0.0.xml      | 48 +++++++++++++++++++
 ...st-model-nofallback-kvm.x86_64-10.2.0.args | 33 +++++++++++++
 ...ost-model-nofallback-kvm.x86_64-10.2.0.xml | 29 +++++++++++
 ...st-model-nofallback-kvm.x86_64-11.0.0.args | 33 +++++++++++++
 ...ost-model-nofallback-kvm.x86_64-11.0.0.xml | 29 +++++++++++
 ...st-model-nofallback-tcg.x86_64-10.2.0.args | 33 +++++++++++++
 ...ost-model-nofallback-tcg.x86_64-10.2.0.xml | 29 +++++++++++
 ...st-model-nofallback-tcg.x86_64-11.0.0.args | 33 +++++++++++++
 ...ost-model-nofallback-tcg.x86_64-11.0.0.xml | 29 +++++++++++
 .../cpu-host-model-tcg.x86_64-10.2.0.args     | 38 +++++++++++++++
 .../cpu-host-model-tcg.x86_64-10.2.0.xml      | 48 +++++++++++++++++++
 .../cpu-host-model-tcg.x86_64-11.0.0.args     | 38 +++++++++++++++
 .../cpu-host-model-tcg.x86_64-11.0.0.xml      | 48 +++++++++++++++++++
 tests/qemuxmlconftest.c                       | 12 +++++
 25 files changed, 852 insertions(+)
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.xml
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.args
 create mode 100644 tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.xml

diff --git a/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.args b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.args
new file mode 100644
index 0000000000..309dc80244
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc-i440fx-10.2,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel kvm \
+-cpu EPYC-Turin,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,spec-ctrl=on,stibp=on,flush-l1d=on,ssbd=on,virt-ssbd=on,tsa-sq-no=on,tsa-l1-no=on,pcid=off,rdseed=off,la57=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.xml b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.xml
new file mode 100644
index 0000000000..e7b26bbfca
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-10.2.0.xml
@@ -0,0 +1,29 @@
+<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>
+  <os>
+    <type arch='x86_64' machine='pc-i440fx-10.2'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.args b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.args
new file mode 100644
index 0000000000..ed23d2bec4
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel kvm \
+-cpu EPYC-Turin,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,spec-ctrl=on,stibp=on,flush-l1d=on,ssbd=on,virt-ssbd=on,tsa-sq-no=on,tsa-l1-no=on,pcid=off,rdseed=off,la57=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.xml b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.xml
new file mode 100644
index 0000000000..8772918cdc
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-kvm.x86_64-11.0.0.xml
@@ -0,0 +1,29 @@
+<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>
+  <os>
+    <type arch='x86_64' machine='pc'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.args b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.args
new file mode 100644
index 0000000000..4daf8c40c4
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc-i440fx-10.2,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel tcg \
+-cpu EPYC,monitor=on,x2apic=on,hypervisor=on,acpi=on,ss=on,erms=on,mpx=on,clwb=on,umip=on,pku=on,vaes=on,la57=on,rdpid=on,pks=on,fsrm=on,cmpccxadd=on,fzrm=on,fsrs=on,fsrc=on,3dnowext=on,3dnow=on,xsaveerptr=on,wbnoinvd=on,npt=on,vgif=on,svme-addr-chk=on,no-nested-data-bp=on,null-sel-clr-base=on,vme=off,xsavec=off,misalignsse=off,osvw=off,topoext=off,fxsr-opt=off,nrip-save=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.xml b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.xml
new file mode 100644
index 0000000000..72c8099893
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-10.2.0.xml
@@ -0,0 +1,29 @@
+<domain type='qemu'>
+  <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>
+  <os>
+    <type arch='x86_64' machine='pc-i440fx-10.2'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.args b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.args
new file mode 100644
index 0000000000..443de62f69
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel tcg \
+-cpu EPYC,monitor=on,x2apic=on,hypervisor=on,acpi=on,ss=on,erms=on,mpx=on,clwb=on,umip=on,pku=on,vaes=on,la57=on,rdpid=on,pks=on,fsrm=on,cmpccxadd=on,fzrm=on,fsrs=on,fsrc=on,3dnowext=on,3dnow=on,xsaveerptr=on,wbnoinvd=on,npt=on,vgif=on,svme-addr-chk=on,no-nested-data-bp=on,null-sel-clr-base=on,vme=off,xsavec=off,misalignsse=off,osvw=off,topoext=off,fxsr-opt=off,nrip-save=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.xml b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.xml
new file mode 100644
index 0000000000..9a1c602064
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-fallback-tcg.x86_64-11.0.0.xml
@@ -0,0 +1,29 @@
+<domain type='qemu'>
+  <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>
+  <os>
+    <type arch='x86_64' machine='pc'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.args b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.args
new file mode 100644
index 0000000000..34e873b4c8
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.args
@@ -0,0 +1,38 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc-q35-10.2,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel kvm \
+-cpu EPYC-Turin,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,spec-ctrl=on,stibp=on,flush-l1d=on,ssbd=on,virt-ssbd=on,tsa-sq-no=on,tsa-l1-no=on,pcid=off,rdseed=off,la57=off \
+-m size=219136k \
+-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 \
+-boot strict=on \
+-device '{"driver":"pcie-root-port","port":8,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x1"}' \
+-device '{"driver":"pcie-root-port","port":9,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x1.0x1"}' \
+-device '{"driver":"pcie-root-port","port":10,"chassis":3,"id":"pci.3","bus":"pcie.0","addr":"0x1.0x2"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-global ICH9-LPC.noreboot=off \
+-watchdog-action reset \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.xml b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.xml
new file mode 100644
index 0000000000..ca1f5bef67
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-10.2.0.xml
@@ -0,0 +1,48 @@
+<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'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='pc-q35-10.2'>hvm</type>
+    <boot dev='hd'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='pci' index='0' model='pcie-root'/>
+    <controller type='pci' index='1' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='1' port='0x8'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0' multifunction='on'/>
+    </controller>
+    <controller type='pci' index='2' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='2' port='0x9'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
+    </controller>
+    <controller type='pci' index='3' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='3' port='0xa'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='usb' index='0' model='qemu-xhci'>
+      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
+    </controller>
+    <controller type='sata' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
+    </controller>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <watchdog model='itco' action='reset'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.args b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.args
new file mode 100644
index 0000000000..df7407e32b
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.args
@@ -0,0 +1,38 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine q35,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel kvm \
+-cpu EPYC-Turin,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,spec-ctrl=on,stibp=on,flush-l1d=on,ssbd=on,virt-ssbd=on,tsa-sq-no=on,tsa-l1-no=on,pcid=off,rdseed=off,la57=off \
+-m size=219136k \
+-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 \
+-boot strict=on \
+-device '{"driver":"pcie-root-port","port":8,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x1"}' \
+-device '{"driver":"pcie-root-port","port":9,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x1.0x1"}' \
+-device '{"driver":"pcie-root-port","port":10,"chassis":3,"id":"pci.3","bus":"pcie.0","addr":"0x1.0x2"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-global ICH9-LPC.noreboot=off \
+-watchdog-action reset \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.xml b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.xml
new file mode 100644
index 0000000000..677b0f16ef
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-kvm.x86_64-11.0.0.xml
@@ -0,0 +1,48 @@
+<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'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='q35'>hvm</type>
+    <boot dev='hd'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='pci' index='0' model='pcie-root'/>
+    <controller type='pci' index='1' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='1' port='0x8'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0' multifunction='on'/>
+    </controller>
+    <controller type='pci' index='2' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='2' port='0x9'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
+    </controller>
+    <controller type='pci' index='3' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='3' port='0xa'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='usb' index='0' model='qemu-xhci'>
+      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
+    </controller>
+    <controller type='sata' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
+    </controller>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <watchdog model='itco' action='reset'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.args b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.args
new file mode 100644
index 0000000000..309dc80244
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc-i440fx-10.2,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel kvm \
+-cpu EPYC-Turin,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,spec-ctrl=on,stibp=on,flush-l1d=on,ssbd=on,virt-ssbd=on,tsa-sq-no=on,tsa-l1-no=on,pcid=off,rdseed=off,la57=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.xml b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.xml
new file mode 100644
index 0000000000..e7b26bbfca
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-10.2.0.xml
@@ -0,0 +1,29 @@
+<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>
+  <os>
+    <type arch='x86_64' machine='pc-i440fx-10.2'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.args b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.args
new file mode 100644
index 0000000000..ed23d2bec4
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel kvm \
+-cpu EPYC-Turin,x2apic=on,tsc-deadline=on,hypervisor=on,tsc-adjust=on,spec-ctrl=on,stibp=on,flush-l1d=on,ssbd=on,virt-ssbd=on,tsa-sq-no=on,tsa-l1-no=on,pcid=off,rdseed=off,la57=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.xml b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.xml
new file mode 100644
index 0000000000..8772918cdc
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-kvm.x86_64-11.0.0.xml
@@ -0,0 +1,29 @@
+<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>
+  <os>
+    <type arch='x86_64' machine='pc'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.args b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.args
new file mode 100644
index 0000000000..4daf8c40c4
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc-i440fx-10.2,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel tcg \
+-cpu EPYC,monitor=on,x2apic=on,hypervisor=on,acpi=on,ss=on,erms=on,mpx=on,clwb=on,umip=on,pku=on,vaes=on,la57=on,rdpid=on,pks=on,fsrm=on,cmpccxadd=on,fzrm=on,fsrs=on,fsrc=on,3dnowext=on,3dnow=on,xsaveerptr=on,wbnoinvd=on,npt=on,vgif=on,svme-addr-chk=on,no-nested-data-bp=on,null-sel-clr-base=on,vme=off,xsavec=off,misalignsse=off,osvw=off,topoext=off,fxsr-opt=off,nrip-save=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.xml b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.xml
new file mode 100644
index 0000000000..72c8099893
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-10.2.0.xml
@@ -0,0 +1,29 @@
+<domain type='qemu'>
+  <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>
+  <os>
+    <type arch='x86_64' machine='pc-i440fx-10.2'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.args b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.args
new file mode 100644
index 0000000000..443de62f69
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.args
@@ -0,0 +1,33 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel tcg \
+-cpu EPYC,monitor=on,x2apic=on,hypervisor=on,acpi=on,ss=on,erms=on,mpx=on,clwb=on,umip=on,pku=on,vaes=on,la57=on,rdpid=on,pks=on,fsrm=on,cmpccxadd=on,fzrm=on,fsrs=on,fsrc=on,3dnowext=on,3dnow=on,xsaveerptr=on,wbnoinvd=on,npt=on,vgif=on,svme-addr-chk=on,no-nested-data-bp=on,null-sel-clr-base=on,vme=off,xsavec=off,misalignsse=off,osvw=off,topoext=off,fxsr-opt=off,nrip-save=off \
+-m size=219136k \
+-object '{"qom-type":"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 \
+-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 \
+-boot strict=on \
+-device '{"driver":"piix3-usb-uhci","id":"usb","bus":"pci.0","addr":"0x1.0x2"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.xml b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.xml
new file mode 100644
index 0000000000..9a1c602064
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-nofallback-tcg.x86_64-11.0.0.xml
@@ -0,0 +1,29 @@
+<domain type='qemu'>
+  <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>
+  <os>
+    <type arch='x86_64' machine='pc'>hvm</type>
+    <boot dev='network'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='usb' index='0' model='piix3-uhci'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.args b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.args
new file mode 100644
index 0000000000..627ee603f4
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.args
@@ -0,0 +1,38 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine pc-q35-10.2,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel tcg \
+-cpu EPYC,monitor=on,x2apic=on,hypervisor=on,acpi=on,ss=on,erms=on,mpx=on,clwb=on,umip=on,pku=on,vaes=on,la57=on,rdpid=on,pks=on,fsrm=on,cmpccxadd=on,fzrm=on,fsrs=on,fsrc=on,3dnowext=on,3dnow=on,xsaveerptr=on,wbnoinvd=on,npt=on,vgif=on,svme-addr-chk=on,no-nested-data-bp=on,null-sel-clr-base=on,vme=off,xsavec=off,misalignsse=off,osvw=off,topoext=off,fxsr-opt=off,nrip-save=off \
+-m size=219136k \
+-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 \
+-boot strict=on \
+-device '{"driver":"pcie-root-port","port":8,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x1"}' \
+-device '{"driver":"pcie-root-port","port":9,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x1.0x1"}' \
+-device '{"driver":"pcie-root-port","port":10,"chassis":3,"id":"pci.3","bus":"pcie.0","addr":"0x1.0x2"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-global ICH9-LPC.noreboot=off \
+-watchdog-action reset \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.xml b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.xml
new file mode 100644
index 0000000000..624968a7e9
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-10.2.0.xml
@@ -0,0 +1,48 @@
+<domain type='qemu'>
+  <name>QEMUGuest1</name>
+  <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid>
+  <memory unit='KiB'>219100</memory>
+  <currentMemory unit='KiB'>219100</currentMemory>
+  <vcpu placement='static'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='pc-q35-10.2'>hvm</type>
+    <boot dev='hd'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='pci' index='0' model='pcie-root'/>
+    <controller type='pci' index='1' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='1' port='0x8'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0' multifunction='on'/>
+    </controller>
+    <controller type='pci' index='2' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='2' port='0x9'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
+    </controller>
+    <controller type='pci' index='3' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='3' port='0xa'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='usb' index='0' model='qemu-xhci'>
+      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
+    </controller>
+    <controller type='sata' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
+    </controller>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <watchdog model='itco' action='reset'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.args b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.args
new file mode 100644
index 0000000000..688a217c3c
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.args
@@ -0,0 +1,38 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \
+USER=test \
+LOGNAME=test \
+XDG_DATA_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \
+XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \
+XDG_CONFIG_HOME=/var/lib/libvirt/qemu/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":"/var/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \
+-machine q35,usb=off,dump-guest-core=off,memory-backend=pc.ram,acpi=off \
+-accel tcg \
+-cpu EPYC,monitor=on,x2apic=on,hypervisor=on,acpi=on,ss=on,erms=on,mpx=on,clwb=on,umip=on,pku=on,vaes=on,la57=on,rdpid=on,pks=on,fsrm=on,cmpccxadd=on,fzrm=on,fsrs=on,fsrc=on,3dnowext=on,3dnow=on,xsaveerptr=on,wbnoinvd=on,npt=on,vgif=on,svme-addr-chk=on,no-nested-data-bp=on,null-sel-clr-base=on,vme=off,xsavec=off,misalignsse=off,osvw=off,topoext=off,fxsr-opt=off,nrip-save=off \
+-m size=219136k \
+-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 \
+-boot strict=on \
+-device '{"driver":"pcie-root-port","port":8,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x1"}' \
+-device '{"driver":"pcie-root-port","port":9,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x1.0x1"}' \
+-device '{"driver":"pcie-root-port","port":10,"chassis":3,"id":"pci.3","bus":"pcie.0","addr":"0x1.0x2"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
+-audiodev '{"id":"audio1","driver":"none"}' \
+-global ICH9-LPC.noreboot=off \
+-watchdog-action reset \
+-device '{"driver":"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/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.xml b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.xml
new file mode 100644
index 0000000000..a02e8ed9bb
--- /dev/null
+++ b/tests/qemuxmlconfdata/cpu-host-model-tcg.x86_64-11.0.0.xml
@@ -0,0 +1,48 @@
+<domain type='qemu'>
+  <name>QEMUGuest1</name>
+  <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid>
+  <memory unit='KiB'>219100</memory>
+  <currentMemory unit='KiB'>219100</currentMemory>
+  <vcpu placement='static'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='q35'>hvm</type>
+    <boot dev='hd'/>
+  </os>
+  <cpu mode='host-model' check='partial'/>
+  <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>
+    <controller type='pci' index='0' model='pcie-root'/>
+    <controller type='pci' index='1' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='1' port='0x8'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0' multifunction='on'/>
+    </controller>
+    <controller type='pci' index='2' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='2' port='0x9'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
+    </controller>
+    <controller type='pci' index='3' model='pcie-root-port'>
+      <model name='pcie-root-port'/>
+      <target chassis='3' port='0xa'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='usb' index='0' model='qemu-xhci'>
+      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
+    </controller>
+    <controller type='sata' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
+    </controller>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <audio id='1' type='none'/>
+    <watchdog model='itco' action='reset'/>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxmlconftest.c b/tests/qemuxmlconftest.c
index 4c9b55693a..9afedabae5 100644
--- a/tests/qemuxmlconftest.c
+++ b/tests/qemuxmlconftest.c
@@ -2224,6 +2224,8 @@ mymain(void)
     DO_TEST_CAPS_VER("cpu-host-model-kvm", "9.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-kvm", "10.0.0");
     DO_TEST_CAPS_VER("cpu-host-model-kvm", "10.1.0");
+    DO_TEST_CAPS_VER("cpu-host-model-kvm", "10.2.0");
+    DO_TEST_CAPS_VER("cpu-host-model-kvm", "11.0.0");
 
     DO_TEST_CAPS_VER("cpu-host-model-tcg", "6.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-tcg", "7.0.0");
@@ -2237,6 +2239,8 @@ mymain(void)
     DO_TEST_CAPS_VER("cpu-host-model-tcg", "9.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-tcg", "10.0.0");
     DO_TEST_CAPS_VER("cpu-host-model-tcg", "10.1.0");
+    DO_TEST_CAPS_VER("cpu-host-model-tcg", "10.2.0");
+    DO_TEST_CAPS_VER("cpu-host-model-tcg", "11.0.0");
 
     DO_TEST_CAPS_VER("cpu-host-model-fallback-kvm", "6.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-fallback-kvm", "7.0.0");
@@ -2250,6 +2254,8 @@ mymain(void)
     DO_TEST_CAPS_VER("cpu-host-model-fallback-kvm", "9.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-fallback-kvm", "10.0.0");
     DO_TEST_CAPS_VER("cpu-host-model-fallback-kvm", "10.1.0");
+    DO_TEST_CAPS_VER("cpu-host-model-fallback-kvm", "10.2.0");
+    DO_TEST_CAPS_VER("cpu-host-model-fallback-kvm", "11.0.0");
 
     DO_TEST_CAPS_VER("cpu-host-model-fallback-tcg", "6.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-fallback-tcg", "7.0.0");
@@ -2263,6 +2269,8 @@ mymain(void)
     DO_TEST_CAPS_VER("cpu-host-model-fallback-tcg", "9.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-fallback-tcg", "10.0.0");
     DO_TEST_CAPS_VER("cpu-host-model-fallback-tcg", "10.1.0");
+    DO_TEST_CAPS_VER("cpu-host-model-fallback-tcg", "10.2.0");
+    DO_TEST_CAPS_VER("cpu-host-model-fallback-tcg", "11.0.0");
 
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-kvm", "6.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-kvm", "7.0.0");
@@ -2276,6 +2284,8 @@ mymain(void)
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-kvm", "9.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-kvm", "10.0.0");
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-kvm", "10.1.0");
+    DO_TEST_CAPS_VER("cpu-host-model-nofallback-kvm", "10.2.0");
+    DO_TEST_CAPS_VER("cpu-host-model-nofallback-kvm", "11.0.0");
 
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-tcg", "6.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-tcg", "7.0.0");
@@ -2289,6 +2299,8 @@ mymain(void)
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-tcg", "9.2.0");
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-tcg", "10.0.0");
     DO_TEST_CAPS_VER("cpu-host-model-nofallback-tcg", "10.1.0");
+    DO_TEST_CAPS_VER("cpu-host-model-nofallback-tcg", "10.2.0");
+    DO_TEST_CAPS_VER("cpu-host-model-nofallback-tcg", "11.0.0");
 
     /* For this specific test we accept the increased likelihood of changes
      * if qemu updates the CPU model */
-- 
2.53.0
Re: [PATCH] qemuxmlconftest: Add new cpu host model expansions tests
Posted by Peter Krempa via Devel 1 week, 2 days ago
On Tue, May 05, 2026 at 14:55:20 +0200, Michal Privoznik via Devel wrote:
> From: Michal Privoznik <mprivozn@redhat.com>
> 
> In qemuxmlconftest there's a section which aim on testing
> 'host-model' cpu mode expansion. Since this depends on what QEMU
> reports (and thus can change with its version) we have a test
> case for each QEMU version supported. Unfortunately, when adding
> capabilities for new QEMUs this section was forgotten. Add

This reminds me to necromance and complete a series which would make it
easy to make these automatic. 

> missing test cases (10.2.0 and 11.0.0).
> 
> Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
> ---

Reviewed-by: Peter Krempa <pkrempa@redhat.com>