From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
To: "Zheng, Lv" <lv.zheng@intel.com>,
"Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: "Brown, Len" <len.brown@intel.com>, Lv Zheng <zetalog@gmail.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-acpi@vger.kernel.org" <linux-acpi@vger.kernel.org>
Subject: Re: [PATCH v2 5/5] ACPICA: Remove deprecated _LINUX definitions for ACPICA.
Date: Mon, 28 Apr 2014 22:26:46 +0200 [thread overview]
Message-ID: <535EB986.9060802@intel.com> (raw)
In-Reply-To: <1AE640813FDE7649BE1B193DEA596E88025586A7@SHSMSX101.ccr.corp.intel.com>
On 4/28/2014 6:10 AM, Zheng, Lv wrote:
> Hi, Rafael
>
>> From: Rafael J. Wysocki [mailto:rjw@rjwysocki.net]
>> Sent: Monday, April 28, 2014 5:39 AM
>>
>> On Wednesday, April 23, 2014 02:54:22 PM Lv Zheng wrote:
>>> There are _LINUX defined so that when Linux kernel is compiled using broken
>>> compilers that having not __linux__ defined can still include
>>> <acpi/platform/aclinux.h> from <acpi/platform/acenv.h>.
>>>
>>> This behavior is deprecated as all drivers/acpi/acpica files are compiled
>>> without including <linux/acpi.h>, thus without _LINUX defined. As there is
>>> no issues encountered when we compile ACPICA code without _LINUX defined,
>>> it is OK to remove _LINUX from <linux/acpi.h> now.
>>>
>>> Signed-off-by: Lv Zheng <lv.zheng@intel.com>
>>> ---
>>> include/linux/acpi.h | 4 ----
>>> 1 file changed, 4 deletions(-)
>>>
>>> diff --git a/include/linux/acpi.h b/include/linux/acpi.h
>>> index 7a8f2cd..9c559f7 100644
>>> --- a/include/linux/acpi.h
>>> +++ b/include/linux/acpi.h
>>> @@ -31,10 +31,6 @@
>>>
>>> #ifdef CONFIG_ACPI
>>>
>>> -#ifndef _LINUX
>>> -#define _LINUX
>>> -#endif
>>> -
>>> #include <linux/list.h>
>>> #include <linux/mod_devicetable.h>
>> What about <acpi/platform/acenv.h>? Should it still check if _LINUX is defined
>> after this change?
> If you mean these lines:
> #if defined(_LINUX) || defined(__linux__)
> #include <acpi/platform/aclinux.h>
> After deleting "_LINUX" from <linux/acpi.h>, acenv.h still can include aclinux.h because of "__linux__".
> Actually all drivers/acpi/acpica source files are compiled without including <linux/acpi.h>, so "_LINUX" defined in this file is useless to Linux.
> We needn't delete "_LINUX" from acenv.h.
>
> "_LINUX" is only used in ACPICA makefiles, Linux never uses it:
> https://github.com/acpica/acpica/blob/master/generate/unix/Makefile.config
> ACPICA can be compiled using the following make command:
> make HOST=_LINUX
> I think this is the only usage of "_LINUX" for now.
Well, my point was: If we delete the definition of _LINUX, why don't we
drop the symbol itself from everywhere along with it?
It definitely is not useful to refer to a symbol that's never defined,
is it?
Rafael
next prev parent reply other threads:[~2014-04-28 20:27 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <cover.1385110130.git.lv.zheng@intel.com>
2014-04-08 7:55 ` [PATCH 0/4] ACPICA: Fix some mis-ordered inclusions Lv Zheng
2014-04-08 7:56 ` [PATCH 1/4] ACPICA: Add <acpi/platform/aclinuxxf.h> to remove mis-ordered inclusion of <acpi/actypes.h> from <acpi/platform/aclinux.h> Lv Zheng
2014-04-21 20:58 ` Rafael J. Wysocki
2014-04-22 2:01 ` Zheng, Lv
2014-04-22 11:16 ` Rafael J. Wysocki
2014-04-23 1:06 ` Zheng, Lv
2014-04-08 7:56 ` [PATCH 2/4] ACPICA: Add <asm/acenv.h> to remove mis-ordered inclusion of <asm/acpi.h> " Lv Zheng
2014-04-08 7:57 ` [PATCH 3/4] ACPICA: Cleanup redudant definitions that already have defaults in <acpi/platform/acenv.h> Lv Zheng
2014-04-08 7:57 ` [PATCH 4/4] ACPICA: Remove deprecated _LINUX definitions for ACPICA Lv Zheng
2014-04-23 6:53 ` [PATCH v2 0/5] ACPICA: Fix some mis-ordered inclusions Lv Zheng
2014-04-23 6:53 ` [PATCH v2 1/5] ACPICA: OSL: Add direct inclusion of extra header Lv Zheng
2014-04-27 21:33 ` Rafael J. Wysocki
2014-04-28 4:12 ` Zheng, Lv
2014-04-23 6:53 ` [PATCH v2 2/5] ACPICA: Add <acpi/acpi_opt.h> to remove mis-ordered inclusion of <acpi/actypes.h> from <acpi/platform/aclinux.h> Lv Zheng
2014-04-23 6:54 ` [PATCH v2 3/5] ACPICA: Add <asm/acenv.h> to remove mis-ordered inclusion of <asm/acpi.h> " Lv Zheng
2014-04-27 21:36 ` Rafael J. Wysocki
2014-04-28 3:02 ` Zheng, Lv
2014-04-28 20:30 ` Rafael J. Wysocki
2014-04-29 7:49 ` Zheng, Lv
2014-04-23 6:54 ` [PATCH v2 4/5] ACPICA: Cleanup redudant definitions that already have defaults in <acpi/platform/acenv.h> Lv Zheng
2014-04-23 6:54 ` [PATCH v2 5/5] ACPICA: Remove deprecated _LINUX definitions for ACPICA Lv Zheng
2014-04-27 21:38 ` Rafael J. Wysocki
2014-04-28 4:10 ` Zheng, Lv
2014-04-28 20:26 ` Rafael J. Wysocki [this message]
2014-04-29 7:50 ` Zheng, Lv
2014-05-12 7:44 ` [PATCH v3 0/4] ACPICA: Cleanups for <acpi/platform/acenv.h> and <acpi/platform/aclinux.h> Lv Zheng
2014-05-12 7:45 ` [PATCH v3 1/4] ACPICA: Linux headers: Remove ACPI_PREEMPTION_POINT() due to no usages Lv Zheng
2014-05-12 7:46 ` [PATCH v3 2/4] ACPICA: Linux headers: Add <acpi/platform/aclinuxex.h> to remove mis-ordered inclusion of <acpi/actypes.h> from <acpi/platform/aclinux.h> Lv Zheng
2014-05-12 7:46 ` [PATCH v3 3/4] ACPICA: Linux headers: Add <asm/acenv.h> to remove mis-ordered inclusion of <asm/acpi.h> " Lv Zheng
2014-05-12 7:46 ` [PATCH v3 4/4] ACPICA: Cleanup redudant definitions that already have defaults in <acpi/platform/acenv.h> Lv Zheng
2014-05-16 12:06 ` [PATCH v3 0/4] ACPICA: Cleanups for <acpi/platform/acenv.h> and <acpi/platform/aclinux.h> Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=535EB986.9060802@intel.com \
--to=rafael.j.wysocki@intel.com \
--cc=len.brown@intel.com \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lv.zheng@intel.com \
--cc=rjw@rjwysocki.net \
--cc=zetalog@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).