linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
@ 2016-10-13 23:51 Yisheng Xie
  2016-10-17 22:26 ` Zheng, Lv
  0 siblings, 1 reply; 9+ messages in thread
From: Yisheng Xie @ 2016-10-13 23:51 UTC (permalink / raw)
  To: robert.moore, lv.zheng, rafael.j.wysocki, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

when try to cross compile acpi tool in dir kernel/tools
for arm64 use command:
    make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- acpi
it failed with the following log:
In file included
    from ../../../../../include/acpi/acpi.h:58:0,
    from ../../../../../drivers/acpi/acpica/utstring.c:44:
    ../../../../../include/acpi/actypes.h:130:34: error: conflicting types for 's64'
 typedef signed long long s64;
                           ^
In file included
    from /opt/aarch64-linux-gnu/libc/usr/include/asm-generic/types.h:6:0
    from /opt/aarch64-linux-gnu/libc/usr/include/asm/types.h:1,
    from ../../../../../include/uapi/linux/types.h:4,
    from ../../../../../include/linux/types.h:5,
    from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19,
    from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
    from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
    from ../../../../../include/acpi/platform/acenv.h:365,
    from ../../../../../include/acpi/acpi.h:56,
    from ./acpidump.h:55,
    from ../../os_specific/service_layers/oslinuxtbl.c:44:
../../../../../include/asm-generic/int-ll64.h:24:26: note: previous declaration of 's64' was here
 typedef signed long long s64;
                           ^
Fix this compile problem.

Fixes: e323c02dee59 ("ACPICA: MSVC9: Fix <sys/stat.h> inclusion order issue")
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
---
 include/acpi/platform/acenv.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/include/acpi/platform/acenv.h b/include/acpi/platform/acenv.h
index 34cce72..0089fa0 100644
--- a/include/acpi/platform/acenv.h
+++ b/include/acpi/platform/acenv.h
@@ -361,9 +361,13 @@
 #include <stdio.h>
 #include <fcntl.h>
 #include <errno.h>
+#ifdef __aarch64__
+#include <sys/stat.h>
+#else
 #include <time.h>
 #include <signal.h>
 #endif
+#endif
 
 #endif				/* ACPI_USE_STANDARD_HEADERS */
 
-- 
1.7.12.4

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

* RE: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-13 23:51 [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64 Yisheng Xie
@ 2016-10-17 22:26 ` Zheng, Lv
  2016-10-18 11:46   ` Yisheng Xie
  0 siblings, 1 reply; 9+ messages in thread
From: Zheng, Lv @ 2016-10-17 22:26 UTC (permalink / raw)
  To: Yisheng Xie, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

Hi, Yisheng

> From: Yisheng Xie [mailto:xieyisheng1@huawei.com]
> Subject: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
> 
> when try to cross compile acpi tool in dir kernel/tools
> for arm64 use command:
>     make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- acpi
> it failed with the following log:
> In file included
>     from ../../../../../include/acpi/acpi.h:58:0,
>     from ../../../../../drivers/acpi/acpica/utstring.c:44:
>     ../../../../../include/acpi/actypes.h:130:34: error: conflicting types for 's64'
>  typedef signed long long s64;
>                            ^
> In file included
>     from /opt/aarch64-linux-gnu/libc/usr/include/asm-generic/types.h:6:0
>     from /opt/aarch64-linux-gnu/libc/usr/include/asm/types.h:1,
>     from ../../../../../include/uapi/linux/types.h:4,
>     from ../../../../../include/linux/types.h:5,
>     from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19,
>     from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>     from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>     from ../../../../../include/acpi/platform/acenv.h:365,
>     from ../../../../../include/acpi/acpi.h:56,
>     from ./acpidump.h:55,
>     from ../../os_specific/service_layers/oslinuxtbl.c:44:
> ../../../../../include/asm-generic/int-ll64.h:24:26: note: previous declaration of 's64' was here
>  typedef signed long long s64;
>                            ^
> Fix this compile problem.

This looks like a conflict between asm-generic/int-ll64.h and actypes.h.

When a build environment actually has s64 definition.
ACPICA shouldn't define it.
ACPICA should define ACPI_USE_SYSTEM_INTTYPES instead.

However it is not clear if a Linux userspace should be aware of s64.
We couldn't see this issue in other arch builds.
So I wonder if this is just a missing "#ifdef __KERNEL__" in asm-generic/int-ll64.h.

If Linux should be aware of s64.
Then ACPICA definition of s64 should be disabled by defining ACPI_USE_SYSTEM_INTTYPES.
Since this is a post-ACPICA-release issue.
You should only fix it in tools/power/acpi/Makefile*.

So I think this patch is not a right fix, but a wrong workaround.
It can easily cause regressions in other ACPICA builds.

> 
> Fixes: e323c02dee59 ("ACPICA: MSVC9: Fix <sys/stat.h> inclusion order issue")
> Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
> ---
>  include/acpi/platform/acenv.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/include/acpi/platform/acenv.h b/include/acpi/platform/acenv.h
> index 34cce72..0089fa0 100644
> --- a/include/acpi/platform/acenv.h
> +++ b/include/acpi/platform/acenv.h
> @@ -361,9 +361,13 @@
>  #include <stdio.h>
>  #include <fcntl.h>
>  #include <errno.h>
> +#ifdef __aarch64__
> +#include <sys/stat.h>
> +#else
>  #include <time.h>
>  #include <signal.h>
>  #endif
> +#endif
> 
>  #endif				/* ACPI_USE_STANDARD_HEADERS */


We shouldn't rely on inclusion orders to fix this issue.
It can easily cause order problem on other ACPICA build environment.

Thanks
Lv

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

* Re: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-17 22:26 ` Zheng, Lv
@ 2016-10-18 11:46   ` Yisheng Xie
  2016-10-18 22:07     ` Zheng, Lv
  0 siblings, 1 reply; 9+ messages in thread
