From df1c3e74aae92b6dff8571e787c06f6c0e3b72b6 Mon Sep 17 00:00:00 2001 From: Pavel Hrdina Date: Fri, 10 Jun 2016 17:42:56 +0200 Subject: [PATCH] virt-install: add a new guest feature GIC for ARM guests Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1334857 Signed-off-by: Pavel Hrdina --- man/virt-install.pod | 5 +++ .../compare/virt-install-aarch64-kvm-gic.xml | 33 +++++++++++++++++++ tests/clitest.py | 1 + virtinst/cli.py | 2 ++ 4 files changed, 41 insertions(+) create mode 100644 tests/cli-test-xml/compare/virt-install-aarch64-kvm-gic.xml diff --git a/man/virt-install.pod b/man/virt-install.pod index 05376936..0da93483 100644 --- a/man/virt-install.pod +++ b/man/virt-install.pod @@ -254,6 +254,11 @@ Allow the KVM hypervisor signature to be hidden from the guest Notify the guest that the host supports paravirtual spinlocks for example by exposing the pvticketlocks mechanism. +=item B<--features gic_version=2> + +This is relevant only for ARM architectures. Possible values are "host" or +version number. + =back Use --features=? to see a list of all available sub options. Complete details at L diff --git a/tests/cli-test-xml/compare/virt-install-aarch64-kvm-gic.xml b/tests/cli-test-xml/compare/virt-install-aarch64-kvm-gic.xml new file mode 100644 index 00000000..189373db --- /dev/null +++ b/tests/cli-test-xml/compare/virt-install-aarch64-kvm-gic.xml @@ -0,0 +1,33 @@ + + foobar + 00000000-1111-2222-3333-444444444444 + 65536 + 65536 + 1 + + hvm + /usr/share/AAVMF/AAVMF_CODE.fd + + + + + + + + destroy + restart + restart + + /usr/bin/qemu-system-aarch64 + + + + + + + + + + + + diff --git a/tests/clitest.py b/tests/clitest.py index 5d260783..cbf83a90 100644 --- a/tests/clitest.py +++ b/tests/clitest.py @@ -711,6 +711,7 @@ c.add_compare("--arch aarch64 --machine virt --boot kernel=/f19-arm.kernel,initr c.add_compare("--arch aarch64 --boot kernel=/f19-arm.kernel,initrd=/f19-arm.initrd,kernel_args=\"console=ttyAMA0,1234 rw root=/dev/vda3\",extra_args=foo --disk %(EXISTIMG1)s", "aarch64-machdefault") c.add_compare("--arch aarch64 --cdrom %(EXISTIMG2)s --boot loader=CODE.fd,nvram_template=VARS.fd --disk %(EXISTIMG1)s --cpu none --events on_crash=preserve,on_reboot=destroy,on_poweroff=restart", "aarch64-cdrom") c.add_compare("--connect %(URI-KVM-AARCH64)s --disk %(EXISTIMG1)s --import --os-variant fedora21", "aarch64-kvm-import") +c.add_compare("--connect %(URI-KVM-AARCH64)s --disk none --os-variant fedora23 --features gic_version=host", "aarch64-kvm-gic") # ppc64 tests c.add_compare("--arch ppc64 --machine pseries --boot network --disk %(EXISTIMG1)s --disk device=cdrom --os-variant fedora20 --network none", "ppc64-pseries-f20") diff --git a/virtinst/cli.py b/virtinst/cli.py index 7924b147..dc86bb7c 100644 --- a/virtinst/cli.py +++ b/virtinst/cli.py @@ -1545,6 +1545,8 @@ class ParserFeatures(VirtCLIParser): self.set_param("kvm_hidden", "kvm_hidden", is_onoff=True) self.set_param("pvspinlock", "pvspinlock", is_onoff=True) + self.set_param("gic_version", "gic_version") + ################### # --clock parsing #