From nobody Wed May 14 19:57:06 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1522245980239854.3242178452349; Wed, 28 Mar 2018 07:06:20 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C1CCB3AA1B; Wed, 28 Mar 2018 14:06:18 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 49AA560BE7; Wed, 28 Mar 2018 14:06:18 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 018CC181B9FF; Wed, 28 Mar 2018 14:06:18 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w2SE6GbB027704 for ; Wed, 28 Mar 2018 10:06:16 -0400 Received: by smtp.corp.redhat.com (Postfix) id B0EFA215CDC7; Wed, 28 Mar 2018 14:06:16 +0000 (UTC) Received: from inaba.usersys.redhat.com (ovpn-204-126.brq.redhat.com [10.40.204.126]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 304CE215CDC5 for ; Wed, 28 Mar 2018 14:06:15 +0000 (UTC) From: Andrea Bolognani To: libvir-list@redhat.com Date: Wed, 28 Mar 2018 16:06:01 +0200 Message-Id: <20180328140610.8414-3-abologna@redhat.com> In-Reply-To: <20180328140610.8414-1-abologna@redhat.com> References: <20180328140610.8414-1-abologna@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 02/11] tests: Add aarch64-traditional-pci test X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Wed, 28 Mar 2018 14:06:19 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" This test shows what happens when you add a traditional PCI device such as pci-serial to a pure PCIe machine type such as aarch64/virt. Signed-off-by: Andrea Bolognani Reviewed-by: John Ferlan --- .../qemuxml2argvdata/aarch64-traditional-pci.args | 26 +++++++++++++ tests/qemuxml2argvdata/aarch64-traditional-pci.xml | 19 ++++++++++ tests/qemuxml2argvtest.c | 8 ++++ .../qemuxml2xmloutdata/aarch64-traditional-pci.xml | 43 ++++++++++++++++++= ++++ tests/qemuxml2xmltest.c | 8 ++++ 5 files changed, 104 insertions(+) create mode 100644 tests/qemuxml2argvdata/aarch64-traditional-pci.args create mode 100644 tests/qemuxml2argvdata/aarch64-traditional-pci.xml create mode 100644 tests/qemuxml2xmloutdata/aarch64-traditional-pci.xml diff --git a/tests/qemuxml2argvdata/aarch64-traditional-pci.args b/tests/qe= muxml2argvdata/aarch64-traditional-pci.args new file mode 100644 index 0000000000..f10252f729 --- /dev/null +++ b/tests/qemuxml2argvdata/aarch64-traditional-pci.args @@ -0,0 +1,26 @@ +LC_ALL=3DC \ +PATH=3D/bin \ +HOME=3D/home/test \ +USER=3Dtest \ +LOGNAME=3Dtest \ +QEMU_AUDIO_DRV=3Dnone \ +/usr/bin/qemu-system-aarch64 \ +-name guest \ +-S \ +-M virt \ +-m 1024 \ +-smp 1,sockets=3D1,cores=3D1,threads=3D1 \ +-uuid 496d7ea8-9739-544b-4ebd-ef08be936e8b \ +-nographic \ +-nodefconfig \ +-nodefaults \ +-chardev socket,id=3Dcharmonitor,path=3D/tmp/lib/domain--1-guest/monitor.s= ock,\ +server,nowait \ +-mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dreadline \ +-no-acpi \ +-boot c \ +-device i82801b11-bridge,id=3Dpci.1,bus=3Dpcie.0,addr=3D0x1 \ +-device pci-bridge,chassis_nr=3D2,id=3Dpci.2,bus=3Dpci.1,addr=3D0x0 \ +-device pcie-root-port,port=3D0x10,chassis=3D3,id=3Dpci.3,bus=3Dpcie.0,add= r=3D0x2 \ +-chardev pty,id=3Dcharserial0 \ +-device pci-serial,chardev=3Dcharserial0,id=3Dserial0,bus=3Dpci.2,addr=3D0= x1 diff --git a/tests/qemuxml2argvdata/aarch64-traditional-pci.xml b/tests/qem= uxml2argvdata/aarch64-traditional-pci.xml new file mode 100644 index 0000000000..8c87a27f6e --- /dev/null +++ b/tests/qemuxml2argvdata/aarch64-traditional-pci.xml @@ -0,0 +1,19 @@ + + guest + 496d7ea8-9739-544b-4ebd-ef08be936e8b + 1048576 + 1 + + hvm + + + /usr/bin/qemu-system-aarch64 + + + + + + + + diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index 308d71f725..9a0d01e4f4 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -2705,6 +2705,14 @@ mymain(void) QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, QEMU_CAPS_DEVICE_PCIE_ROOT_PORT); + DO_TEST("aarch64-traditional-pci", + QEMU_CAPS_NODEFCONFIG, + QEMU_CAPS_OBJECT_GPEX, + QEMU_CAPS_PCI_MULTIFUNCTION, + QEMU_CAPS_DEVICE_PCIE_ROOT_PORT, + QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, + QEMU_CAPS_DEVICE_PCI_BRIDGE, + QEMU_CAPS_DEVICE_PCI_SERIAL); =20 /* Make sure all combinations of ACPI and UEFI behave as expected */ DO_TEST("aarch64-acpi-uefi", NONE); diff --git a/tests/qemuxml2xmloutdata/aarch64-traditional-pci.xml b/tests/q= emuxml2xmloutdata/aarch64-traditional-pci.xml new file mode 100644 index 0000000000..70664aa4f9 --- /dev/null +++ b/tests/qemuxml2xmloutdata/aarch64-traditional-pci.xml @@ -0,0 +1,43 @@ + + guest + 496d7ea8-9739-544b-4ebd-ef08be936e8b + 1048576 + 1048576 + 1 + + hvm + + + + + + + destroy + restart + destroy + + /usr/bin/qemu-system-aarch64 + + + +
+ + + + +
+ + + + +
+ + + + + +
+ + + + diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c index 0f560290a0..49b61d7647 100644 --- a/tests/qemuxml2xmltest.c +++ b/tests/qemuxml2xmltest.c @@ -1117,6 +1117,14 @@ mymain(void) QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, QEMU_CAPS_DEVICE_PCIE_ROOT_PORT); + DO_TEST("aarch64-traditional-pci", + QEMU_CAPS_NODEFCONFIG, + QEMU_CAPS_OBJECT_GPEX, + QEMU_CAPS_PCI_MULTIFUNCTION, + QEMU_CAPS_DEVICE_PCIE_ROOT_PORT, + QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, + QEMU_CAPS_DEVICE_PCI_BRIDGE, + QEMU_CAPS_DEVICE_PCI_SERIAL); DO_TEST("aarch64-video-default", QEMU_CAPS_NODEFCONFIG, QEMU_CAPS_OBJECT_GPEX, --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list