From patchwork Fri Apr 25 13:20:11 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hanjun Guo X-Patchwork-Id: 4062501 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.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 684E19F271 for ; Fri, 25 Apr 2014 13:25:13 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 96E402034F for ; Fri, 25 Apr 2014 13:25:12 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C60AB20397 for ; Fri, 25 Apr 2014 13:25:11 +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 1Wdg5x-0007ZA-Jh; Fri, 25 Apr 2014 13:23:13 +0000 Received: from mail-pb0-f53.google.com ([209.85.160.53]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Wdg5v-0007IA-EG for linux-arm-kernel@lists.infradead.org; Fri, 25 Apr 2014 13:23:12 +0000 Received: by mail-pb0-f53.google.com with SMTP id jt11so1455634pbb.26 for ; Fri, 25 Apr 2014 06:22:50 -0700 (PDT) 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=GXJgByyEffc8JJGf32bTQzUWO5OZ17Q7HUAH51+pQXQ=; b=QAKZfX6VH6qIMcVFUZCGEmGZmqfgIi3640o0vHG2Um8CskCmKUqk7oo5pqCPpfNJ3l 7EhMMzvQbN7pU81Jj4QQWGPX5wxnLP2ZoqGv8thYbZY0wHSjbqq3P1hI6QD0j+zcvg+e U4Ubg37h0Pq2hbcTt54Tlpawpi4pCdHGXg3D0ij5An3i6OZQFr75jdlt57hb1gxdJfUp wjGBOaReVawNUlx1h5Y7YqMAZKttpDWHJpwtkwO+YG4aDYTEFaWErexQZsyI3r0UTomw zCVe1/gJmWoI3Txgvizq9r/0SSwtr3umSSausmsWGnhNjAIH8SbvNlWvKQwNlQPOzfG5 m5mA== X-Gm-Message-State: ALoCoQnsaTrCkWVak5qpGKBliYUJxnBVSPQC9CccgXVuf/smbD+oIU/pNjRp3shGPV9jMU8aDOFC X-Received: by 10.68.163.197 with SMTP id yk5mr7736848pbb.57.1398432168243; Fri, 25 Apr 2014 06:22:48 -0700 (PDT) Received: from localhost ([218.17.215.175]) by mx.google.com with ESMTPSA id gj9sm16012481pbc.7.2014.04.25.06.22.36 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 25 Apr 2014 06:22:47 -0700 (PDT) From: Hanjun Guo To: linux-arm-kernel@lists.infradead.org, linux-acpi@vger.kernel.org Subject: [PATCH v3 part1 05/11] ARM64 / ACPI: Introduce early_param for "acpi" Date: Fri, 25 Apr 2014 21:20:11 +0800 Message-Id: <1398432017-8506-6-git-send-email-hanjun.guo@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1398432017-8506-1-git-send-email-hanjun.guo@linaro.org> References: <1398432017-8506-1-git-send-email-hanjun.guo@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140425_062311_503336_2173F41A X-CRM114-Status: GOOD ( 11.37 ) X-Spam-Score: -0.1 (/) Cc: Mark Rutland , Rob Herring , Al Stone , Arnd Bergmann , Mark Brown , Catalin Marinas , linaro-acpi@lists.linaro.org, "Rafael J. Wysocki" , Will Deacon , Olof Johansson , Hanjun Guo , Sudeep Holla , Grant Likely , Graeme Gregory , Charles.Garcia-Tobin@arm.com X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , 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=-1.8 required=5.0 tests=BAYES_00, RCVD_IN_SORBS_WEB, RP_MATCHES_RCVD, 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 Introduce two early parameters for "acpi", one is the parameter to disable ACPI on ARM64 and another one is acpi=strict to disable out-of-spec workarounds. Signed-off-by: Al Stone Signed-off-by: Graeme Gregory Signed-off-by: Hanjun Guo Reviewed-by: Grant Likely --- drivers/acpi/plat/arm-core.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/drivers/acpi/plat/arm-core.c b/drivers/acpi/plat/arm-core.c index 47b5d9b..e4846fd 100644 --- a/drivers/acpi/plat/arm-core.c +++ b/drivers/acpi/plat/arm-core.c @@ -111,3 +111,21 @@ void __init acpi_boot_table_init(void) return; } } + +static int __init parse_acpi(char *arg) +{ + if (!arg) + return -EINVAL; + + /* "acpi=off" disables both ACPI table parsing and interpreter */ + if (strcmp(arg, "off") == 0) { + disable_acpi(); + } + /* acpi=strict disables out-of-spec workarounds */ + else if (strcmp(arg, "strict") == 0) { + acpi_strict = 1; + } + + return 0; +} +early_param("acpi", parse_acpi);