From: Yisheng Xie @ 2016-10-18 11:46 UTC (permalink / raw)
  To: Zheng, Lv, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

Hi, Lv

On 2016/10/18 6:26, Zheng, Lv wrote:
> Hi, Yisheng
> 
>> From: Yisheng Xie [mailto:xieyisheng1@huawei.com]
>> Subject: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
>>
>> when try to cross compile acpi tool in dir kernel/tools
>> for arm64 use command:
>>     make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- acpi
>> it failed with the following log:
>> In file included
>>     from ../../../../../include/acpi/acpi.h:58:0,
>>     from ../../../../../drivers/acpi/acpica/utstring.c:44:
>>     ../../../../../include/acpi/actypes.h:130:34: error: conflicting types for 's64'
>>  typedef signed long long s64;
>>                            ^
>> In file included
>>     from /opt/aarch64-linux-gnu/libc/usr/include/asm-generic/types.h:6:0
>>     from /opt/aarch64-linux-gnu/libc/usr/include/asm/types.h:1,
>>     from ../../../../../include/uapi/linux/types.h:4,
>>     from ../../../../../include/linux/types.h:5,
>>     from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19,
>>     from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>>     from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>>     from ../../../../../include/acpi/platform/acenv.h:365,
>>     from ../../../../../include/acpi/acpi.h:56,
>>     from ./acpidump.h:55,
>>     from ../../os_specific/service_layers/oslinuxtbl.c:44:
>> ../../../../../include/asm-generic/int-ll64.h:24:26: note: previous declaration of 's64' was here
>>  typedef signed long long s64;
>>                            ^
>> Fix this compile problem.
> 
> This looks like a conflict between asm-generic/int-ll64.h and actypes.h.
> 
> When a build environment actually has s64 definition.
> ACPICA shouldn't define it.
> ACPICA should define ACPI_USE_SYSTEM_INTTYPES instead.
> 
> However it is not clear if a Linux userspace should be aware of s64.
> We couldn't see this issue in other arch builds.
> So I wonder if this is just a missing "#ifdef __KERNEL__" in asm-generic/int-ll64.h.
> 
> If Linux should be aware of s64.
> Then ACPICA definition of s64 should be disabled by defining ACPI_USE_SYSTEM_INTTYPES.
> Since this is a post-ACPICA-release issue.
> You should only fix it in tools/power/acpi/Makefile*.
> 
> So I think this patch is not a right fix, but a wrong workaround.
> It can easily cause regressions in other ACPICA builds.
> 
Thank you for your reply.
You are right that the  ACPI_USE_SYSTEM_INTTYPES in Makefile can fixed compile error,
I listed in change log. And I also have tried that way.
However, it still have many other errors.(I am sorry to not have listed all of them.)

>From the following log, you can see, all of the conflict type is from signal.h.
And maybe this patch is a better way to fix these compile error, without too much
change of code.

Are you sure that it will cause order problem when build ACPICA on other build
environment, for it only effect aarch64.

Thanks
Yisheng.

----------detail compile error log---------
In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
                 from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
                 from ../../../../../include/acpi/platform/acenv.h:365,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
