From patchwork Mon Jan 25 17:10:49 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ian Campbell X-Patchwork-Id: 8113191 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id C09B79F859 for ; Mon, 25 Jan 2016 17:13:54 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E5535202AE for ; Mon, 25 Jan 2016 17:13:53 +0000 (UTC) Received: from lists.xen.org (lists.xenproject.org [50.57.142.19]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1527A2026F for ; Mon, 25 Jan 2016 17:13:53 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aNkfJ-0000I8-Ep; Mon, 25 Jan 2016 17:10:57 +0000 Received: from mail6.bemta4.messagelabs.com ([85.158.143.247]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aNkfH-0000Hi-Hn for xen-devel@lists.xen.org; Mon, 25 Jan 2016 17:10:55 +0000 Received: from [85.158.143.35] by server-2.bemta-4.messagelabs.com id CA/DD-08977-E1756A65; Mon, 25 Jan 2016 17:10:54 +0000 X-Env-Sender: prvs=825142af3=Ian.Campbell@citrix.com X-Msg-Ref: server-6.tower-21.messagelabs.com!1453741852!12017531!1 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 7.35.1; banners=-,-,- X-VirusChecked: Checked Received: (qmail 14824 invoked from network); 25 Jan 2016 17:10:54 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-6.tower-21.messagelabs.com with RC4-SHA encrypted SMTP; 25 Jan 2016 17:10:54 -0000 X-IronPort-AV: E=Sophos;i="5.22,345,1449532800"; d="scan'208";a="333814204" From: Ian Campbell To: , , Date: Mon, 25 Jan 2016 17:10:49 +0000 Message-ID: <1453741849-5484-2-git-send-email-ian.campbell@citrix.com> X-Mailer: git-send-email 2.6.1 MIME-Version: 1.0 X-DLP: MIA1 Cc: Olaf Hering , Boris Ostrovsky , Ian Campbell Subject: [Xen-devel] [PATCH 2/2] tools: avoid redefinining xenevtchn_handle typedef for xc_suspend_* X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Similar to the previous xentoollog case this is not allowed. Switch to a forward decl of the struct and use of it in the APIs. Signed-off-by: Ian Campbell Acked-by: Ian Jackson Tested-by: Boris Ostrovsky Tested-by: Olaf Hering --- tools/libxc/include/xenguest.h | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/tools/libxc/include/xenguest.h b/tools/libxc/include/xenguest.h index 050a537..d48b3ff 100644 --- a/tools/libxc/include/xenguest.h +++ b/tools/libxc/include/xenguest.h @@ -38,7 +38,7 @@ * User not using xc_suspend_* / xc_await_suspent may not want to * include the full libxenevtchn API here. */ -typedef struct xenevtchn_handle xenevtchn_handle; +struct xenevtchn_handle; /* callbacks provided by xc_domain_save */ struct save_callbacks { @@ -167,18 +167,22 @@ struct xc_hvm_firmware_module { * Sets *lockfd to -1. * Has deallocated everything even on error. */ -int xc_suspend_evtchn_release(xc_interface *xch, xenevtchn_handle *xce, int domid, int suspend_evtchn, int *lockfd); +int xc_suspend_evtchn_release(xc_interface *xch, + struct xenevtchn_handle *xce, + int domid, int suspend_evtchn, int *lockfd); /** * This function eats the initial notification. * xce must not be used for anything else * See xc_suspend_evtchn_init_sane re lockfd. */ -int xc_suspend_evtchn_init_exclusive(xc_interface *xch, xenevtchn_handle *xce, +int xc_suspend_evtchn_init_exclusive(xc_interface *xch, + struct xenevtchn_handle *xce, int domid, int port, int *lockfd); /* xce must not be used for anything else */ -int xc_await_suspend(xc_interface *xch, xenevtchn_handle *xce, int suspend_evtchn); +int xc_await_suspend(xc_interface *xch, struct xenevtchn_handle *xce, + int suspend_evtchn); /** * The port will be signaled immediately after this call @@ -187,7 +191,8 @@ int xc_await_suspend(xc_interface *xch, xenevtchn_handle *xce, int suspend_evtch * and fed to xc_suspend_evtchn_release. (On error *lockfd is * undefined and xc_suspend_evtchn_release is not allowed.) */ -int xc_suspend_evtchn_init_sane(xc_interface *xch, xenevtchn_handle *xce, +int xc_suspend_evtchn_init_sane(xc_interface *xch, + struct xenevtchn_handle *xce, int domid, int port, int *lockfd); int xc_mark_page_online(xc_interface *xch, unsigned long start,