From patchwork Thu May 18 17:10:02 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Liu X-Patchwork-Id: 9734917 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 01FE7601C8 for ; Thu, 18 May 2017 17:19:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D9744288C7 for ; Thu, 18 May 2017 17:19:00 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CE6A1288D0; Thu, 18 May 2017 17:19:00 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 4185E288CD for ; Thu, 18 May 2017 17:18:59 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dBP2W-0004PC-VR; Thu, 18 May 2017 17:16:40 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dBP2V-0004ME-5G for xen-devel@lists.xenproject.org; Thu, 18 May 2017 17:16:39 +0000 Received: from [85.158.139.211] by server-15.bemta-5.messagelabs.com id 40/FE-01730-6F6DD195; Thu, 18 May 2017 17:16:38 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpgkeJIrShJLcpLzFFi42JxWrohUvfrNdl Igx+XLC2+b5nM5MDocfjDFZYAxijWzLyk/IoE1oyZM1wL3nFVNH1Pb2C8ydHFyMkhIeAvMfXx XhYQm01AWeJnZy8biC0ioCfRdOA5I4jNLJAncXb1IlYQW1ggSOLMzAdgcRYBVYmWqZ1AvRwcv AKWEtOmhkOMlJfY1XaRFSTMCRR+cNQFJCwkYCGx9+F6ZghbQaJj+jEmEJtXQFDi5MwnLBCbJC QOvnjBPIGRdxaS1CwkqQWMTKsY1YtTi8pSi3QN9ZKKMtMzSnITM3N0DQ1M9XJTi4sT01NzEpO K9ZLzczcxAkOmnoGBcQdjU6/zIUZJDiYlUd7DBbKRQnxJ+SmVGYnFGfFFpTmpxYcYZTg4lCR4 q68C5QSLUtNTK9Iyc4DBC5OW4OBREuE9BJLmLS5IzC3OTIdInWJUlBLn3Q2SEABJZJTmwbXBI uYSo6yUMC8jAwODEE9BalFuZgmq/CtGcQ5GJaAKYPwJ8WTmlcBNfwW0mAlocfMDaZDFJYkIKa kGxiotzWuu0uy+m2Lia5RO7dyxSGr+Hlet1mr3zUGWaYGB7huD5lt0OxtISy1pPpC4I8GK+ZJ JyqMNyyc+/sJTUVq1T/vqtTK1rnO83xd1r/Vzn8ob8Fbz2P3uujO21x7Zero0SvZv1Mz8NdWr Xtr25c2kTdcibYPZ1BxsbV3SWX7dd9aZcPWdEktxRqKhFnNRcSIAh3UbepMCAAA= X-Env-Sender: prvs=304fe0a9c=wei.liu2@citrix.com X-Msg-Ref: server-6.tower-206.messagelabs.com!1495127794!98835104!1 X-Originating-IP: [66.165.176.89] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni44OSA9PiAyMDMwMDc=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 9.4.12; banners=-,-,- X-VirusChecked: Checked Received: (qmail 59785 invoked from network); 18 May 2017 17:16:37 -0000 Received: from smtp.citrix.com (HELO SMTP.CITRIX.COM) (66.165.176.89) by server-6.tower-206.messagelabs.com with RC4-SHA encrypted SMTP; 18 May 2017 17:16:37 -0000 X-IronPort-AV: E=Sophos;i="5.38,359,1491264000"; d="scan'208";a="424430798" From: Wei Liu To: Xen-devel Date: Thu, 18 May 2017 18:10:02 +0100 Message-ID: <20170518171004.27204-21-wei.liu2@citrix.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170518171004.27204-1-wei.liu2@citrix.com> References: <20170518171004.27204-1-wei.liu2@citrix.com> MIME-Version: 1.0 Cc: Andrew Cooper , Wei Liu , Jan Beulich Subject: [Xen-devel] [PATCH for-next v3 20/22] x86: guest_has_trap_callback should return bool X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP No functional change. Signed-off-by: Wei Liu --- xen/arch/x86/pv/traps.c | 4 ++-- xen/include/asm-x86/traps.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/xen/arch/x86/pv/traps.c b/xen/arch/x86/pv/traps.c index ea5b543247..c36b650f5f 100644 --- a/xen/arch/x86/pv/traps.c +++ b/xen/arch/x86/pv/traps.c @@ -274,8 +274,8 @@ long unregister_guest_nmi_callback(void) return 0; } -int guest_has_trap_callback(struct domain *d, uint16_t vcpuid, - unsigned int trap_nr) +bool guest_has_trap_callback(struct domain *d, uint16_t vcpuid, + unsigned int trap_nr) { struct vcpu *v; struct trap_info *t; diff --git a/xen/include/asm-x86/traps.h b/xen/include/asm-x86/traps.h index 4e8760482f..7f36f6c1a7 100644 --- a/xen/include/asm-x86/traps.h +++ b/xen/include/asm-x86/traps.h @@ -33,10 +33,10 @@ void async_exception_cleanup(struct vcpu *); /** * guest_has_trap_callback * - * returns true (non-zero) if guest registered a trap handler + * returns true if guest registered a trap handler */ -extern int guest_has_trap_callback(struct domain *d, uint16_t vcpuid, - unsigned int trap_nr); +extern bool guest_has_trap_callback(struct domain *d, uint16_t vcpuid, + unsigned int trap_nr); /** * send_guest_trap