virt-manager/601a82cb-fix-console_type-if-xen.patch
Charles Arnold 2e04f0d659 - bsc#919420 - virt-manager: installation of vm on pp64le: Couldn't
find hvm kernel for SUSE tree.
  virtinst-add-ppc64-arch-support.patch
- Upstream bug fix to console if running on Xen
  601a82cb-fix-console_type-if-xen.patch

OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=269
2015-09-22 17:14:49 +00:00

64 lines
2.7 KiB
Diff

Subject: virt-install: Simplify --extra-args text install warnings
From: Cole Robinson crobinso@redhat.com Tue Sep 22 08:42:09 2015 -0400
Date: Tue Sep 22 12:44:33 2015 -0400:
Git: 601a82cb87ebc055ba9dd52864317bd513613814
- Drop the warnings about incorrect console=, that's a little too fine
grained and was really only about virtio-console default confusion
which doesn't apply anymore
- Skip the check for xenpv which seems to always 'just work'
- Drop the opencoded arm check, use is_arm
- Fix an error when xen HVM is used (reported on virt-tools-list)
diff --git a/virt-install b/virt-install
index ba9423e..d509256 100755
--- a/virt-install
+++ b/virt-install
@@ -513,35 +513,20 @@ def _show_nographics_warnings(options, guest):
serial_arg = "console=ttyS0"
serial_arm_arg = "console=ttyAMA0"
- virtio_arg = "console=hvc0"
- console_type = None
- if guest.conn.is_test() or guest.conn.is_qemu():
- console_type = serial_arg
- if guest.os.arch.startswith("arm") or guest.os.arch == "aarch64":
- console_type = serial_arm_arg
- if guest.get_devices("console")[0].target_type == "virtio":
- console_type = virtio_arg
-
- if not options.extra_args or "console=" not in options.extra_args:
- logging.warn(_("No 'console' seen in --extra-args, a '%s' kernel "
- "argument is likely required to see text install output from "
- "the guest."), console_type or "console=")
- return
+ hvc_arg = "console=hvc0"
- if console_type in options.extra_args:
- return
- if (serial_arg not in options.extra_args and
- virtio_arg not in options.extra_args):
+ console_type = serial_arg
+ if guest.os.is_arm():
+ console_type = serial_arm_arg
+ if guest.get_devices("console")[0].target_type in ["virtio", "xen"]:
+ console_type = hvc_arg
+
+ if console_type in (options.extra_args or ""):
return
- has = (serial_arg in options.extra_args) and serial_arg or virtio_arg
- need = (serial_arg in options.extra_args) and virtio_arg or serial_arg
- logging.warn(_("'%s' found in --extra-args, but the device attached "
- "to the guest likely requires '%s'. You may not see text install "
- "output from the guest."), has, need)
- if has == serial_arg:
- logging.warn(_("To make '--extra-args %s' work, you can force a "
- "plain serial device with '--console pty'"), serial_arg)
+ logging.warn(_("Did not find '%(console_string)s' in --extra-args, "
+ "which is likely required to see text install output from the "
+ "guest."), {"console_string": console_type})
def show_warnings(options, guest):