qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] linux-user: Fix build failure caused by missing __u64 on musl
@ 2024-10-22 12:29 Yao Zi
  2024-10-22 13:47 ` Laurent Vivier
  2024-10-22 18:21 ` Richard Henderson
  0 siblings, 2 replies; 3+ messages in thread
From: Yao Zi @ 2024-10-22 12:29 UTC (permalink / raw)
  To: Laurent Vivier, qemu-devel; +Cc: Michael Vogt, Yao Zi

Commit 9651cead2f ("linux-user: add openat2 support in linux-user")
ships a definition of struct open_how_ver0 while assuming type __u64 is
available in code, which is not the case when building QEMU on musl.
Let's replaces __u64 with uint64_t.

Fixes: 9651cead2f ("linux-user: add openat2 support in linux-user")
Signed-off-by: Yao Zi <ziyao@disroot.org>
---
 linux-user/syscall_defs.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 0ade83745e..0e08dfae3e 100644
--- a/linux-user/syscall_defs.h
+++ b/linux-user/syscall_defs.h
@@ -2750,9 +2750,9 @@ struct target_sched_param {
 
 /* from kernel's include/uapi/linux/openat2.h */
 struct open_how_ver0 {
-    __u64 flags;
-    __u64 mode;
-    __u64 resolve;
+    uint64_t flags;
+    uint64_t mode;
+    uint64_t resolve;
 };
 struct target_open_how_ver0 {
     abi_ullong flags;
-- 
2.46.2



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

* Re: [PATCH] linux-user: Fix build failure caused by missing __u64 on musl
  2024-10-22 12:29 [PATCH] linux-user: Fix build failure caused by missing __u64 on musl Yao Zi
@ 2024-10-22 13:47 ` Laurent Vivier
  2024-10-22 18:21 ` Richard Henderson
  1 sibling, 0 replies; 3+ messages in thread
From: Laurent Vivier @ 2024-10-22 13:47 UTC (permalink / raw)
  To: Yao Zi, qemu-devel; +Cc: Michael Vogt

Le 22/10/2024 à 14:29, Yao Zi a écrit :
> Commit 9651cead2f ("linux-user: add openat2 support in linux-user")
> ships a definition of struct open_how_ver0 while assuming type __u64 is
> available in code, which is not the case when building QEMU on musl.
> Let's replaces __u64 with uint64_t.
> 
> Fixes: 9651cead2f ("linux-user: add openat2 support in linux-user")
> Signed-off-by: Yao Zi <ziyao@disroot.org>
> ---
>   linux-user/syscall_defs.h | 6 +++---
>   1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
> index 0ade83745e..0e08dfae3e 100644
> --- a/linux-user/syscall_defs.h
> +++ b/linux-user/syscall_defs.h
> @@ -2750,9 +2750,9 @@ struct target_sched_param {
>   
>   /* from kernel's include/uapi/linux/openat2.h */
>   struct open_how_ver0 {
> -    __u64 flags;
> -    __u64 mode;
> -    __u64 resolve;
> +    uint64_t flags;
> +    uint64_t mode;
> +    uint64_t resolve;
>   };
>   struct target_open_how_ver0 {
>       abi_ullong flags;

Reviewed-by: Laurent Vivier <laurent@vivier.eu>


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

* Re: [PATCH] linux-user: Fix build failure caused by missing __u64 on musl
  2024-10-22 12:29 [PATCH] linux-user: Fix build failure caused by missing __u64 on musl Yao Zi
  2024-10-22 13:47 ` Laurent Vivier
@ 2024-10-22 18:21 ` Richard Henderson
  1 sibling, 0 replies; 3+ messages in thread
From: Richard Henderson @ 2024-10-22 18:21 UTC (permalink / raw)
  To: Yao Zi, Laurent Vivier, qemu-devel; +Cc: Michael Vogt

On 10/22/24 05:29, Yao Zi wrote:
> Commit 9651cead2f ("linux-user: add openat2 support in linux-user")
> ships a definition of struct open_how_ver0 while assuming type __u64 is
> available in code, which is not the case when building QEMU on musl.
> Let's replaces __u64 with uint64_t.
> 
> Fixes: 9651cead2f ("linux-user: add openat2 support in linux-user")
> Signed-off-by: Yao Zi <ziyao@disroot.org>
> ---
>   linux-user/syscall_defs.h | 6 +++---
>   1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
> index 0ade83745e..0e08dfae3e 100644
> --- a/linux-user/syscall_defs.h
> +++ b/linux-user/syscall_defs.h
> @@ -2750,9 +2750,9 @@ struct target_sched_param {
>   
>   /* from kernel's include/uapi/linux/openat2.h */
>   struct open_how_ver0 {
> -    __u64 flags;
> -    __u64 mode;
> -    __u64 resolve;
> +    uint64_t flags;
> +    uint64_t mode;
> +    uint64_t resolve;
>   };
>   struct target_open_how_ver0 {
>       abi_ullong flags;

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

Queued, thanks.

r~


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

end of thread, other threads:[~2024-10-22 18:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-22 12:29 [PATCH] linux-user: Fix build failure caused by missing __u64 on musl Yao Zi
2024-10-22 13:47 ` Laurent Vivier
2024-10-22 18:21 ` Richard Henderson

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