]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
tests: check e820_host option handling
authorMarek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Tue, 14 Apr 2020 02:37:07 +0000 (04:37 +0200)
committerJim Fehlig <jfehlig@suse.com>
Tue, 21 Apr 2020 15:06:09 +0000 (09:06 -0600)
Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Jim Fehlig <jfehlig@suse.com>
tests/xlconfigdata/test-paravirt-e820_host.cfg [new file with mode: 0644]
tests/xlconfigdata/test-paravirt-e820_host.xml [new file with mode: 0644]
tests/xlconfigtest.c

diff --git a/tests/xlconfigdata/test-paravirt-e820_host.cfg b/tests/xlconfigdata/test-paravirt-e820_host.cfg
new file mode 100644 (file)
index 0000000..b9e5a48
--- /dev/null
@@ -0,0 +1,13 @@
+name = "XenGuest1"
+uuid = "45b60f51-88a9-47a8-a3b3-5e66d71b2283"
+maxmem = 512
+memory = 512
+vcpus = 4
+e820_host = 1
+localtime = 0
+on_poweroff = "preserve"
+on_reboot = "restart"
+on_crash = "preserve"
+vif = [ "mac=5a:36:0e:be:00:09" ]
+bootloader = "/usr/bin/pygrub"
+disk = [ "format=qcow2,vdev=xvda,access=rw,backendtype=qdisk,target=/var/lib/xen/images/debian/disk.qcow2" ]
diff --git a/tests/xlconfigdata/test-paravirt-e820_host.xml b/tests/xlconfigdata/test-paravirt-e820_host.xml
new file mode 100644 (file)
index 0000000..955a780
--- /dev/null
@@ -0,0 +1,37 @@
+<domain type='xen'>
+  <name>XenGuest1</name>
+  <uuid>45b60f51-88a9-47a8-a3b3-5e66d71b2283</uuid>
+  <memory unit='KiB'>524288</memory>
+  <currentMemory unit='KiB'>524288</currentMemory>
+  <vcpu placement='static'>4</vcpu>
+  <bootloader>/usr/bin/pygrub</bootloader>
+  <os>
+    <type arch='x86_64' machine='xenpv'>linux</type>
+  </os>
+  <features>
+    <xen>
+      <e820_host state='on'/>
+    </xen>
+  </features>
+  <clock offset='utc' adjustment='reset'/>
+  <on_poweroff>preserve</on_poweroff>
+  <on_reboot>restart</on_reboot>
+  <on_crash>preserve</on_crash>
+  <devices>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='qcow2'/>
+      <source file='/var/lib/xen/images/debian/disk.qcow2'/>
+      <target dev='xvda' bus='xen'/>
+    </disk>
+    <controller type='xenbus' index='0'/>
+    <interface type='ethernet'>
+      <mac address='5a:36:0e:be:00:09'/>
+    </interface>
+    <console type='pty'>
+      <target type='xen' port='0'/>
+    </console>
+    <input type='mouse' bus='xen'/>
+    <input type='keyboard' bus='xen'/>
+    <memballoon model='xen'/>
+  </devices>
+</domain>
index 8faef16ddf532f207bc7160530ba8f506b4ed9bb..8ea250347b925d1d231171fe4a44f00ec4f04b1d 100644 (file)
@@ -300,6 +300,7 @@ mymain(void)
     DO_TEST("vif-multi-ip");
     DO_TEST("usb");
     DO_TEST("usbctrl");
+    DO_TEST("paravirt-e820_host");
 
     testXLFreeDriver(driver);