From patchwork Fri Nov 22 00:41:50 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Al Stone X-Patchwork-Id: 21669 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qa0-f69.google.com (mail-qa0-f69.google.com [209.85.216.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 8F6D123FDF for ; Fri, 22 Nov 2013 00:42:12 +0000 (UTC) Received: by mail-qa0-f69.google.com with SMTP id ii20sf8528448qab.8 for ; Thu, 21 Nov 2013 16:42:12 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=o2FuxXZrkMVWSYva2JlG0X9TTOuJci+jIvj5eER00ls=; b=DU8WDJOioulf/+RomcgS/Iz4jZDuS+241WHfzd9CIPu0/KIGx38/lo/W0SgrHjrJ4r YDMC50hbPKytEJm/V5RGjBhZuANehfsgdMO2fOl/gTxgUknhlMPNyQ7DhzsjT8NGc9hb e9nYQka3ZACEs/TM13pK5N4tOtAAx5VGrbkG/eD9UIBHaQP7gYcVnf8l8VzLwunefdL6 GnGdAmkpIloOAnQCmKVDCLb5zMHUa4Cv5oIDxucqF1RBPbJBBDzaA7KEMtESIY48KrP0 FkeHJKu8DmG0g3dDgTeRLJHFDCAwwWMuGMCIJrZ+Iq9Edwkg50XxJCnIeCD2hLLNsXwG vO1Q== X-Gm-Message-State: ALoCoQncsBlCEi7b1UvbcSNaLLCn+zWzsoz3IYmHUA0nWWuSOc4PkcoHwR4ShkEiJSM1dCmDErzr X-Received: by 10.236.115.198 with SMTP id e46mr4611829yhh.33.1385080932316; Thu, 21 Nov 2013 16:42:12 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.83.198 with SMTP id s6ls736802qey.46.gmail; Thu, 21 Nov 2013 16:42:12 -0800 (PST) X-Received: by 10.58.136.231 with SMTP id qd7mr8403022veb.1.1385080932208; Thu, 21 Nov 2013 16:42:12 -0800 (PST) Received: from mail-vc0-f180.google.com (mail-vc0-f180.google.com [209.85.220.180]) by mx.google.com with ESMTPS id dh7si11643626vcb.38.2013.11.21.16.42.11 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 21 Nov 2013 16:42:11 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.180 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.180; Received: by mail-vc0-f180.google.com with SMTP id if17so369725vcb.25 for ; Thu, 21 Nov 2013 16:42:11 -0800 (PST) X-Received: by 10.58.133.77 with SMTP id pa13mr8487864veb.21.1385080931785; Thu, 21 Nov 2013 16:42:11 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp2864vcz; Thu, 21 Nov 2013 16:42:11 -0800 (PST) X-Received: by 10.67.4.197 with SMTP id cg5mr9370492pad.10.1385080930781; Thu, 21 Nov 2013 16:42:10 -0800 (PST) Received: from mail-pd0-f173.google.com (mail-pd0-f173.google.com [209.85.192.173]) by mx.google.com with ESMTPS id il5si2988285pbb.294.2013.11.21.16.42.10 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 21 Nov 2013 16:42:10 -0800 (PST) Received-SPF: neutral (google.com: 209.85.192.173 is neither permitted nor denied by best guess record for domain of al.stone@linaro.org) client-ip=209.85.192.173; Received: by mail-pd0-f173.google.com with SMTP id p10so509850pdj.4 for ; Thu, 21 Nov 2013 16:42:10 -0800 (PST) X-Received: by 10.66.148.97 with SMTP id tr1mr9255122pab.163.1385080930370; Thu, 21 Nov 2013 16:42:10 -0800 (PST) Received: from fidelio.ahs3.com (74-93-232-46-Colorado.hfc.comcastbusiness.net. [74.93.232.46]) by mx.google.com with ESMTPSA id pl1sm48881461pbb.20.2013.11.21.16.42.09 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 21 Nov 2013 16:42:10 -0800 (PST) From: al.stone@linaro.org To: linux-acpi@vger.kernel.org Cc: linaro-acpi@lists.linaro.org, patches@linaro.org, linaro-kernel@lists.linaro.org, Al Stone , Hanjun Guo Subject: [PATCH v2 1/6] ACPI: introduce CONFIG_ACPI_REDUCED_HARDWARE to enable this ACPI mode Date: Thu, 21 Nov 2013 17:41:50 -0700 Message-Id: <1385080915-23430-2-git-send-email-al.stone@linaro.org> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1385080915-23430-1-git-send-email-al.stone@linaro.org> References: <1385080915-23430-1-git-send-email-al.stone@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: al.stone@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.180 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Al Stone To enable the hardware reduced mode of ACPI on some platforms (such as ARM), we need to modify the kernel code and set ACPI_REDUCED_HARDWARE to TRUE in the ACPICA source. This can be done more resonably by introducing a kernel config item to enable/disable ACPI_REDUCED_HARDWARE. We can then change the kernel config instead of having to modify the kernel source directly to enable the reduced hardware mode of ACPI. Lv Zheng suggested that this configuration item does not belong in ACPICA, the upstream source for much of the ACPI internals, but rather to the Linux kernel itself. Hence, we introduce this flag so that we can make ACPI_REDUCED_HARDWARE configurable. For the details of the discussion, please refer to: http://www.spinics.net/lists/linux-acpi/msg46369.html Signed-off-by: Hanjun Guo Signed-off-by: Al Stone --- drivers/acpi/Kconfig | 8 ++++++++ include/acpi/platform/aclinux.h | 4 ++++ 2 files changed, 12 insertions(+) diff --git a/drivers/acpi/Kconfig b/drivers/acpi/Kconfig index 5d92485..53f0f16 100644 --- a/drivers/acpi/Kconfig +++ b/drivers/acpi/Kconfig @@ -343,6 +343,14 @@ config ACPI_BGRT data from the firmware boot splash. It will appear under /sys/firmware/acpi/bgrt/ . +config ACPI_REDUCED_HARDWARE + bool "Hardware-reduced ACPI support" + depends on ARM || ARM64 + help + This config adds support for Hardware-reduced ACPI. When this option + is selected, will generate a specialized version of ACPICA that ONLY + supports the ACPI "reduced hardware". + source "drivers/acpi/apei/Kconfig" config ACPI_EXTLOG diff --git a/include/acpi/platform/aclinux.h b/include/acpi/platform/aclinux.h index 28f4f4d..ae93a91 100644 --- a/include/acpi/platform/aclinux.h +++ b/include/acpi/platform/aclinux.h @@ -67,6 +67,10 @@ /* Host-dependent types and defines for in-kernel ACPICA */ +#ifdef CONFIG_ACPI_REDUCED_HARDWARE +#define ACPI_REDUCED_HARDWARE TRUE +#endif + #define ACPI_MACHINE_WIDTH BITS_PER_LONG #define ACPI_EXPORT_SYMBOL(symbol) EXPORT_SYMBOL(symbol); #define strtoul simple_strtoul