../../../../../include/linux/types.h:14:26: error: conflicting types for 'fd_set'
 typedef __kernel_fd_set  fd_set;
                          ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:219:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/sys/select.h:75:5: note: previous declaration of 'fd_set' was here
   } fd_set;
     ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
                 from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
                 from ../../../../../include/acpi/platform/acenv.h:365,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
../../../../../include/linux/types.h:15:25: error: conflicting types for 'dev_t'
 typedef __kernel_dev_t  dev_t;
                         ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:60:17: note: previous declaration of 'dev_t' was here
 typedef __dev_t dev_t;
                 ^
...
In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
                 from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
                 from ../../../../../include/acpi/platform/acenv.h:365,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
../../../../../include/linux/types.h:25:26: error: conflicting types for 'timer_t'
 typedef __kernel_timer_t timer_t;
                          ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:132:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/time.h:103:19: note: previous declaration of 'timer_t' was here
 typedef __timer_t timer_t;
                   ^
...
In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
                 from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
                 from ../../../../../include/acpi/platform/acenv.h:365,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
../../../../../include/linux/types.h:45:26: error: conflicting types for 'loff_t'
 typedef __kernel_loff_t  loff_t;
                          ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:44:18: note: previous declaration of 'loff_t' was here
 typedef __loff_t loff_t;
                  ^
...
In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
                 from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
                 from ../../../../../include/acpi/platform/acenv.h:365,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
../../../../../include/linux/types.h:112:17: error: conflicting types for 'u_int64_t'
 typedef  __u64  u_int64_t;
                 ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:203:1: note: previous declaration of 'u_int64_t' was here
 __u_intN_t (64, __DI__);
 ^
...
In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
                 from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
                 from ../../../../../include/acpi/platform/acenv.h:365,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
../../../../../include/linux/types.h:113:17: error: conflicting types for 'int64_t'
 typedef  __s64  int64_t;
                 ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:197:1: note: previous declaration of 'int64_t' was here
 __intN_t (64, __DI__);
 ^
...
In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
                 from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
                 from ../../../../../include/acpi/platform/acenv.h:365,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
../../../../../include/linux/types.h:134:23: error: conflicting types for 'blkcnt_t'
 typedef unsigned long blkcnt_t;
                       ^
In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/tbprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:235:20: note: previous declaration of 'blkcnt_t' was here
 typedef __blkcnt_t blkcnt_t;  /* Type to count number of disk blocks.  */
                    ^

					

					
In file included from /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:219:0,
                 from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314,
                 from ../../../../../include/acpi/platform/acenv.h:357,
                 from ../../../../../include/acpi/acpi.h:56,
                 from acpidbg.c:12:
acpidbg.c: In function 'acpi_aml_set_fd':
../../../../../drivers/acpi/acpica/utprint.c:352:5: error: conflicting types for 'vsnprintf'
 int vsnprintf(char *string, acpi_size size, const char *format, va_list args)
     ^
