From patchwork Fri Nov 22 09:56:31 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hanjun Guo X-Patchwork-Id: 3221911 Return-Path: X-Original-To: patchwork-linux-acpi@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 3D3F39F461 for ; Fri, 22 Nov 2013 09:56:32 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2C8E320798 for ; Fri, 22 Nov 2013 09:56:31 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 10A9420793 for ; Fri, 22 Nov 2013 09:56:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753901Ab3KVJ43 (ORCPT ); Fri, 22 Nov 2013 04:56:29 -0500 Received: from mail-pa0-f53.google.com ([209.85.220.53]:40123 "EHLO mail-pa0-f53.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753377Ab3KVJ42 (ORCPT ); Fri, 22 Nov 2013 04:56:28 -0500 Received: by mail-pa0-f53.google.com with SMTP id hz1so1098708pad.12 for ; Fri, 22 Nov 2013 01:56:27 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=mNWjQrgtGFtj1y5Uqr97L2zBA5fw+IwzAAi08lRNAvU=; b=a/fMRPP13ET+aWzL0VojQyTPm5A+mDrDiK81Y+ENy7x4r+ujzarbCHixShfIA89VVM SV7/lHcgsuLtuyGgvYklsnI7jD73JqofLPp2qhFmC1sWXUO/DDyYZjAvR/uJAlT6OIZm zQ8aoNEhzpxNoyiUgEQtb4MCyjnyXk6pYmH05pV8boXEJQHba8jQs/kpSoPmnLbMYA7b p45+BJ6qdhYl0vVoRv0YzsNZR5pthjLoVmt2uG+Oh9hWSJ/KYHtMXcxXzFK5Ar1KSwXc vE9RWr1Ma0GutG/P46rz37zFP1CZ9jxau8eRfbeIX1qChwqPUB9SeXaNny6sZm9j3oE9 rmyg== X-Gm-Message-State: ALoCoQlURpyL2Vkwasc5qzopeLeC8GHL5Lg1V73Pt4wHTqT7EnSQKtXxor9+jXaft3esM2D+xNe0 X-Received: by 10.68.198.97 with SMTP id jb1mr1909987pbc.104.1385114187431; Fri, 22 Nov 2013 01:56:27 -0800 (PST) Received: from [192.168.204.184] ([218.17.215.175]) by mx.google.com with ESMTPSA id xs1sm58800039pac.7.2013.11.22.01.56.21 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 22 Nov 2013 01:56:26 -0800 (PST) Message-ID: <528F2A4F.90908@linaro.org> Date: Fri, 22 Nov 2013 17:56:31 +0800 From: Hanjun Guo User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:24.0) Gecko/20100101 Thunderbird/24.1.1 MIME-Version: 1.0 To: "Zheng, Lv" , "al.stone@linaro.org" , "linux-acpi@vger.kernel.org" CC: "linaro-acpi@lists.linaro.org" , Al Stone Subject: Re: [PATCH 01/12] ACPI: introduce CONFIG_ACPI_REDUCED_HARDWARE to enable this ACPI mode References: <1384047382-20623-1-git-send-email-al.stone@linaro.org> <1384047382-20623-2-git-send-email-al.stone@linaro.org> <1AE640813FDE7649BE1B193DEA596E880248C95D@SHSMSX101.ccr.corp.intel.com> In-Reply-To: <1AE640813FDE7649BE1B193DEA596E880248C95D@SHSMSX101.ccr.corp.intel.com> Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_WEB, RP_MATCHES_RCVD, 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 On 2013-11-22 14:14, Zheng, Lv wrote: [...] >> endif # ACPI >> 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 >> + > > Maybe you put this here because of my previous wrong comment. > > For ACPICA environments that work like Kconfigs for Linux, it is good to define them before including any ACPICA files. > While putting things here cannot cover . Good catch! thanks for the reminding. > > Normally, I will do: > > ... > > #ifdef __KERNEL__ > > /* some comment */ > (one empty line as ACPICA enforces 1 empty line after 1 line comment and no empty lines after a block of comments) > #ifdef CONFIG_ACPI_REDUCED_HARDWARE > #define ACPI_REDUCED_HARDWARE(spaces not tabs here according to ACPICA's coding style)TRUE > #endif > > #include There is a problem when I try yours suggestion, it is a compiling warning: warning: "TRUE" is not defined And I find that "TRUE" is defined in include/acpi/actypes. So, is this ok to you? > The coding style can help ACPICA release process to generate correct Linuxized patches. > It would be good to Linux developers to follow this currently for ACPICA internal code or we may see a small useless divergences commit generated from a back ported Linux commit :-( . > I'm sorry for the inconvenience. ok, will update in next version. > > Thanks > -Lv --- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/include/acpi/platform/aclinux.h +++ b/include/acpi/platform/aclinux.h @@ -63,6 +63,13 @@ #ifdef EXPORT_ACPI_INTERFACES #include #endif + +#define TRUE (1 == 1) + +#ifdef CONFIG_ACPI_REDUCED_HARDWARE +#define ACPI_REDUCED_HARDWARE TRUE +#endif + #include >