[libvirt] [PATCH] qemu: tolerate panic device on S390

Boris Fiuczynski fiuczy at linux.vnet.ibm.com
Wed Mar 23 13:56:03 UTC 2016


If a panic device is being defined without a model in a domain
the default value is always overwritten with model ISA. An ISA
bus does not exist on S390 and therefore specifying a panic device
results in an unsupported configuration.
Since the s390 architecture inherently provides a crash detection
capability the panic device should be tolerated in the domain xml.

This patch achieves the toleration by setting the model to the
default value in case the architecture is S390.

Signed-off-by: Boris Fiuczynski <fiuczy at linux.vnet.ibm.com>
Reviewed-by: Cornelia Huck <cornelia.huck at de.ibm.com>
---
 src/qemu/qemu_domain.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index 9f9fae3..96561c0 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -1605,6 +1605,9 @@ qemuDomainDeviceDefPostParse(virDomainDeviceDefPtr dev,
         if (ARCH_IS_PPC64(def->os.arch) &&
             STRPREFIX(def->os.machine, "pseries"))
             dev->data.panic->model = VIR_DOMAIN_PANIC_MODEL_PSERIES;
+        else if (ARCH_IS_S390(def->os.arch))
+            /* since S390 does not support ISA use default for toleration */
+            dev->data.panic->model = VIR_DOMAIN_PANIC_MODEL_DEFAULT;
         else
             dev->data.panic->model = VIR_DOMAIN_PANIC_MODEL_ISA;
     }
-- 
2.5.0




More information about the libvir-list mailing list