...
In file included from ../../../../../include/acpi/platform/acenv.h:361:0,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/utprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/stdio.h:390:12: note: previous declaration of 'vsnprintf' was here
 extern int vsnprintf (char *__restrict __s, size_t __maxlen,
            ^
....
../../../../../drivers/acpi/acpica/utprint.c:599:5: error: conflicting types for 'snprintf'
 int snprintf(char *string, acpi_size size, const char *format, ...)
     ^

In file included from ../../../../../include/acpi/platform/acenv.h:361:0,
                 from ../../../../../include/acpi/acpi.h:56,
                 from ../../../../../drivers/acpi/acpica/utprint.c:44:
/opt/aarch64-linux-gnu/libc/usr/include/stdio.h:386:12: note: previous declaration of 'snprintf' was here
 extern int snprintf (char *__restrict __s, size_t __maxlen,
            ^
...
acpidbg.c:303:25: warning: passing argument 2 of 'select' from incompatible pointer type [-Wincompatible-pointer-types]
   ret = select(maxfd+1, &rfds, &wfds, NULL, &tv);
                         ^
....
acpidbg.c:309:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
    if (FD_ISSET(STDIN_FILENO, &rfds))
        ^
make[2]: *** [utprint.o] Error 1
acpidbg.c:311:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
    if (FD_ISSET(fd, &wfds)) {
        ^
acpidbg.c:317:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
    if (FD_ISSET(fd, &rfds)) {
        ^
acpidbg.c:323:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
    if (FD_ISSET(STDOUT_FILENO, &wfds)) {
        ^

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

* RE: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-18 11:46   ` Yisheng Xie
@ 2016-10-18 22:07     ` Zheng, Lv
  2016-10-20  1:45       ` Yisheng Xie
  0 siblings, 1 reply; 9+ messages in thread
From: Zheng, Lv @ 2016-10-18 22:07 UTC (permalink / raw)
  To: Yisheng Xie, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

Hi,

> From: Yisheng Xie [mailto:xieyisheng1@huawei.com]
> Sent: Tuesday, October 18, 2016 4:47 AM
> To: Zheng, Lv <lv.zheng@intel.com>; Moore, Robert <robert.moore@intel.com>; Wysocki, Rafael J
> <rafael.j.wysocki@intel.com>; lenb@kernel.org; wmiles@sgl.com
> Cc: linux-acpi@vger.kernel.org; devel@acpica.org; linux-kernel@vger.kernel.org; guohanjun@huawei.com;
> wangxiongfeng2@huawei.com
> Subject: Re: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
> 
> Hi, Lv
> 
> On 2016/10/18 6:26, Zheng, Lv wrote:
> > Hi, Yisheng
> >
> >> From: Yisheng Xie [mailto:xieyisheng1@huawei.com]
> >> Subject: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
> >>
> >> when try to cross compile acpi tool in dir kernel/tools
> >> for arm64 use command:
> >>     make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- acpi
> >> it failed with the following log:
> >> In file included
> >>     from ../../../../../include/acpi/acpi.h:58:0,
> >>     from ../../../../../drivers/acpi/acpica/utstring.c:44:
> >>     ../../../../../include/acpi/actypes.h:130:34: error: conflicting types for 's64'
> >>  typedef signed long long s64;
> >>                            ^
> >> In file included
> >>     from /opt/aarch64-linux-gnu/libc/usr/include/asm-generic/types.h:6:0
> >>     from /opt/aarch64-linux-gnu/libc/usr/include/asm/types.h:1,
> >>     from ../../../../../include/uapi/linux/types.h:4,
> >>     from ../../../../../include/linux/types.h:5,
> >>     from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19,
> >>     from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
> >>     from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
> >>     from ../../../../../include/acpi/platform/acenv.h:365,
> >>     from ../../../../../include/acpi/acpi.h:56,
> >>     from ./acpidump.h:55,
> >>     from ../../os_specific/service_layers/oslinuxtbl.c:44:
> >> ../../../../../include/asm-generic/int-ll64.h:24:26: note: previous declaration of 's64' was here
> >>  typedef signed long long s64;
> >>                            ^
> >> Fix this compile problem.
> >
> > This looks like a conflict between asm-generic/int-ll64.h and actypes.h.
> >
> > When a build environment actually has s64 definition.
> > ACPICA shouldn't define it.
> > ACPICA should define ACPI_USE_SYSTEM_INTTYPES instead.
> >
> > However it is not clear if a Linux userspace should be aware of s64.
> > We couldn't see this issue in other arch builds.
> > So I wonder if this is just a missing "#ifdef __KERNEL__" in asm-generic/int-ll64.h.
> >
> > If Linux should be aware of s64.
> > Then ACPICA definition of s64 should be disabled by defining ACPI_USE_SYSTEM_INTTYPES.
> > Since this is a post-ACPICA-release issue.
> > You should only fix it in tools/power/acpi/Makefile*.
> >
> > So I think this patch is not a right fix, but a wrong workaround.
> > It can easily cause regressions in other ACPICA builds.
> >
> Thank you for your reply.
> You are right that the  ACPI_USE_SYSTEM_INTTYPES in Makefile can fixed compile error,

I'm not sure what you mean.
I mean you need ACPI_USE_SYSTEM_INTTYPES in case s64 has already been defined in that environment.
Are you sure s64 should be defined for your environment?

IMO, s64 is kernel space specific, while you are compiling user space tools.
It looks to me like there is something wrong with ARM kernel's asm/types.h.

> I listed in change log. And I also have tried that way.
> However, it still have many other errors.(I am sorry to not have listed all of them.)
> 
> From the following log, you can see, all of the conflict type is from signal.h.
> And maybe this patch is a better way to fix these compile error, without too much
> change of code.
> 
> Are you sure that it will cause order problem when build ACPICA on other build
> environment, for it only effect aarch64.
> 
> Thanks
> Yisheng.
> 
> ----------detail compile error log---------
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>                  from ../../../../../include/acpi/platform/acenv.h:365,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> ../../../../../include/linux/types.h:14:26: error: conflicting types for 'fd_set'
>  typedef __kernel_fd_set  fd_set;
>                           ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:219:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/sys/select.h:75:5: note: previous declaration of 'fd_set' was
> here
>    } fd_set;
>      ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>                  from ../../../../../include/acpi/platform/acenv.h:365,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> ../../../../../include/linux/types.h:15:25: error: conflicting types for 'dev_t'
>  typedef __kernel_dev_t  dev_t;
>                          ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:60:17: note: previous declaration of 'dev_t' was
> here
>  typedef __dev_t dev_t;
>                  ^
> ...
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>                  from ../../../../../include/acpi/platform/acenv.h:365,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> ../../../../../include/linux/types.h:25:26: error: conflicting types for 'timer_t'
>  typedef __kernel_timer_t timer_t;
>                           ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:132:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/time.h:103:19: note: previous declaration of 'timer_t' was
> here
>  typedef __timer_t timer_t;
>                    ^
> ...
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>                  from ../../../../../include/acpi/platform/acenv.h:365,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> ../../../../../include/linux/types.h:45:26: error: conflicting types for 'loff_t'
>  typedef __kernel_loff_t  loff_t;
>                           ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:44:18: note: previous declaration of 'loff_t' was
> here
>  typedef __loff_t loff_t;
>                   ^
> ...
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>                  from ../../../../../include/acpi/platform/acenv.h:365,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> ../../../../../include/linux/types.h:112:17: error: conflicting types for 'u_int64_t'
>  typedef  __u64  u_int64_t;
>                  ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:203:1: note: previous declaration of 'u_int64_t'
> was here
>  __u_intN_t (64, __DI__);
>  ^
> ...
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>                  from ../../../../../include/acpi/platform/acenv.h:365,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> ../../../../../include/linux/types.h:113:17: error: conflicting types for 'int64_t'
>  typedef  __s64  int64_t;
>                  ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:197:1: note: previous declaration of 'int64_t' was
> here
>  __intN_t (64, __DI__);
>  ^
> ...
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/asm/sigcontext.h:19:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/bits/sigcontext.h:27,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/signal.h:308,
>                  from ../../../../../include/acpi/platform/acenv.h:365,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> ../../../../../include/linux/types.h:134:23: error: conflicting types for 'blkcnt_t'
>  typedef unsigned long blkcnt_t;
>                        ^
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314:0,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/tbprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:235:20: note: previous declaration of 'blkcnt_t'
> was here
>  typedef __blkcnt_t blkcnt_t;  /* Type to count number of disk blocks.  */
>                     ^
> 
> 
> 
> 
> In file included from /opt/aarch64-linux-gnu/libc/usr/include/sys/types.h:219:0,
>                  from /opt/aarch64-linux-gnu/libc/usr/include/stdlib.h:314,
>                  from ../../../../../include/acpi/platform/acenv.h:357,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from acpidbg.c:12:
> acpidbg.c: In function 'acpi_aml_set_fd':
> ../../../../../drivers/acpi/acpica/utprint.c:352:5: error: conflicting types for 'vsnprintf'
>  int vsnprintf(char *string, acpi_size size, const char *format, va_list args)
>      ^
> ...
> In file included from ../../../../../include/acpi/platform/acenv.h:361:0,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/utprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/stdio.h:390:12: note: previous declaration of 'vsnprintf' was
> here
>  extern int vsnprintf (char *__restrict __s, size_t __maxlen,
>             ^
> ....
> ../../../../../drivers/acpi/acpica/utprint.c:599:5: error: conflicting types for 'snprintf'
>  int snprintf(char *string, acpi_size size, const char *format, ...)
>      ^
> 
> In file included from ../../../../../include/acpi/platform/acenv.h:361:0,
>                  from ../../../../../include/acpi/acpi.h:56,
>                  from ../../../../../drivers/acpi/acpica/utprint.c:44:
> /opt/aarch64-linux-gnu/libc/usr/include/stdio.h:386:12: note: previous declaration of 'snprintf' was
> here
>  extern int snprintf (char *__restrict __s, size_t __maxlen,
>             ^
> ...
> acpidbg.c:303:25: warning: passing argument 2 of 'select' from incompatible pointer type [-
> Wincompatible-pointer-types]
>    ret = select(maxfd+1, &rfds, &wfds, NULL, &tv);
>                          ^
> ....
> acpidbg.c:309:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
>     if (FD_ISSET(STDIN_FILENO, &rfds))
>         ^
> make[2]: *** [utprint.o] Error 1
> acpidbg.c:311:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
>     if (FD_ISSET(fd, &wfds)) {
>         ^
> acpidbg.c:317:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
>     if (FD_ISSET(fd, &rfds)) {
>         ^
> acpidbg.c:323:8: error: 'fd_set {aka struct <anonymous>}' has no member named '__fds_bits'
>     if (FD_ISSET(STDOUT_FILENO, &wfds)) {
>         ^


I'm not sure what this is.
How did you get this?
Were you compiling kernel acpi tools or compiling the kernel itself?

For tool compilation, are you sure you have correctly configured your cross-compilation environment?
Will you see problems in compiling ACPICA applications from:
https://github.com/acpica/acpica

Thanks
Lv

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

* Re: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-18 22:07     ` Zheng, Lv
@ 2016-10-20  1:45       ` Yisheng Xie
  2016-10-20 18:42         ` Zheng, Lv
  0 siblings, 1 reply; 9+ messages in thread
From: Yisheng Xie @ 2016-10-20  1:45 UTC (permalink / raw)
  To: Zheng, Lv, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

Hi,

On 2016/10/19 6:07, Zheng, Lv wrote:
> Hi,
> 
> I'm not sure what you mean.
> I mean you need ACPI_USE_SYSTEM_INTTYPES in case s64 has already been defined in that environment.
> Are you sure s64 should be defined for your environment?
> 
s64 is not defined in my build environment but in kernel code.

> IMO, s64 is kernel space specific, while you are compiling user space tools.
> It looks to me like there is something wrong with ARM kernel's asm/types.h.
> 
>> I listed in change log. And I also have tried that way.
>> However, it still have many other errors.(I am sorry to not have listed all of them.)
>>
>> From the following log, you can see, all of the conflict type is from signal.h.
>> And maybe this patch is a better way to fix these compile error, without too much
>> change of code.
>>
>> Are you sure that it will cause order problem when build ACPICA on other build
>> environment, for it only effect aarch64.
> 
> I'm not sure what this is.
> How did you get this?
> Were you compiling kernel acpi tools or compiling the kernel itself?
> 
It's about compiling kernel acpi tools.

> For tool compilation, are you sure you have correctly configured your cross-compilation environment?
Maybe it is not my cross-compilation environment problem, for your also can reproduce it,
as your said in another email, right?

> Will you see problems in compiling ACPICA applications from:
> https://github.com/acpica/acpica
> 

> Thanks
> Lv
> 
> .
> 

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

* RE: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-20  1:45       ` Yisheng Xie
@ 2016-10-20 18:42         ` Zheng, Lv
  2016-10-21 19:40           ` Zheng, Lv
  0 siblings, 1 reply; 9+ messages in thread
From: Zheng, Lv @ 2016-10-20 18:42 UTC (permalink / raw)
  To: Yisheng Xie, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

Hi,

> From: linux-acpi-owner@vger.kernel.org [mailto:linux-acpi-owner@vger.kernel.org] On Behalf Of Yisheng
> Xie
> Subject: Re: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
> 
> Hi,
> 
> On 2016/10/19 6:07, Zheng, Lv wrote:
> > Hi,
> >
> > I'm not sure what you mean.
> > I mean you need ACPI_USE_SYSTEM_INTTYPES in case s64 has already been defined in that environment.
> > Are you sure s64 should be defined for your environment?
> >
> s64 is not defined in my build environment but in kernel code.

Yes, in-kernel ACPICA applications trickily reused this to get it compiled in kernel source tree with minimal porting effort.
And it is working on x86.

> 
> > IMO, s64 is kernel space specific, while you are compiling user space tools.
> > It looks to me like there is something wrong with ARM kernel's asm/types.h.
> >
> >> I listed in change log. And I also have tried that way.
> >> However, it still have many other errors.(I am sorry to not have listed all of them.)
> >>
> >> From the following log, you can see, all of the conflict type is from signal.h.
> >> And maybe this patch is a better way to fix these compile error, without too much
> >> change of code.
> >>
> >> Are you sure that it will cause order problem when build ACPICA on other build
> >> environment, for it only effect aarch64.
> >
> > I'm not sure what this is.
> > How did you get this?
> > Were you compiling kernel acpi tools or compiling the kernel itself?
> >
> It's about compiling kernel acpi tools.
> 
> > For tool compilation, are you sure you have correctly configured your cross-compilation environment?
> Maybe it is not my cross-compilation environment problem, for your also can reproduce it,
> as your said in another email, right?

Yes, I reproduced it.
By commenting out <signal.h> inclusion from acenv.h.
Tools can be built by aarch64-linux-gnu tool chain downloaded from linaro.

However this is still not the root cause, IMO.

Thanks
Lv

> 
> > Will you see problems in compiling ACPICA applications from:
> > https://github.com/acpica/acpica
> >
> 
> > 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

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

* RE: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-20 18:42         ` Zheng, Lv
@ 2016-10-21 19:40           ` Zheng, Lv
  2016-10-24  8:01             ` Yisheng Xie
  0 siblings, 1 reply; 9+ messages in thread
From: Zheng, Lv @ 2016-10-21 19:40 UTC (permalink / raw)
  To: Zheng, Lv, Yisheng Xie, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

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

Hi,

I generated a solution with tools/power/acpi makefiles.
Please give it a try.
Sorry for the hackish build includes.

Thanks and best regards
Lv

> From: linux-acpi-owner@vger.kernel.org [mailto:linux-acpi-owner@vger.kernel.org] On Behalf Of Zheng,
> Lv
> Subject: RE: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
> 
> Hi,
> 
> > From: linux-acpi-owner@vger.kernel.org [mailto:linux-acpi-owner@vger.kernel.org] On Behalf Of
> Yisheng
> > Xie
> > Subject: Re: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
> >
> > Hi,
> >
> > On 2016/10/19 6:07, Zheng, Lv wrote:
> > > Hi,
> > >
> > > I'm not sure what you mean.
> > > I mean you need ACPI_USE_SYSTEM_INTTYPES in case s64 has already been defined in that environment.
> > > Are you sure s64 should be defined for your environment?
> > >
> > s64 is not defined in my build environment but in kernel code.
> 
> Yes, in-kernel ACPICA applications trickily reused this to get it compiled in kernel source tree with
> minimal porting effort.
> And it is working on x86.
> 
> >
> > > IMO, s64 is kernel space specific, while you are compiling user space tools.
> > > It looks to me like there is something wrong with ARM kernel's asm/types.h.
> > >
> > >> I listed in change log. And I also have tried that way.
> > >> However, it still have many other errors.(I am sorry to not have listed all of them.)
> > >>
> > >> From the following log, you can see, all of the conflict type is from signal.h.
> > >> And maybe this patch is a better way to fix these compile error, without too much
> > >> change of code.
> > >>
> > >> Are you sure that it will cause order problem when build ACPICA on other build
> > >> environment, for it only effect aarch64.
> > >
> > > I'm not sure what this is.
> > > How did you get this?
> > > Were you compiling kernel acpi tools or compiling the kernel itself?
> > >
> > It's about compiling kernel acpi tools.
> >
> > > For tool compilation, are you sure you have correctly configured your cross-compilation
> environment?
> > Maybe it is not my cross-compilation environment problem, for your also can reproduce it,
> > as your said in another email, right?
> 
> Yes, I reproduced it.
> By commenting out <signal.h> inclusion from acenv.h.
> Tools can be built by aarch64-linux-gnu tool chain downloaded from linaro.
> 
> However this is still not the root cause, IMO.
> 
> Thanks
> Lv
> 
> >
> > > Will you see problems in compiling ACPICA applications from:
> > > https://github.com/acpica/acpica
> > >
> >
> > > 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
> --
> 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

[-- Attachment #2: lv-tools1.patch --]
[-- Type: application/octet-stream, Size: 3305 bytes --]

From: Lv Zheng <lv.zheng@intel.com>
Subject: [PATCH] tools/power/acpi: Remove direct kernel source include reference

ACPICA tools trickily uses integer types, and trickily includes kernel
include directory directly, which breaks tools build for some cross
compilers. This patch fixes this build issue.

Reported-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
---
Index: linux-acpica/tools/power/acpi/Makefile
===================================================================
--- linux-acpica.orig/tools/power/acpi/Makefile
+++ linux-acpica/tools/power/acpi/Makefile
@@ -11,11 +11,17 @@
 include ../../scripts/Makefile.include
 
 all: acpidbg acpidump ec
-clean: acpidbg_clean acpidump_clean ec_clean
+clean: acpidbg_clean acpidump_clean include_clean ec_clean
 install: acpidbg_install acpidump_install ec_install
 uninstall: acpidbg_uninstall acpidump_uninstall ec_uninstall
+include/acpi:
+	mkdir -p include
+	ln -s ../../../../include/acpi include/acpi
+include_clean:
+	rm -f include/acpi
+	rm -rf include
 
-acpidbg acpidump ec: FORCE
+acpidbg acpidump ec: include/acpi FORCE
 	$(call descend,tools/$@,all)
 acpidbg_clean acpidump_clean ec_clean:
 	$(call descend,tools/$(@:_clean=),clean)
Index: linux-acpica/tools/power/acpi/tools/acpidbg/Makefile
===================================================================
--- linux-acpica.orig/tools/power/acpi/tools/acpidbg/Makefile
+++ linux-acpica/tools/power/acpi/tools/acpidbg/Makefile
@@ -19,7 +19,7 @@ vpath %.c \
 CFLAGS += -DACPI_APPLICATION -DACPI_SINGLE_THREAD -DACPI_DEBUGGER\
 	-I.\
 	-I../../../../../drivers/acpi/acpica\
-	-I../../../../../include
+	-I../../include
 LDFLAGS += -lpthread
 TOOL_OBJS = \
 	acpidbg.o
Index: linux-acpica/tools/power/acpi/tools/acpidbg/acpidbg.c
===================================================================
--- linux-acpica.orig/tools/power/acpi/tools/acpidbg/acpidbg.c
+++ linux-acpica/tools/power/acpi/tools/acpidbg/acpidbg.c
@@ -12,10 +12,16 @@
 #include <acpi/acpi.h>
 
 /* Headers not included by include/acpi/platform/aclinux.h */
+#include <unistd.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <error.h>
 #include <stdbool.h>
 #include <fcntl.h>
 #include <assert.h>
-#include <linux/circ_buf.h>
+#include <sys/select.h>
+#include "../../../../../include/linux/circ_buf.h"
 
 #define ACPI_AML_FILE		"/sys/kernel/debug/acpi/acpidbg"
 #define ACPI_AML_SEC_TICK	1
Index: linux-acpica/tools/power/acpi/tools/acpidump/Makefile
===================================================================
--- linux-acpica.orig/tools/power/acpi/tools/acpidump/Makefile
+++ linux-acpica/tools/power/acpi/tools/acpidump/Makefile
@@ -21,7 +21,7 @@ vpath %.c \
 	../../os_specific/service_layers
 CFLAGS += -DACPI_DUMP_APP -I.\
 	-I../../../../../drivers/acpi/acpica\
-	-I../../../../../include
+	-I../../include
 TOOL_OBJS = \
 	apdump.o\
 	apfiles.o\
Index: linux-acpica/include/acpi/platform/aclinux.h
===================================================================
--- linux-acpica.orig/include/acpi/platform/aclinux.h
+++ linux-acpica/include/acpi/platform/aclinux.h
@@ -191,6 +191,9 @@
 #ifndef __init
 #define __init
 #endif
+#ifndef __iomem
+#define __iomem
+#endif
 
 /* Host-dependent types and defines for user-space ACPICA */
 

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

* Re: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-21 19:40           ` Zheng, Lv
@ 2016-10-24  8:01             ` Yisheng Xie
  2016-10-24 14:25               ` Zheng, Lv
  0 siblings, 1 reply; 9+ messages in thread
From: Yisheng Xie @ 2016-10-24  8:01 UTC (permalink / raw)
  To: Zheng, Lv, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2



On 2016/10/22 3:40, Zheng, Lv wrote:
> Hi,
> 
> I generated a solution with tools/power/acpi makefiles.
> Please give it a try.
Hi Lv,
Your patch also works.

> Sorry for the hackish build includes.
> 
> Thanks and best regards
> Lv
> 

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

* RE: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
  2016-10-24  8:01             ` Yisheng Xie
@ 2016-10-24 14:25               ` Zheng, Lv
  0 siblings, 0 replies; 9+ messages in thread
From: Zheng, Lv @ 2016-10-24 14:25 UTC (permalink / raw)
  To: Yisheng Xie, Moore, Robert, Wysocki, Rafael J, lenb, wmiles
  Cc: linux-acpi, devel, linux-kernel, guohanjun, wangxiongfeng2

Hi

> From: linux-acpi-owner@vger.kernel.org [mailto:linux-acpi-owner@vger.kernel.org] On Behalf Of Yisheng
> Xie
> Subject: Re: [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64
> 
> 
> 
> On 2016/10/22 3:40, Zheng, Lv wrote:
> > Hi,
> >
> > I generated a solution with tools/power/acpi makefiles.
> > Please give it a try.
> Hi Lv,
> Your patch also works.

Thanks for the test.
I'll send it to the community for review.

Best regards
Lv

> 
> > Sorry for the hackish build includes.
> >
> > Thanks and best regards
> > 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

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

end of thread, other threads:[~2016-10-24 14:25 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-10-13 23:51 [PATCH] ACPICA: arm64: fix compile apci tools fail for arm64 Yisheng Xie
2016-10-17 22:26 ` Zheng, Lv
2016-10-18 11:46   ` Yisheng Xie
2016-10-18 22:07     ` Zheng, Lv
2016-10-20  1:45       ` Yisheng Xie
2016-10-20 18:42         ` Zheng, Lv
2016-10-21 19:40           ` Zheng, Lv
2016-10-24  8:01             ` Yisheng Xie
2016-10-24 14:25               ` Zheng, Lv

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).