From nobody Mon Apr 29 21:51:57 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1490667525998394.45344113938427; Mon, 27 Mar 2017 19:18:45 -0700 (PDT) Received: from localhost ([::1]:49593 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1csgia-0000Tx-Pw for importer@patchew.org; Mon, 27 Mar 2017 22:18:44 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33333) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1csggy-0007oT-Iq for qemu-devel@nongnu.org; Mon, 27 Mar 2017 22:17:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1csggv-0004xK-EZ for qemu-devel@nongnu.org; Mon, 27 Mar 2017 22:17:04 -0400 Received: from ozlabs.org ([103.22.144.67]:47941) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1csggu-0004sd-RB; Mon, 27 Mar 2017 22:17:01 -0400 Received: by ozlabs.org (Postfix, from userid 1007) id 3vsZK341m3z9rxm; Tue, 28 Mar 2017 13:16:55 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gibson.dropbear.id.au; s=201602; t=1490667415; bh=9CgmXZssQP7vytd1eU5Ll7K3KsX7JLkz7ZMQugTW2dw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=m8P/CeVnashZPHRurHZkQ3m3XGw16+8VbrdT0s0YZXFOOJ0i3QgXKEnHeWLewm5vR NhKqB0DBfYNtN+TIO0F0Yg6Jr5pO0kdJmq9dT0sK+TbVVg0BwxMXLXITH+g92iEe3o dyLpC8pkyxFKt+uvlr2JEcCvKRadRfbAFP9pEY6U= From: David Gibson To: ehabkost@redhat.com, aik@ozlabs.ru, marcel@redhat.com Date: Tue, 28 Mar 2017 13:16:49 +1100 Message-Id: <20170328021651.19350-2-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20170328021651.19350-1-david@gibson.dropbear.id.au> References: <20170328021651.19350-1-david@gibson.dropbear.id.au> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 103.22.144.67 Subject: [Qemu-devel] [RFC for-2.10 1/3] pci/pcie: Make a consistent helper for switching PCI/PCIe "hybrid" devices X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: lersek@redhat.com, David Gibson , qemu-ppc@nongnu.org, qemu-devel@nongnu.org, mst@redhat.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" virtio-pci and XHCI are "hybrid" devices in the sense that they can present themselves as either PCIe or plain PCI devices depending on the machine and bus they're connected to. For virtio-pci to present as PCIe it requires that it's connected to a PCIe bus and that it's not a root bus - this is to ensure that the device is connected via a PCIe root port or downstream port rather than being a integrated endpoint. Some guests (Windows in particular AIUI) don't really cope with PCIe integrated endpoints. For XHCI it only checks that the bus is PCIe, but that probably means it would cause problems if attached as an integrated devices directly to a PCIe root bus. This patch makes the test consistent between XHCI and virtio-pci, and clarifies things by having them both use a new 'pci_allow_hybrid_pcie()' helper which performs the same check as virtio-pci. Signed-off-by: David Gibson --- hw/pci/pci.c | 7 +++++++ hw/usb/hcd-xhci.c | 2 +- hw/virtio/virtio-pci.c | 3 +-- include/hw/pci/pci.h | 1 + 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/hw/pci/pci.c b/hw/pci/pci.c index bd8043c..779787b 100644 --- a/hw/pci/pci.c +++ b/hw/pci/pci.c @@ -390,6 +390,13 @@ bool pci_bus_is_root(PCIBus *bus) return PCI_BUS_GET_CLASS(bus)->is_root(bus); } =20 +bool pci_allow_hybrid_pcie(PCIDevice *pci_dev) +{ + PCIBus *bus =3D pci_dev->bus; + + return pci_bus_is_express(bus) && !pci_bus_is_root(bus); +} + void pci_bus_new_inplace(PCIBus *bus, size_t bus_size, DeviceState *parent, const char *name, MemoryRegion *address_space_mem, diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c index f0af852..a7ff4fd 100644 --- a/hw/usb/hcd-xhci.c +++ b/hw/usb/hcd-xhci.c @@ -3619,7 +3619,7 @@ static void usb_xhci_realize(struct PCIDevice *dev, E= rror **errp) PCI_BASE_ADDRESS_SPACE_MEMORY|PCI_BASE_ADDRESS_MEM_TY= PE_64, &xhci->mem); =20 - if (pci_bus_is_express(dev->bus) || + if (pci_allow_hybrid_pcie(dev) || xhci_get_flag(xhci, XHCI_FLAG_FORCE_PCIE_ENDCAP)) { ret =3D pcie_endpoint_cap_init(dev, 0xa0); assert(ret >=3D 0); diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index f9b7244..9b34673 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virtio/virtio-pci.c @@ -1737,8 +1737,7 @@ static void virtio_pci_realize(PCIDevice *pci_dev, Er= ror **errp) { VirtIOPCIProxy *proxy =3D VIRTIO_PCI(pci_dev); VirtioPCIClass *k =3D VIRTIO_PCI_GET_CLASS(pci_dev); - bool pcie_port =3D pci_bus_is_express(pci_dev->bus) && - !pci_bus_is_root(pci_dev->bus); + bool pcie_port =3D pci_allow_hybrid_pcie(pci_dev); =20 if (!kvm_has_many_ioeventfds()) { proxy->flags &=3D ~VIRTIO_PCI_FLAG_USE_IOEVENTFD; diff --git a/include/hw/pci/pci.h b/include/hw/pci/pci.h index a37a2d5..7b9a40f 100644 --- a/include/hw/pci/pci.h +++ b/include/hw/pci/pci.h @@ -453,6 +453,7 @@ void pci_for_each_bus(PCIBus *bus, =20 PCIBus *pci_find_primary_bus(void); PCIBus *pci_device_root_bus(const PCIDevice *d); +bool pci_allow_hybrid_pcie(PCIDevice *pci_dev); const char *pci_root_bus_path(PCIDevice *dev); PCIDevice *pci_find_device(PCIBus *bus, int bus_num, uint8_t devfn); int pci_qdev_find_device(const char *id, PCIDevice **pdev); --=20 2.9.3 From nobody Mon Apr 29 21:51:57 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1490667606312642.0180732460839; Mon, 27 Mar 2017 19:20:06 -0700 (PDT) Received: from localhost ([::1]:49597 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1csgjs-0001Tb-Re for importer@patchew.org; Mon, 27 Mar 2017 22:20:04 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33332) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1csggy-0007oS-Ij for qemu-devel@nongnu.org; Mon, 27 Mar 2017 22:17:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1csggv-0004xC-EI for qemu-devel@nongnu.org; Mon, 27 Mar 2017 22:17:04 -0400 Received: from ozlabs.org ([103.22.144.67]:36023) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1csggu-0004sv-Qz; Mon, 27 Mar 2017 22:17:01 -0400 Received: by ozlabs.org (Postfix, from userid 1007) id 3vsZK34zq8z9s7N; Tue, 28 Mar 2017 13:16:55 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gibson.dropbear.id.au; s=201602; t=1490667415; bh=aW8EnDLyQumnsMFPuDf4FxVN4qlRO5O/gJJ6wof2JmI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Oy5x/opOFwW6hPqpFIgL7o1scgo1E1z/eg2EzHj994oUe392vTsKTS6khQ+HLJOal fJ8dWjek6TzDj3F8vwutqqyRt083pG16I42Gtu1Ueu93oPWP7gQKDDiMyYhWeiFRYi m9nF8FrPY0yhiL60H/rnL+TEBDFQ3qButJHwLCMI= From: David Gibson To: ehabkost@redhat.com, aik@ozlabs.ru, marcel@redhat.com Date: Tue, 28 Mar 2017 13:16:50 +1100 Message-Id: <20170328021651.19350-3-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20170328021651.19350-1-david@gibson.dropbear.id.au> References: <20170328021651.19350-1-david@gibson.dropbear.id.au> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 103.22.144.67 Subject: [Qemu-devel] [RFC for-2.10 2/3] pci: Allow host bridges to override PCI/PCIe hybrid device behaviour X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: lersek@redhat.com, David Gibson , qemu-ppc@nongnu.org, qemu-devel@nongnu.org, mst@redhat.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Currently PCI/PCIe hybrid devices - that is, devices which can appear as either plain PCI or PCIe depending on where they're attached - will only appear in PCIe mode if they're attached to a PCIe bus via a root port or downstream port. This is correct for "standard" PCIe setups, but there are some platforms which need different behaviour (notably "pseries" whose paravirtualized PCI host bridges have some idiosyncracies). This patch allows the host bridge to override the normal behaviour. Signed-off-by: David Gibson Reviewed-by: Eduardo Habkost --- hw/pci/pci.c | 11 +++++++++-- include/hw/pci/pci_host.h | 1 + 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/hw/pci/pci.c b/hw/pci/pci.c index 779787b..ac68065 100644 --- a/hw/pci/pci.c +++ b/hw/pci/pci.c @@ -392,9 +392,16 @@ bool pci_bus_is_root(PCIBus *bus) =20 bool pci_allow_hybrid_pcie(PCIDevice *pci_dev) { - PCIBus *bus =3D pci_dev->bus; + PCIHostState *host_bridge =3D PCI_HOST_BRIDGE(pci_device_root_bus(pci_= dev)->qbus.parent); + PCIHostBridgeClass *hc =3D PCI_HOST_BRIDGE_GET_CLASS(host_bridge); + + if (hc->allow_hybrid_pcie) { + return hc->allow_hybrid_pcie(host_bridge, pci_dev); + } else { + PCIBus *bus =3D pci_dev->bus; =20 - return pci_bus_is_express(bus) && !pci_bus_is_root(bus); + return pci_bus_is_express(bus) && !pci_bus_is_root(bus); + } } =20 void pci_bus_new_inplace(PCIBus *bus, size_t bus_size, DeviceState *parent, diff --git a/include/hw/pci/pci_host.h b/include/hw/pci/pci_host.h index ba31595..ad03cca 100644 --- a/include/hw/pci/pci_host.h +++ b/include/hw/pci/pci_host.h @@ -54,6 +54,7 @@ typedef struct PCIHostBridgeClass { SysBusDeviceClass parent_class; =20 const char *(*root_bus_path)(PCIHostState *, PCIBus *); + bool (*allow_hybrid_pcie)(PCIHostState *, PCIDevice *); } PCIHostBridgeClass; =20 /* common internal helpers for PCI/PCIe hosts, cut off overflows */ --=20 2.9.3 From nobody Mon Apr 29 21:51:57 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1490667629551645.3218644607886; Mon, 27 Mar 2017 19:20:29 -0700 (PDT) Received: from localhost ([::1]:49602 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1csgkG-0001ms-Br for importer@patchew.org; Mon, 27 Mar 2017 22:20:28 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33311) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1csggw-0007oR-Lz for qemu-devel@nongnu.org; Mon, 27 Mar 2017 22:17:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1csggv-0004xB-EK for qemu-devel@nongnu.org; Mon, 27 Mar 2017 22:17:02 -0400 Received: from ozlabs.org ([2401:3900:2:1::2]:59647) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1csggu-0004tP-T6; Mon, 27 Mar 2017 22:17:01 -0400 Received: by ozlabs.org (Postfix, from userid 1007) id 3vsZK36l7bz9s7Z; Tue, 28 Mar 2017 13:16:55 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gibson.dropbear.id.au; s=201602; t=1490667415; bh=TpKn7j300ttG+s4ytHVQ/yKl5/kYMs/dxYqi53uT9vc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QSJdbbnm3I8a3isDA9+hHPezhpH5aIxgqPZJYmSPkTsyUpKl2D2oGVeL8B8qCRqzq mzm0G7vxHm6Lpig0XWegilApqwSaxplZe7Fx163PK7PQ/+HMT+r7JHR/E1sRtWu+JC HnlC64Fe9XoS6D4oZ3Ln8xwvJzzUzahl+hr4Oaw4= From: David Gibson To: ehabkost@redhat.com, aik@ozlabs.ru, marcel@redhat.com Date: Tue, 28 Mar 2017 13:16:51 +1100 Message-Id: <20170328021651.19350-4-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20170328021651.19350-1-david@gibson.dropbear.id.au> References: <20170328021651.19350-1-david@gibson.dropbear.id.au> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2401:3900:2:1::2 Subject: [Qemu-devel] [RFC for-2.10 3/3] pseries: Allow PCIe virtio and XHCI on pseries machine type X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: lersek@redhat.com, David Gibson , qemu-ppc@nongnu.org, qemu-devel@nongnu.org, mst@redhat.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" pseries now allows PCIe devices (both emulated and VFIO), although its PCI bus is in most respects a plain PCI bus - this uses paravirtualized access methods to PCIe extended config space defined in the PAPR spec. However, because the bus is not PCIe, it means that virtio-pci and XHCI devices will present themselves as plain PCI rather than PCIe, which would be preferable. This patch uses the new hook to override the behaviour for such PCI/PCIe "hybrid" devices to allow PCIe virtio-pci and XHCI on pseries. Signed-off-by: David Gibson --- hw/ppc/spapr_pci.c | 9 +++++++++ tests/virtio-9p-test.c | 2 +- tests/virtio-blk-test.c | 4 ++-- tests/virtio-net-test.c | 2 +- tests/virtio-scsi-test.c | 2 +- 5 files changed, 14 insertions(+), 5 deletions(-) diff --git a/hw/ppc/spapr_pci.c b/hw/ppc/spapr_pci.c index 98c52e4..7686f7f 100644 --- a/hw/ppc/spapr_pci.c +++ b/hw/ppc/spapr_pci.c @@ -1979,6 +1979,14 @@ static const char *spapr_phb_root_bus_path(PCIHostSt= ate *host_bridge, return sphb->dtbusname; } =20 +static bool spapr_phb_allow_hybrid_pcie(PCIHostState *host_bridge, + PCIDevice *pci_dev) +{ + sPAPRPHBState *sphb =3D SPAPR_PCI_HOST_BRIDGE(host_bridge); + + return sphb->pcie_ecs; +} + static void spapr_phb_class_init(ObjectClass *klass, void *data) { PCIHostBridgeClass *hc =3D PCI_HOST_BRIDGE_CLASS(klass); @@ -1986,6 +1994,7 @@ static void spapr_phb_class_init(ObjectClass *klass, = void *data) HotplugHandlerClass *hp =3D HOTPLUG_HANDLER_CLASS(klass); =20 hc->root_bus_path =3D spapr_phb_root_bus_path; + hc->allow_hybrid_pcie =3D spapr_phb_allow_hybrid_pcie; dc->realize =3D spapr_phb_realize; dc->props =3D spapr_phb_properties; dc->reset =3D spapr_phb_reset; diff --git a/tests/virtio-9p-test.c b/tests/virtio-9p-test.c index 43a1ad8..ae0d51e 100644 --- a/tests/virtio-9p-test.c +++ b/tests/virtio-9p-test.c @@ -32,7 +32,7 @@ static QVirtIO9P *qvirtio_9p_start(const char *driver) { const char *arch =3D qtest_get_arch(); const char *cmd =3D "-fsdev local,id=3Dfsdev0,security_model=3Dnone,pa= th=3D%s " - "-device %s,fsdev=3Dfsdev0,mount_tag=3D%s"; + "-device %s,fsdev=3Dfsdev0,mount_tag=3D%s,disable-le= gacy=3Doff"; QVirtIO9P *v9p =3D g_new0(QVirtIO9P, 1); =20 v9p->test_share =3D g_strdup("/tmp/qtest.XXXXXX"); diff --git a/tests/virtio-blk-test.c b/tests/virtio-blk-test.c index 1eee95d..5fb7882 100644 --- a/tests/virtio-blk-test.c +++ b/tests/virtio-blk-test.c @@ -65,7 +65,7 @@ static QOSState *pci_test_start(void) const char *cmd =3D "-drive if=3Dnone,id=3Ddrive0,file=3D%s,format=3Dr= aw " "-drive if=3Dnone,id=3Ddrive1,file=3D/dev/null,forma= t=3Draw " "-device virtio-blk-pci,id=3Ddrv0,drive=3Ddrive0," - "addr=3D%x.%x"; + "addr=3D%x.%x,disable-legacy=3Doff"; =20 tmp_path =3D drive_create(); =20 @@ -656,7 +656,7 @@ static void pci_hotplug(void) =20 /* plug secondary disk */ qpci_plug_device_test("virtio-blk-pci", "drv1", PCI_SLOT_HP, - "'drive': 'drive1'"); + "'drive': 'drive1', 'disable-legacy': 'off'"); =20 dev =3D virtio_blk_pci_init(qs->pcibus, PCI_SLOT_HP); g_assert(dev); diff --git a/tests/virtio-net-test.c b/tests/virtio-net-test.c index 8f94360..a35d87b 100644 --- a/tests/virtio-net-test.c +++ b/tests/virtio-net-test.c @@ -55,7 +55,7 @@ static QOSState *pci_test_start(int socket) { const char *arch =3D qtest_get_arch(); const char *cmd =3D "-netdev socket,fd=3D%d,id=3Dhs0 -device " - "virtio-net-pci,netdev=3Dhs0"; + "virtio-net-pci,netdev=3Dhs0,disable-legacy=3Doff"; =20 if (strcmp(arch, "i386") =3D=3D 0 || strcmp(arch, "x86_64") =3D=3D 0) { return qtest_pc_boot(cmd, socket); diff --git a/tests/virtio-scsi-test.c b/tests/virtio-scsi-test.c index 0eabd56..5a802d9 100644 --- a/tests/virtio-scsi-test.c +++ b/tests/virtio-scsi-test.c @@ -36,7 +36,7 @@ static QOSState *qvirtio_scsi_start(const char *extra_opt= s) { const char *arch =3D qtest_get_arch(); const char *cmd =3D "-drive id=3Ddrv0,if=3Dnone,file=3D/dev/null,forma= t=3Draw " - "-device virtio-scsi-pci,id=3Dvs0 " + "-device virtio-scsi-pci,id=3Dvs0,disable-legacy=3Do= ff " "-device scsi-hd,bus=3Dvs0.0,drive=3Ddrv0 %s"; =20 if (strcmp(arch, "i386") =3D=3D 0 || strcmp(arch, "x86_64") =3D=3D 0) { --=20 2.9.3