From patchwork Thu Mar 31 11:23:36 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shannon Zhao X-Patchwork-Id: 64766 Delivered-To: patch@linaro.org Received: by 10.112.199.169 with SMTP id jl9csp96033lbc; Thu, 31 Mar 2016 04:26:30 -0700 (PDT) X-Received: by 10.140.143.134 with SMTP id 128mr16642377qhp.25.1459423582190; Thu, 31 Mar 2016 04:26:22 -0700 (PDT) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org. [192.237.175.120]) by mx.google.com with ESMTPS id 71si7337679qhb.91.2016.03.31.04.26.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 31 Mar 2016 04:26:22 -0700 (PDT) Received-SPF: neutral (google.com: 192.237.175.120 is neither permitted nor denied by best guess record for domain of xen-devel-bounces@lists.xen.org) client-ip=192.237.175.120; Authentication-Results: mx.google.com; spf=neutral (google.com: 192.237.175.120 is neither permitted nor denied by best guess record for domain of xen-devel-bounces@lists.xen.org) smtp.mailfrom=xen-devel-bounces@lists.xen.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1alaj2-0006us-0U; Thu, 31 Mar 2016 11:25:20 +0000 Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1alaj1-0006sp-GF for xen-devel@lists.xen.org; Thu, 31 Mar 2016 11:25:19 +0000 Received: from [193.109.254.147] by server-4.bemta-14.messagelabs.com id E6/2B-03301-E190DF65; Thu, 31 Mar 2016 11:25:18 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrBIsWRWlGSWpSXmKPExsVSPpHPUVeO82+ YwZxpghZLPi5mcWD0OLr7N1MAYxRrZl5SfkUCa8apUxvYC77yVXy79JWxgXEVTxcjF4eQwClG iZuf1rJCOHsYJWa+Ws/UxcjJwSagK/Fx4xR2EFtEIE/ie+MsNpAiZoGtTBLv+yeAJYQF4iQWT PrKAmKzCKhKPN68kBXE5hVwlzj0ZQ+YLSGgIbGydwJYDaeAh8SexhVgcSGgmuerXzND1AtKnJ z5BKyGWUBC4uCLF8wQvYoSbetPskHYkhIHV9xgATlCAuTstjcQQyUETCWmHtvLPoFRcBaSWbO QzFrAyLSKUb04tagstUjXXC+pKDM9oyQ3MTNH19DQRC83tbg4MT01JzGpWC85P3cTIzBEGYBg B+OXJc6HGCU5mJREee+9/hMmxJeUn1KZkVicEV9UmpNafIhRhoNDSYJXnuNvmJBgUWp6akVaZ g4wWmDSEhw8SiK8jCBp3uKCxNzizHSI1ClGRSlxXhmQhABIIqM0D64NFqGXGGWlhHkZgQ4R4i lILcrNLEGVf8UozsGoJMx7mx1oCk9mXgnc9FdAi5mAFm/V+AWyuCQRISXVwBj8Y2vU692+Gfs e8tnZTfxa5Dg7i6/yJOO8V29n8N5Z+OzuqYKkn+UB04LX/eSaGlkkdfB6Yf6e34c3S0+4mmjx nuO5U+SJMzm9VZ03+T5r7X63sf5xg+gkkf23/7fIX1MT27TEUEGIh795+SIPXh9Gk2uySutaF rGuE1jy5MSeXt21/SWJi2OVWIozEg21mIuKEwHUAksQywIAAA== X-Env-Sender: zhaoshenglong@huawei.com X-Msg-Ref: server-8.tower-27.messagelabs.com!1459423514!31022324!1 X-Originating-IP: [119.145.14.65] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogMTE5LjE0NS4xNC42NSA9PiA3NzQ2Mw==\n X-StarScan-Received: X-StarScan-Version: 8.28; banners=-,-,- X-VirusChecked: Checked Received: (qmail 35674 invoked from network); 31 Mar 2016 11:25:17 -0000 Received: from szxga02-in.huawei.com (HELO szxga02-in.huawei.com) (119.145.14.65) by server-8.tower-27.messagelabs.com with RC4-SHA encrypted SMTP; 31 Mar 2016 11:25:17 -0000 Received: from 172.24.1.60 (EHLO szxeml428-hub.china.huawei.com) ([172.24.1.60]) by szxrg02-dlp.huawei.com (MOS 4.3.7-GA FastPath queued) with ESMTP id DEL54445; Thu, 31 Mar 2016 19:25:07 +0800 (CST) Received: from HGHY1Z002260041.china.huawei.com (10.177.16.142) by szxeml428-hub.china.huawei.com (10.82.67.183) with Microsoft SMTP Server id 14.3.235.1; Thu, 31 Mar 2016 19:24:55 +0800 From: Shannon Zhao To: , , Date: Thu, 31 Mar 2016 19:23:36 +0800 Message-ID: <1459423425-1220-9-git-send-email-zhaoshenglong@huawei.com> X-Mailer: git-send-email 1.9.0.msysgit.0 In-Reply-To: <1459423425-1220-1-git-send-email-zhaoshenglong@huawei.com> References: <1459423425-1220-1-git-send-email-zhaoshenglong@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.177.16.142] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A0B0206.56FD0913.0208, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0, ip=0.0.0.0, so=2013-06-18 04:22:30, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: 762a0d9a9cd5a27c790a1744a773527d Cc: devicetree@vger.kernel.org, sstabellini@kernel.org, catalin.marinas@arm.com, will.deacon@arm.com, linux-kernel@vger.kernel.org, xen-devel@lists.xen.org, julien.grall@arm.com, linux-efi@vger.kernel.org, shannon.zhao@linaro.org, peter.huangpeng@huawei.com Subject: [Xen-devel] [PATCH v9 08/17] Xen: public/hvm: sync changes of HVM_PARAM_CALLBACK_VIA ABI from Xen 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" From: Shannon Zhao Sync the changes of HVM_PARAM_CALLBACK_VIA ABI introduced by Xen commit (public/hvm: export the HVM_PARAM_CALLBACK_VIA ABI in the API). Signed-off-by: Shannon Zhao Acked-by: Stefano Stabellini --- include/xen/interface/hvm/params.h | 27 +++++++++++++++++++++------ 1 file changed, 21 insertions(+), 6 deletions(-) diff --git a/include/xen/interface/hvm/params.h b/include/xen/interface/hvm/params.h index a6c7991..70ad208 100644 --- a/include/xen/interface/hvm/params.h +++ b/include/xen/interface/hvm/params.h @@ -27,16 +27,31 @@ * Parameter space for HVMOP_{set,get}_param. */ +#define HVM_PARAM_CALLBACK_IRQ 0 /* * How should CPU0 event-channel notifications be delivered? - * val[63:56] == 0: val[55:0] is a delivery GSI (Global System Interrupt). - * val[63:56] == 1: val[55:0] is a delivery PCI INTx line, as follows: - * Domain = val[47:32], Bus = val[31:16], - * DevFn = val[15: 8], IntX = val[ 1: 0] - * val[63:56] == 2: val[7:0] is a vector number. + * * If val == 0 then CPU0 event-channel notifications are not delivered. + * If val != 0, val[63:56] encodes the type, as follows: + */ + +#define HVM_PARAM_CALLBACK_TYPE_GSI 0 +/* + * val[55:0] is a delivery GSI. GSI 0 cannot be used, as it aliases val == 0, + * and disables all notifications. + */ + +#define HVM_PARAM_CALLBACK_TYPE_PCI_INTX 1 +/* + * val[55:0] is a delivery PCI INTx line: + * Domain = val[47:32], Bus = val[31:16] DevFn = val[15:8], IntX = val[1:0] + */ + +#define HVM_PARAM_CALLBACK_TYPE_VECTOR 2 +/* + * val[7:0] is a vector number. Check for XENFEAT_hvm_callback_vector to know + * if this delivery method is available. */ -#define HVM_PARAM_CALLBACK_IRQ 0 #define HVM_PARAM_STORE_PFN 1 #define HVM_PARAM_STORE_EVTCHN 2