All of lore.kernel.org
 help / color / mirror / Atom feed
* [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
@ 2020-01-22 17:07 Moore, Robert
  0 siblings, 0 replies; 5+ messages in thread
From: Moore, Robert @ 2020-01-22 17:07 UTC (permalink / raw)
  To: devel

[-- Attachment #1: Type: text/plain, Size: 4078 bytes --]



-----Original Message-----
From: Kaneda, Erik <erik.kaneda(a)intel.com> 
Sent: Tuesday, January 21, 2020 1:46 PM
To: Moore, Robert <robert.moore(a)intel.com>
Subject: FW: [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian



> -----Original Message-----
> From: Moore, Robert <robert.moore(a)intel.com>
> Sent: Wednesday, December 18, 2019 10:10 AM
> To: Jung-uk Kim <jkim(a)FreeBSD.org>; Rafael J. Wysocki 
> <rjw(a)rjwysocki.net>; Kaneda, Erik <erik.kaneda(a)intel.com>
> Cc: Laster K. <officiallazerl0rd(a)gmail.com>; Wysocki, Rafael J 
> <rafael.j.wysocki(a)intel.com>; linux-acpi(a)vger.kernel.org; 
> devel(a)acpica.org
> Subject: RE: [Devel] Re: [PATCH] ACPICA: Fix compilation with 
> bare-metal toolchian
> 
> 
> 
> -----Original Message-----
> From: Jung-uk Kim <jkim(a)FreeBSD.org>
> Sent: Friday, December 13, 2019 7:05 AM
> To: Moore, Robert <robert.moore(a)intel.com>; Rafael J. Wysocki 
> <rjw(a)rjwysocki.net>; Kaneda, Erik <erik.kaneda(a)intel.com>
> Cc: Laster K. <officiallazerl0rd(a)gmail.com>; Wysocki, Rafael J 
> <rafael.j.wysocki(a)intel.com>; linux-acpi(a)vger.kernel.org; 
> devel(a)acpica.org
> Subject: Re: [Devel] Re: [PATCH] ACPICA: Fix compilation with 
> bare-metal toolchian
> 
> On 19. 12. 12., Moore, Robert wrote:
> >> -----Original Message-----
> >> From: Rafael J. Wysocki [mailto:rjw(a)rjwysocki.net]
> >> Sent: Friday, July 5, 2019 2:44 AM
> >> To: Moore, Robert <robert.moore(a)intel.com>; Schmauss, Erik 
> >> <erik.schmauss(a)intel.com>
> >> Cc: Laster K. <officiallazerl0rd(a)gmail.com>; Wysocki, Rafael J 
> >> <rafael.j.wysocki(a)intel.com>; lenb(a)kernel.org; linux- 
> >> acpi(a)vger.kernel.org; devel(a)acpica.org
> >> Subject: Re: [PATCH] ACPICA: Fix compilation with bare-metal 
> >> toolchian
> >>
> >> On Saturday, June 22, 2019 11:03:54 PM CEST Laster K. wrote:
> >>> An ifdef expects to be compiled with full-fledged Linux toolchain, 
> >>> but it's common to compile kernel with just bare-metal toolchain 
> >>> which doesn't define __linux__. So, also add __KERNEL__ check.
> >>>
> > [Moore, Robert]
> > This sounds OK, as long as no other supported hosts define __KERNEL__.
> 
> FreeBSD defines _KERNEL for kernel source.
> 
> I'd have to say that this sounds a bit dangerous. Is there another 
> symbol that we can AND into an expression?
> 
> JK
> 
I agree, this sounds dangerous due to other hosts possibly using __KERNEL__. If __KERNEL__ is defined as well as _LINUX or __linux__, this would eliminate the danger.

Bob


> >>> Signed-off-by: Laster K. (lazerl0rd) <officiallazerl0rd(a)gmail.com>
> >>> ---
> >>> Apologies for the multiple/spammed e-mails, I was having mail 
> >>> client
> >> issues.
> >>>
> >>>  include/acpi/platform/acenv.h   | 2 +-
> >>>  include/acpi/platform/acenvex.h | 2 +-
> >>>  2 files changed, 2 insertions(+), 2 deletions(-)
> >>>
> >>> diff --git a/include/acpi/platform/acenv.h 
> >>> b/include/acpi/platform/acenv.h index 35ab3f87cc29..b69319198cb8
> >>> 100644
> >>> --- a/include/acpi/platform/acenv.h
> >>> +++ b/include/acpi/platform/acenv.h
> >>> @@ -148,7 +148,7 @@
> >>>
> >>>  #endif
> >>>
> >>> -#if defined(_LINUX) || defined(__linux__)
> >>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
> >>>  #include <acpi/platform/aclinux.h>
> >>>
> >>>  #elif defined(_APPLE) || defined(__APPLE__) diff --git 
> >>> a/include/acpi/platform/acenvex.h 
> >>> b/include/acpi/platform/acenvex.h index 2e36c8344897..c7697a47e33f 
> >>> 100644
> >>> --- a/include/acpi/platform/acenvex.h
> >>> +++ b/include/acpi/platform/acenvex.h
> >>> @@ -19,7 +19,7 @@
> >>>   *
> >>>
> >>>
> **********************************************************
> **********
> >>> **
> >>> *******/
> >>>
> >>> -#if defined(_LINUX) || defined(__linux__)
> >>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
> >>>  #include <acpi/platform/aclinuxex.h>
> >>>
> >>>  #elif defined(__DragonFly__)
> >>>
> >>
> >> Erik, Bob, any input here?



^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
@ 2019-12-18 18:09 Moore, Robert
  0 siblings, 0 replies; 5+ messages in thread
From: Moore, Robert @ 2019-12-18 18:09 UTC (permalink / raw)
  To: devel

[-- Attachment #1: Type: text/plain, Size: 2940 bytes --]



-----Original Message-----
From: Jung-uk Kim <jkim(a)FreeBSD.org> 
Sent: Friday, December 13, 2019 7:05 AM
To: Moore, Robert <robert.moore(a)intel.com>; Rafael J. Wysocki <rjw(a)rjwysocki.net>; Kaneda, Erik <erik.kaneda(a)intel.com>
Cc: Laster K. <officiallazerl0rd(a)gmail.com>; Wysocki, Rafael J <rafael.j.wysocki(a)intel.com>; linux-acpi(a)vger.kernel.org; devel(a)acpica.org
Subject: Re: [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian

On 19. 12. 12., Moore, Robert wrote:
>> -----Original Message-----
>> From: Rafael J. Wysocki [mailto:rjw(a)rjwysocki.net]
>> Sent: Friday, July 5, 2019 2:44 AM
>> To: Moore, Robert <robert.moore(a)intel.com>; Schmauss, Erik 
>> <erik.schmauss(a)intel.com>
>> Cc: Laster K. <officiallazerl0rd(a)gmail.com>; Wysocki, Rafael J 
>> <rafael.j.wysocki(a)intel.com>; lenb(a)kernel.org; linux- 
>> acpi(a)vger.kernel.org; devel(a)acpica.org
>> Subject: Re: [PATCH] ACPICA: Fix compilation with bare-metal 
>> toolchian
>>
>> On Saturday, June 22, 2019 11:03:54 PM CEST Laster K. wrote:
>>> An ifdef expects to be compiled with full-fledged Linux toolchain, 
>>> but it's common to compile kernel with just bare-metal toolchain 
>>> which doesn't define __linux__. So, also add __KERNEL__ check.
>>>
> [Moore, Robert]
> This sounds OK, as long as no other supported hosts define __KERNEL__.

FreeBSD defines _KERNEL for kernel source.

I'd have to say that this sounds a bit dangerous. Is there another symbol that we can AND into an expression?

JK

>>> Signed-off-by: Laster K. (lazerl0rd) <officiallazerl0rd(a)gmail.com>
>>> ---
>>> Apologies for the multiple/spammed e-mails, I was having mail client
>> issues.
>>>
>>>  include/acpi/platform/acenv.h   | 2 +-
>>>  include/acpi/platform/acenvex.h | 2 +-
>>>  2 files changed, 2 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/include/acpi/platform/acenv.h 
>>> b/include/acpi/platform/acenv.h index 35ab3f87cc29..b69319198cb8
>>> 100644
>>> --- a/include/acpi/platform/acenv.h
>>> +++ b/include/acpi/platform/acenv.h
>>> @@ -148,7 +148,7 @@
>>>
>>>  #endif
>>>
>>> -#if defined(_LINUX) || defined(__linux__)
>>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
>>>  #include <acpi/platform/aclinux.h>
>>>
>>>  #elif defined(_APPLE) || defined(__APPLE__) diff --git 
>>> a/include/acpi/platform/acenvex.h b/include/acpi/platform/acenvex.h 
>>> index 2e36c8344897..c7697a47e33f 100644
>>> --- a/include/acpi/platform/acenvex.h
>>> +++ b/include/acpi/platform/acenvex.h
>>> @@ -19,7 +19,7 @@
>>>   *
>>>
>>> ********************************************************************
>>> **
>>> *******/
>>>
>>> -#if defined(_LINUX) || defined(__linux__)
>>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
>>>  #include <acpi/platform/aclinuxex.h>
>>>
>>>  #elif defined(__DragonFly__)
>>>
>>
>> Erik, Bob, any input here?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
@ 2019-12-13 15:05       ` Jung-uk Kim
  0 siblings, 0 replies; 5+ messages in thread
From: Jung-uk Kim @ 2019-12-13 15:05 UTC (permalink / raw)
  To: Moore, Robert, Rafael J. Wysocki, Kaneda, Erik
  Cc: Laster K., Wysocki, Rafael J, linux-acpi, devel

On 19. 12. 12., Moore, Robert wrote:
>> -----Original Message-----
>> From: Rafael J. Wysocki [mailto:rjw@rjwysocki.net]
>> Sent: Friday, July 5, 2019 2:44 AM
>> To: Moore, Robert <robert.moore@intel.com>; Schmauss, Erik
>> <erik.schmauss@intel.com>
>> Cc: Laster K. <officiallazerl0rd@gmail.com>; Wysocki, Rafael J
>> <rafael.j.wysocki@intel.com>; lenb@kernel.org; linux-
>> acpi@vger.kernel.org; devel@acpica.org
>> Subject: Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
>>
>> On Saturday, June 22, 2019 11:03:54 PM CEST Laster K. wrote:
>>> An ifdef expects to be compiled with full-fledged Linux toolchain, but
>>> it's common to compile kernel with just bare-metal toolchain which
>>> doesn't define __linux__. So, also add __KERNEL__ check.
>>>
> [Moore, Robert] 
> This sounds OK, as long as no other supported hosts define __KERNEL__.

FreeBSD defines _KERNEL for kernel source.

JK

>>> Signed-off-by: Laster K. (lazerl0rd) <officiallazerl0rd@gmail.com>
>>> ---
>>> Apologies for the multiple/spammed e-mails, I was having mail client
>> issues.
>>>
>>>  include/acpi/platform/acenv.h   | 2 +-
>>>  include/acpi/platform/acenvex.h | 2 +-
>>>  2 files changed, 2 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/include/acpi/platform/acenv.h
>>> b/include/acpi/platform/acenv.h index 35ab3f87cc29..b69319198cb8
>>> 100644
>>> --- a/include/acpi/platform/acenv.h
>>> +++ b/include/acpi/platform/acenv.h
>>> @@ -148,7 +148,7 @@
>>>
>>>  #endif
>>>
>>> -#if defined(_LINUX) || defined(__linux__)
>>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
>>>  #include <acpi/platform/aclinux.h>
>>>
>>>  #elif defined(_APPLE) || defined(__APPLE__) diff --git
>>> a/include/acpi/platform/acenvex.h b/include/acpi/platform/acenvex.h
>>> index 2e36c8344897..c7697a47e33f 100644
>>> --- a/include/acpi/platform/acenvex.h
>>> +++ b/include/acpi/platform/acenvex.h
>>> @@ -19,7 +19,7 @@
>>>   *
>>>
>>> **********************************************************************
>>> *******/
>>>
>>> -#if defined(_LINUX) || defined(__linux__)
>>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
>>>  #include <acpi/platform/aclinuxex.h>
>>>
>>>  #elif defined(__DragonFly__)
>>>
>>
>> Erik, Bob, any input here?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
@ 2019-12-13 15:05       ` Jung-uk Kim
  0 siblings, 0 replies; 5+ messages in thread
From: Jung-uk Kim @ 2019-12-13 15:05 UTC (permalink / raw)
  To: devel

[-- Attachment #1: Type: text/plain, Size: 2333 bytes --]

On 19. 12. 12., Moore, Robert wrote:
>> -----Original Message-----
>> From: Rafael J. Wysocki [mailto:rjw(a)rjwysocki.net]
>> Sent: Friday, July 5, 2019 2:44 AM
>> To: Moore, Robert <robert.moore(a)intel.com>; Schmauss, Erik
>> <erik.schmauss(a)intel.com>
>> Cc: Laster K. <officiallazerl0rd(a)gmail.com>; Wysocki, Rafael J
>> <rafael.j.wysocki(a)intel.com>; lenb(a)kernel.org; linux-
>> acpi(a)vger.kernel.org; devel(a)acpica.org
>> Subject: Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
>>
>> On Saturday, June 22, 2019 11:03:54 PM CEST Laster K. wrote:
>>> An ifdef expects to be compiled with full-fledged Linux toolchain, but
>>> it's common to compile kernel with just bare-metal toolchain which
>>> doesn't define __linux__. So, also add __KERNEL__ check.
>>>
> [Moore, Robert] 
> This sounds OK, as long as no other supported hosts define __KERNEL__.

FreeBSD defines _KERNEL for kernel source.

JK

>>> Signed-off-by: Laster K. (lazerl0rd) <officiallazerl0rd(a)gmail.com>
>>> ---
>>> Apologies for the multiple/spammed e-mails, I was having mail client
>> issues.
>>>
>>>  include/acpi/platform/acenv.h   | 2 +-
>>>  include/acpi/platform/acenvex.h | 2 +-
>>>  2 files changed, 2 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/include/acpi/platform/acenv.h
>>> b/include/acpi/platform/acenv.h index 35ab3f87cc29..b69319198cb8
>>> 100644
>>> --- a/include/acpi/platform/acenv.h
>>> +++ b/include/acpi/platform/acenv.h
>>> @@ -148,7 +148,7 @@
>>>
>>>  #endif
>>>
>>> -#if defined(_LINUX) || defined(__linux__)
>>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
>>>  #include <acpi/platform/aclinux.h>
>>>
>>>  #elif defined(_APPLE) || defined(__APPLE__) diff --git
>>> a/include/acpi/platform/acenvex.h b/include/acpi/platform/acenvex.h
>>> index 2e36c8344897..c7697a47e33f 100644
>>> --- a/include/acpi/platform/acenvex.h
>>> +++ b/include/acpi/platform/acenvex.h
>>> @@ -19,7 +19,7 @@
>>>   *
>>>
>>> **********************************************************************
>>> *******/
>>>
>>> -#if defined(_LINUX) || defined(__linux__)
>>> +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
>>>  #include <acpi/platform/aclinuxex.h>
>>>
>>>  #elif defined(__DragonFly__)
>>>
>>
>> Erik, Bob, any input here?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
@ 2019-12-13  1:21   ` Moore, Robert
  2019-12-13 15:05       ` Jung-uk Kim
  0 siblings, 1 reply; 5+ messages in thread
From: Moore, Robert @ 2019-12-13  1:21 UTC (permalink / raw)
  To: devel

[-- Attachment #1: Type: text/plain, Size: 2241 bytes --]



> -----Original Message-----
> From: Rafael J. Wysocki [mailto:rjw(a)rjwysocki.net]
> Sent: Friday, July 5, 2019 2:44 AM
> To: Moore, Robert <robert.moore(a)intel.com>; Schmauss, Erik
> <erik.schmauss(a)intel.com>
> Cc: Laster K. <officiallazerl0rd(a)gmail.com>; Wysocki, Rafael J
> <rafael.j.wysocki(a)intel.com>; lenb(a)kernel.org; linux-
> acpi(a)vger.kernel.org; devel(a)acpica.org
> Subject: Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian
> 
> On Saturday, June 22, 2019 11:03:54 PM CEST Laster K. wrote:
> > An ifdef expects to be compiled with full-fledged Linux toolchain, but
> > it's common to compile kernel with just bare-metal toolchain which
> > doesn't define __linux__. So, also add __KERNEL__ check.
> >
[Moore, Robert] 
This sounds OK, as long as no other supported hosts define __KERNEL__.

> > Signed-off-by: Laster K. (lazerl0rd) <officiallazerl0rd(a)gmail.com>
> > ---
> > Apologies for the multiple/spammed e-mails, I was having mail client
> issues.
> >
> >  include/acpi/platform/acenv.h   | 2 +-
> >  include/acpi/platform/acenvex.h | 2 +-
> >  2 files changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/include/acpi/platform/acenv.h
> > b/include/acpi/platform/acenv.h index 35ab3f87cc29..b69319198cb8
> > 100644
> > --- a/include/acpi/platform/acenv.h
> > +++ b/include/acpi/platform/acenv.h
> > @@ -148,7 +148,7 @@
> >
> >  #endif
> >
> > -#if defined(_LINUX) || defined(__linux__)
> > +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
> >  #include <acpi/platform/aclinux.h>
> >
> >  #elif defined(_APPLE) || defined(__APPLE__) diff --git
> > a/include/acpi/platform/acenvex.h b/include/acpi/platform/acenvex.h
> > index 2e36c8344897..c7697a47e33f 100644
> > --- a/include/acpi/platform/acenvex.h
> > +++ b/include/acpi/platform/acenvex.h
> > @@ -19,7 +19,7 @@
> >   *
> >
> > **********************************************************************
> > *******/
> >
> > -#if defined(_LINUX) || defined(__linux__)
> > +#if defined(_LINUX) || defined(__KERNEL__) || defined(__linux__)
> >  #include <acpi/platform/aclinuxex.h>
> >
> >  #elif defined(__DragonFly__)
> >
> 
> Erik, Bob, any input here?
> 
> 

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-01-22 17:07 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-22 17:07 [Devel] Re: [PATCH] ACPICA: Fix compilation with bare-metal toolchian Moore, Robert
  -- strict thread matches above, loose matches on Subject: below --
2019-12-18 18:09 Moore, Robert
2019-06-22 21:03 Laster K.
2019-07-05  9:43 ` Rafael J. Wysocki
2019-12-13  1:21   ` [Devel] " Moore, Robert
2019-12-13 15:05     ` Jung-uk Kim
2019-12-13 15:05       ` Jung-uk Kim

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.