From patchwork Tue Nov 17 09:41:00 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shannon Zhao X-Patchwork-Id: 7635091 Return-Path: X-Original-To: patchwork-linux-arm@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 804D09F1D3 for ; Tue, 17 Nov 2015 10:13:47 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9C480204D6 for ; Tue, 17 Nov 2015 10:13:46 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D3A9420411 for ; Tue, 17 Nov 2015 10:13:45 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZydEc-00061Z-9X; Tue, 17 Nov 2015 10:11:34 +0000 Received: from mail-wm0-x233.google.com ([2a00:1450:400c:c09::233]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Zyctv-0004pG-8O for linux-arm-kernel@lists.infradead.org; Tue, 17 Nov 2015 09:50:14 +0000 Received: by wmec201 with SMTP id c201so17407169wme.1 for ; Tue, 17 Nov 2015 01:49:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=spSoj3wEOyxu30/rx1fDNp5dQKn+RufKY14Jn9nLlrU=; b=0DnFXf/xgFFLXapFwwCWVmy0xrhUKpeR3pBGECNFOYsEp6nuFE+ApJ8On7gU6Y48JA R7KxIcE+nV7T0H5+KbOkwOxkV8bxtKlykOuDPM9x/08XxJL2zuZa1zXb860090B6DybL ZB3b3iVJQh6mVVOHtcIMUZW4j9Ctz9a2COvBV81E6dKbXgL8IZctxgo3MolqSddaxQqR dwQ3XrnIyT4Yn3TvW02kz3DQLknh2SCSc0nH39ElQ+vWKImSBAysdV6FNuTHlGCDmKzz OjfImd+2c7nGh8GvrONBrMuf3v6J+STVRc8urtQyN/I+aJD4rC5D4B4hUxdI7owtoGH5 h9JQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=spSoj3wEOyxu30/rx1fDNp5dQKn+RufKY14Jn9nLlrU=; b=mxEKzVYudgr5+j5TH/TYQNdKk8qhK0LBCK5dUZbZbdHMD7Ie6A+xqOZVoW7iIJLpLV qtLWOjuqBHxWUDO+pcRE0pcQK3ntaBj8pT9GAXK2uitBGyXGCCCWN/r6WRyBOHreSYmh 9hX+XaYTne+ZnVD3chuZCTScxMhLUC/xO+mbv2ijsNn9oSRsvFml5gH0HN5xcQ7gwSdb V6jp/Ku1gH5EedD5syOmeO0dztx09FwQNsu3nL4qeJb1LbSv80k6qlOgLO0CH34g882y ZFVrbHQ/8iTZ2YgEaR06tXzRbhU3U8n7IAtSTq/v5Rw8l6JSU29Ncpi3pteqgHVnGm// 7ztg== X-Gm-Message-State: ALoCoQmyYqE2BldHno8h6t8VnJXVUSSiM+4ZE4NDwDEIioZ6EZjjp/i0N/PmvyY2Gs3yKnDjs+EC X-Received: by 10.28.61.213 with SMTP id k204mr1596722wma.5.1447753789603; Tue, 17 Nov 2015 01:49:49 -0800 (PST) Received: from localhost ([78.129.251.54]) by smtp.gmail.com with ESMTPSA id n127sm11771443wmf.12.2015.11.17.01.49.47 (version=TLS1 cipher=AES128-SHA bits=128/128); Tue, 17 Nov 2015 01:49:49 -0800 (PST) From: shannon.zhao@linaro.org To: ian.campbell@citrix.com, stefano.stabellini@citrix.com, keir@xen.org, jbeulich@suse.com, andrew.cooper3@citrix.com, julien.grall@citrix.com, xen-devel@lists.xen.org Subject: [PATCH v3 61/62] arm/acpi: Add acpi parameter to enable/disable acpi Date: Tue, 17 Nov 2015 17:41:00 +0800 Message-Id: <1447753261-7552-62-git-send-email-shannon.zhao@linaro.org> X-Mailer: git-send-email 1.9.5.msysgit.1 In-Reply-To: <1447753261-7552-1-git-send-email-shannon.zhao@linaro.org> References: <1447753261-7552-1-git-send-email-shannon.zhao@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20151117_015011_993565_6F250C05 X-CRM114-Status: GOOD ( 12.49 ) X-Spam-Score: -2.6 (--) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: mark.rutland@arm.com, hangaohuai@huawei.com, ard.biesheuvel@linaro.org, shannon.zhao@linaro.org, christoffer.dall@linaro.org, peter.huangpeng@huawei.com, david.vrabel@citrix.com, zhaoshenglong@huawei.com, linux-arm-kernel@lists.infradead.org, roger.pau@citrix.com MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham 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 From: Parth Dixit ACPI will be disabled by default. Define new command line parameter "acpi" for enabling it. Signed-off-by: Parth Dixit Signed-off-by: Shannon Zhao --- xen/arch/arm/setup.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/xen/arch/arm/setup.c b/xen/arch/arm/setup.c index 63feadf..1a40323 100644 --- a/xen/arch/arm/setup.c +++ b/xen/arch/arm/setup.c @@ -59,6 +59,10 @@ static unsigned long opt_xenheap_megabytes __initdata; integer_param("xenheap_megabytes", opt_xenheap_megabytes); #endif +/* "acpi=force" : Enables acpi */ +static void parse_acpi_param(char *s); +custom_param("acpi", parse_acpi_param); + static __used void init_done(void) { free_init_memory(); @@ -84,6 +88,23 @@ static const char * __initdata processor_implementers[] = { ['i'] = "Intel Corporation", }; +static char __initdata acpi_param[10] = ""; +static void __init parse_acpi_param(char *s) +{ + /* Save the parameter so it can be propagated to domain0. */ + safe_strcpy(acpi_param, s); + + /* Interpret the parameter for use within Xen. */ + if ( !parse_bool(s) ) + { + disable_acpi(); + } + else if ( !strcmp(s, "force") ) + { + acpi_disabled = 0; + } +} + static void __init processor_id(void) { const char *implementer = "Unknown"; @@ -729,6 +750,7 @@ void __init start_xen(unsigned long boot_phys_offset, + (fdt_paddr & ((1 << SECOND_SHIFT) - 1)); fdt_size = boot_fdt_info(device_tree_flattened, fdt_paddr); + disable_acpi(); cmdline = boot_fdt_cmdline(device_tree_flattened); printk("Command line: %s\n", cmdline); cmdline_parse(cmdline);