From patchwork Tue Jul 5 03:12:33 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shannon Zhao X-Patchwork-Id: 71371 Delivered-To: patch@linaro.org Received: by 10.140.28.4 with SMTP id 4csp91290qgy; Mon, 4 Jul 2016 20:17:08 -0700 (PDT) X-Received: by 10.107.145.136 with SMTP id t130mr10294783iod.135.1467688628467; Mon, 04 Jul 2016 20:17:08 -0700 (PDT) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org. [192.237.175.120]) by mx.google.com with ESMTPS id o70si1501659ito.31.2016.07.04.20.17.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 04 Jul 2016 20:17:08 -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 1bKGoi-0008Mn-UO; Tue, 05 Jul 2016 03:14:32 +0000 Received: from mail6.bemta6.messagelabs.com ([85.158.143.247]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bKGoh-0008MZ-V0 for xen-devel@lists.xen.org; Tue, 05 Jul 2016 03:14:32 +0000 Received: from [85.158.143.35] by server-2.bemta-6.messagelabs.com id 8F/1A-11548-7162B775; Tue, 05 Jul 2016 03:14:31 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrGIsWRWlGSWpSXmKPExsVSPpHPSVdMrTr cYNtZfYslHxezODB6HN39mymAMYo1My8pvyKBNWPe7AOMBTN4K87sPMjSwPiAq4uRi0NI4Ayj xI4JF1kgnN2MEhcanjN3MXJysAnoSnzcOIUdxBYRkJVY3TUHzGYW+MAocWq2BIgtLBAoceTRb BYQm0VARWLr/tVsIDavgIfEqfNvwOISAhoSK3sngNmcAp4SX29C2EJANf0H1rNC1AtKnJz5hA VivoTEwRcvmCF6FSXa1p9kg7AlJQ6uuAF2qITAKUaJPW3LgBIcQI6pxMYLChMYBWchGTULyag FjEyrGNWLU4vKUot0jfWSijLTM0pyEzNzdA0NzPRyU4uLE9NTcxKTivWS83M3MQLDkwEIdjB2 /HM6xCjJwaQkyvvqX1W4EF9SfkplRmJxRnxRaU5q8SFGGQ4OJQleUdXqcCHBotT01Iq0zBxgp MCkJTh4lER4lUDSvMUFibnFmekQqVOMilLivIIgCQGQREZpHlwbLDovMcpKCfMyAh0ixFOQWp SbWYIq/4pRnINRSZhXE2QKT2ZeCdz0V0CLmYAWs8aWgywuSURISTUwToiYHaxYypT3Q+B9Tai 9WI/bj0m/jblzopKsoj/nv8osYEvM7J+cvyti7irl1Sld82dc/M9zrF/ynFPek3TtnhWcYo3d jX87a115+iLnMifN109QPdkiUb1gXs5KxSceTvpR25eIxC4s/FHoEWNiN4H5xtqcoI+Ff+7Pr pu207Z6xSnF4s9KLMUZiYZazEXFiQCkxl1HyQIAAA== X-Env-Sender: zhaoshenglong@huawei.com X-Msg-Ref: server-8.tower-21.messagelabs.com!1467688462!22231999!1 X-Originating-IP: [119.145.14.66] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogMTE5LjE0NS4xNC42NiA9PiA4NTI3\n X-StarScan-Received: X-StarScan-Version: 8.46; banners=-,-,- X-VirusChecked: Checked Received: (qmail 8121 invoked from network); 5 Jul 2016 03:14:30 -0000 Received: from szxga03-in.huawei.com (HELO szxga03-in.huawei.com) (119.145.14.66) by server-8.tower-21.messagelabs.com with RC4-SHA encrypted SMTP; 5 Jul 2016 03:14:30 -0000 Received: from 172.24.1.136 (EHLO SZXEML429-HUB.china.huawei.com) ([172.24.1.136]) by szxrg03-dlp.huawei.com (MOS 4.4.3-GA FastPath queued) with ESMTP id CEI04833; Tue, 05 Jul 2016 11:14:05 +0800 (CST) Received: from HGHY1Z002260041.china.huawei.com (10.177.16.142) by SZXEML429-HUB.china.huawei.com (10.82.67.184) with Microsoft SMTP Server id 14.3.235.1; Tue, 5 Jul 2016 11:13:55 +0800 From: Shannon Zhao To: Date: Tue, 5 Jul 2016 11:12:33 +0800 Message-ID: <1467688367-17320-4-git-send-email-zhaoshenglong@huawei.com> X-Mailer: git-send-email 1.9.0.msysgit.0 In-Reply-To: <1467688367-17320-1-git-send-email-zhaoshenglong@huawei.com> References: <1467688367-17320-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.0A090202.577B25FE.001A, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0, ip=0.0.0.0, so=2013-05-26 15:14:31, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: e7e355bb414642960acea9311263ddf2 Cc: hangaohuai@huawei.com, sstabellini@kernel.org, wei.liu2@citrix.com, ian.jackson@eu.citrix.com, peter.huangpeng@huawei.com, julien.grall@arm.com, shannon.zhao@linaro.org, boris.ostrovsky@oracle.com Subject: [Xen-devel] [PATCH v3 03/17] libxl/arm: Add a configuration option for ARM DomU ACPI 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 Add a configuration option for ARM DomU so that user can deicde to use ACPI or not. This option is defaultly false. Signed-off-by: Shannon Zhao --- tools/libxl/libxl.h | 5 +++++ tools/libxl/libxl_types.idl | 1 + tools/libxl/xl_cmdimpl.c | 4 ++++ 3 files changed, 10 insertions(+) diff --git a/tools/libxl/libxl.h b/tools/libxl/libxl.h index 2c0f868..ccaf87b 100644 --- a/tools/libxl/libxl.h +++ b/tools/libxl/libxl.h @@ -234,6 +234,11 @@ #define LIBXL_HAVE_BUILDINFO_ARM_GIC_VERSION 1 /* + * libxl_domain_build_info has the arm.acpi field. + */ +#define LIBXL_HAVE_BUILDINFO_ARM_ACPI 1 + +/* * LIBXL_HAVE_SOFT_RESET indicates that libxl supports performing * 'soft reset' for domains and there is 'soft_reset' shutdown reason * in enum libxl_shutdown_reason. diff --git a/tools/libxl/libxl_types.idl b/tools/libxl/libxl_types.idl index ef614be..426b868 100644 --- a/tools/libxl/libxl_types.idl +++ b/tools/libxl/libxl_types.idl @@ -560,6 +560,7 @@ libxl_domain_build_info = Struct("domain_build_info",[ ("arch_arm", Struct(None, [("gic_version", libxl_gic_version), + ("acpi", libxl_defbool), ])), ], dir=DIR_IN diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c index 6459eec..0634ffa 100644 --- a/tools/libxl/xl_cmdimpl.c +++ b/tools/libxl/xl_cmdimpl.c @@ -2506,6 +2506,10 @@ skip_usbdev: } } + if (xlu_cfg_get_defbool(config, "acpi", &b_info->arch_arm.acpi, 0)) { + libxl_defbool_set(&b_info->arch_arm.acpi, 0); + } + xlu_cfg_destroy(config); }