summaryrefslogtreecommitdiff
path: root/virtinst/guest.py
diff options
context:
space:
mode:
authorCole Robinson <crobinso@redhat.com>2019-07-12 15:58:22 -0400
committerCole Robinson <crobinso@redhat.com>2019-07-12 16:01:21 -0400
commit0c223ab21f0cff216b4a1ab2070a43f0e943d308 (patch)
tree8a87cc7d433ddad3fe494a20c860b622fd32a896 /virtinst/guest.py
parente5980863ddc41220f984f95bfeddf74407d19c72 (diff)
downloadvirt-manager-0c223ab21f0cff216b4a1ab2070a43f0e943d308.tar.gz
guest: Don't set default uefi if firmware= is set
Diffstat (limited to 'virtinst/guest.py')
-rw-r--r--virtinst/guest.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/virtinst/guest.py b/virtinst/guest.py
index 41357644..f0fcfe7d 100644
--- a/virtinst/guest.py
+++ b/virtinst/guest.py
@@ -561,8 +561,9 @@ class Guest(XMLBuilder):
return path
def is_uefi(self):
- return bool(self.os.loader and
- self.os.loader_type == "pflash")
+ if self.os.loader and self.os.loader_type == "pflash":
+ return True
+ return self.os.firmware == "efi"
def set_uefi_path(self, path):
"""
@@ -781,11 +782,13 @@ class Guest(XMLBuilder):
not self.os.kernel and
not self.os.loader and
self.os.loader_ro is None and
- self.os.nvram is None)
+ self.os.nvram is None and
+ self.os.firmware is None)
if use_default_uefi or self.uefi_requested:
try:
path = self.get_uefi_path()
+ log.debug("Setting UEFI path=%s", path)
self.set_uefi_path(path)
except RuntimeError as e:
if self.uefi_requested: