From patchwork Fri Jan 17 18:51:30 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Al Stone X-Patchwork-Id: 23354 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vb0-f72.google.com (mail-vb0-f72.google.com [209.85.212.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C91B2203C6 for ; Fri, 17 Jan 2014 18:51:43 +0000 (UTC) Received: by mail-vb0-f72.google.com with SMTP id w20sf2620986vbb.11 for ; Fri, 17 Jan 2014 10:51:43 -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:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=NUTNGWP5HL5D0wGAYgSBrqEey+H+dA2zZs9KWCUWCRQ=; b=JwSS0ngB0R3KYPLyCuQCcXbwPMtb/qIcqw0nsq/01euTu1iR6Zrsx+RHpkOa2bEAcT kMc9FJ7oRGM5p7E4eHV4Kf93rL3frMQRRZPJIFAdAXxbDa906s410PYsYzSAQ/Oy2/id R1VKToKYHOe6gt24td8Z8O94H0byNNqaAu7BS9Py6BcWfpriOkENlMSXzfwgD1jaD9AP RHomHsey1C0FRSWIdexF57BnL8v6jUmoRop0q+L2TjeO+a9avs7uaRslMya1Vt9BlUtm U090d+2vAPYPrFQkacTRL4r0YgSXhrcCkOEVvsixGDg8+6zNOR1v1MbKeBRBKLpmcIyL lPxg== X-Gm-Message-State: ALoCoQlESGGEZupI/Cqp2nFYciwT68JcwZOFStzTvWnSU1Xi7zFtdrMqmoExnoChdDbY4U+WJuB2 X-Received: by 10.236.17.161 with SMTP id j21mr1066971yhj.55.1389984703016; Fri, 17 Jan 2014 10:51:43 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.48.130 with SMTP id l2ls1341401qen.66.gmail; Fri, 17 Jan 2014 10:51:42 -0800 (PST) X-Received: by 10.58.37.232 with SMTP id b8mr1636685vek.27.1389984702844; Fri, 17 Jan 2014 10:51:42 -0800 (PST) Received: from mail-vb0-f53.google.com (mail-vb0-f53.google.com [209.85.212.53]) by mx.google.com with ESMTPS id u8si5260664vcz.76.2014.01.17.10.51.42 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 17 Jan 2014 10:51:42 -0800 (PST) Received-SPF: neutral (google.com: 209.85.212.53 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.212.53; Received: by mail-vb0-f53.google.com with SMTP id p17so1698095vbe.40 for ; Fri, 17 Jan 2014 10:51:42 -0800 (PST) X-Received: by 10.52.23.13 with SMTP id i13mr1401269vdf.0.1389984702751; Fri, 17 Jan 2014 10:51:42 -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.59.13.131 with SMTP id ey3csp40773ved; Fri, 17 Jan 2014 10:51:42 -0800 (PST) X-Received: by 10.66.122.201 with SMTP id lu9mr3877776pab.40.1389984701721; Fri, 17 Jan 2014 10:51:41 -0800 (PST) Received: from mail-pb0-f48.google.com (mail-pb0-f48.google.com [209.85.160.48]) by mx.google.com with ESMTPS id s4si10896077pbg.273.2014.01.17.10.51.41 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 17 Jan 2014 10:51:41 -0800 (PST) Received-SPF: neutral (google.com: 209.85.160.48 is neither permitted nor denied by best guess record for domain of al.stone@linaro.org) client-ip=209.85.160.48; Received: by mail-pb0-f48.google.com with SMTP id rr13so4432960pbb.7 for ; Fri, 17 Jan 2014 10:51:41 -0800 (PST) X-Received: by 10.68.192.131 with SMTP id hg3mr3849025pbc.136.1389984701236; Fri, 17 Jan 2014 10:51:41 -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 xn12sm33291896pac.12.2014.01.17.10.51.39 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 17 Jan 2014 10:51:40 -0800 (PST) From: al.stone@linaro.org To: linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: linaro-acpi@lists.linaro.org, patches@linaro.org, linaro-kernel@lists.linaro.org, Al Stone , Hanjun Guo Subject: [PATCH v3] ACPI: introduce CONFIG_ACPI_REDUCED_HARDWARE_ONLY to enable this ACPI mode Date: Fri, 17 Jan 2014 11:51:30 -0700 Message-Id: <1389984690-24251-1-git-send-email-al.stone@linaro.org> X-Mailer: git-send-email 1.8.4.2 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.212.53 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 ACPI hardware reduced mode exists to allow newer platforms to use a simpler form of ACPI that does not require supporting legacy versions of the specification and their associated hardware. This mode was introduced in the ACPI 5.0 specification. To enable the hardware reduced mode of ACPI, we need to set the flag ACPI_REDUCED_HARDWARE to TRUE in the ACPICA source. In order to do that, we introduce a kernel configuration item to enable or disable ACPI_REDUCED_HARDWARE. We can then change the kernel configuration instead of having to modify the kernel source. Introducing this configuration item is based on suggestions from Lv Zheng saying that this does not belong in ACPICA, but rather to the Linux kernel itself. Hence, we introduce this configuration item 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 Changes for v3: -- Minimize the changelog. Changes for v2: -- Changed test for EXPERT to avoid reported Kconfig warning Signed-off-by: Hanjun Guo Signed-off-by: Al Stone --- drivers/acpi/Kconfig | 13 +++++++++++++ include/acpi/platform/aclinux.h | 6 ++++++ 2 files changed, 19 insertions(+) diff --git a/drivers/acpi/Kconfig b/drivers/acpi/Kconfig index 4770de5..9fd6a7a 100644 --- a/drivers/acpi/Kconfig +++ b/drivers/acpi/Kconfig @@ -343,6 +343,19 @@ config ACPI_BGRT data from the firmware boot splash. It will appear under /sys/firmware/acpi/bgrt/ . +config ACPI_REDUCED_HARDWARE_ONLY + bool "Hardware-reduced ACPI support only" if EXPERT + def_bool n + depends on ACPI + help + This config item changes the way the ACPI code is built. When this + option is selected, the kernel will use a specialized version of + ACPICA that ONLY supports the ACPI "reduced hardware" mode. The + resulting kernel will be smaller but it will also be restricted to + running in ACPI reduced hardware mode ONLY. + + If you are unsure what to do, do not enable this option. + source "drivers/acpi/apei/Kconfig" config ACPI_EXTLOG diff --git a/include/acpi/platform/aclinux.h b/include/acpi/platform/aclinux.h index 28f4f4d..7d71f08 100644 --- a/include/acpi/platform/aclinux.h +++ b/include/acpi/platform/aclinux.h @@ -52,6 +52,12 @@ #ifdef __KERNEL__ +/* Compile for reduced hardware mode only with this kernel config */ + +#ifdef CONFIG_ACPI_REDUCED_HARDWARE_ONLY +#define ACPI_REDUCED_HARDWARE 1 +#endif + #include #include #include