From nobody Wed Nov 5 02:34:09 2025 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.zohomail.com; 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; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1531828079391430.64212150791116; Tue, 17 Jul 2018 04:47:59 -0700 (PDT) Received: from localhost ([::1]:58435 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ffOSM-0001R5-39 for importer@patchew.org; Tue, 17 Jul 2018 07:47:50 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45538) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ffOFd-0007Kf-Mw for qemu-devel@nongnu.org; Tue, 17 Jul 2018 07:34:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ffOFc-0003uO-R3 for qemu-devel@nongnu.org; Tue, 17 Jul 2018 07:34:41 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:48126 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ffOFc-0003to-Gz for qemu-devel@nongnu.org; Tue, 17 Jul 2018 07:34:40 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 1DD25402315B for ; Tue, 17 Jul 2018 11:34:40 +0000 (UTC) Received: from secure.mitica (ovpn-117-62.ams2.redhat.com [10.36.117.62]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0FDE3FF5B; Tue, 17 Jul 2018 11:34:38 +0000 (UTC) From: Juan Quintela To: qemu-devel@nongnu.org Date: Tue, 17 Jul 2018 13:33:55 +0200 Message-Id: <20180717113402.5510-19-quintela@redhat.com> In-Reply-To: <20180717113402.5510-1-quintela@redhat.com> References: <20180717113402.5510-1-quintela@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.11.54.5 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.6]); Tue, 17 Jul 2018 11:34:40 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.6]); Tue, 17 Jul 2018 11:34:40 +0000 (UTC) for IP:'10.11.54.5' DOMAIN:'int-mx05.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'quintela@redhat.com' RCPT:'' X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 66.187.233.73 Subject: [Qemu-devel] [PATCH 18/25] check: Only test pvpanic when it is compiled in 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: lvivier@redhat.com, dgilbert@redhat.com, peterx@redhat.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" There was not possible to compile out pvpanic. Use the same trick that applesmc. Signed-off-by: Juan Quintela Reviewed-by: Thomas Huth --- hw/misc/pvpanic.c | 11 ----------- include/hw/misc/pvpanic.h | 11 ++++++++++- tests/Makefile.include | 4 ++-- 3 files changed, 12 insertions(+), 14 deletions(-) diff --git a/hw/misc/pvpanic.c b/hw/misc/pvpanic.c index b26250dec9..9d8961ba0c 100644 --- a/hw/misc/pvpanic.c +++ b/hw/misc/pvpanic.c @@ -99,17 +99,6 @@ static void pvpanic_isa_realizefn(DeviceState *dev, Erro= r **errp) isa_register_ioport(d, &s->io, s->ioport); } =20 -#define PVPANIC_IOPORT_PROP "ioport" - -uint16_t pvpanic_port(void) -{ - Object *o =3D object_resolve_path_type("", TYPE_PVPANIC, NULL); - if (!o) { - return 0; - } - return object_property_get_uint(o, PVPANIC_IOPORT_PROP, NULL); -} - static Property pvpanic_isa_properties[] =3D { DEFINE_PROP_UINT16(PVPANIC_IOPORT_PROP, PVPanicState, ioport, 0x505), DEFINE_PROP_END_OF_LIST(), diff --git a/include/hw/misc/pvpanic.h b/include/hw/misc/pvpanic.h index 36a54e270c..1ee071a703 100644 --- a/include/hw/misc/pvpanic.h +++ b/include/hw/misc/pvpanic.h @@ -16,6 +16,15 @@ =20 #define TYPE_PVPANIC "pvpanic" =20 -uint16_t pvpanic_port(void); +#define PVPANIC_IOPORT_PROP "ioport" + +static inline uint16_t pvpanic_port(void) +{ + Object *o =3D object_resolve_path_type("", TYPE_PVPANIC, NULL); + if (!o) { + return 0; + } + return object_property_get_uint(o, PVPANIC_IOPORT_PROP, NULL); +} =20 #endif diff --git a/tests/Makefile.include b/tests/Makefile.include index f635517a68..31d124ee44 100644 --- a/tests/Makefile.include +++ b/tests/Makefile.include @@ -274,8 +274,8 @@ check-qtest-i386-$(CONFIG_VMXNET3_PCI) +=3D tests/vmxne= t3-test$(EXESUF) gcov-files-i386-$(CONFIG_VMXNET3_PCI) +=3D hw/net/vmxnet3.c gcov-files-i386-y +=3D hw/net/net_rx_pkt.c gcov-files-i386-y +=3D hw/net/net_tx_pkt.c -check-qtest-i386-y +=3D tests/pvpanic-test$(EXESUF) -gcov-files-i386-y +=3D i386-softmmu/hw/misc/pvpanic.c +check-qtest-i386-$(CONFIG_PVPANIC) +=3D tests/pvpanic-test$(EXESUF) +gcov-files-i386-$(CONFIG_PVPANIC) +=3D i386-softmmu/hw/misc/pvpanic.c check-qtest-i386-$(CONFIG_I82801B11) +=3D tests/i82801b11-test$(EXESUF) gcov-files-i386-$(CONFIG_I82801B11) +=3D hw/pci-bridge/i82801b11.c check-qtest-i386-$(CONFIG_IOH3420) +=3D tests/ioh3420-test$(EXESUF) --=20 2.17.1