From 837bbf2bd3eb6d90f76b6d1f362c5b32b250f603 Mon Sep 17 00:00:00 2001 From: Charles Arnold Date: Tue, 5 May 2020 09:25:09 -0600 Subject: [PATCH] Fix check for q35 machine type This fix could be included independent of the other patches. Reviewed-by: Cole Robinson --- virtinst/domain/launch_security.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/virtinst/domain/launch_security.py b/virtinst/domain/launch_security.py index 1d8410c15..6eb87add5 100644 --- a/virtinst/domain/launch_security.py +++ b/virtinst/domain/launch_security.py @@ -30,7 +30,7 @@ class DomainLaunchSecurity(XMLBuilder): # exercise for pc-i440fx to make SEV work, AMD recommends Q35 anyway # NOTE: at some point both of these platform checks should be put in # validate(), once that accepts the 'guest' instance - if guest.os.machine != "q35" or guest.os.loader_type != "pflash": + if guest.os.is_q35() is False or guest.os.loader_type != "pflash": raise RuntimeError(_("SEV launch security requires a Q35 UEFI machine")) # libvirt or QEMU might not support SEV