Patchwork linux-user: Fix sparc32plus stat64 syscalls.

login
register
mail settings
Submitter Richard Henderson
Date April 26, 2010, 5:27 p.m.
Message ID <1272302842-7987-1-git-send-email-rth@twiddle.net>
Download mbox | patch
Permalink /patch/50983/
State New
Headers show

Comments

Richard Henderson - April 26, 2010, 5:27 p.m.
Check TARGET_ABI_BITS, not TARGET_LONG_BITS, when deciding
whether or not the guest needs special 64-bit stat translation.

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 linux-user/syscall.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
Blue Swirl - April 26, 2010, 5:34 p.m.
Thanks, applied.

On 4/26/10, Richard Henderson <rth@twiddle.net> wrote:
> Check TARGET_ABI_BITS, not TARGET_LONG_BITS, when deciding
>  whether or not the guest needs special 64-bit stat translation.
>
>  Signed-off-by: Richard Henderson <rth@twiddle.net>
>  ---
>   linux-user/syscall.c |    2 +-
>   1 files changed, 1 insertions(+), 1 deletions(-)
>
>  diff --git a/linux-user/syscall.c b/linux-user/syscall.c
>  index 26c0fb4..eb77ade 100644
>  --- a/linux-user/syscall.c
>  +++ b/linux-user/syscall.c
>  @@ -4021,7 +4021,7 @@ static inline abi_long host_to_target_stat64(void *cpu_env,
>      } else
>   #endif
>      {
>  -#if (TARGET_LONG_BITS == 64) && (!defined(TARGET_ALPHA))
>  +#if TARGET_ABI_BITS == 64 && !defined(TARGET_ALPHA)
>          struct target_stat *target_st;
>   #else
>          struct target_stat64 *target_st;
>
> --
>  1.6.6.1
>
>

Patch

diff --git a/linux-user/syscall.c b/linux-user/syscall.c
index 26c0fb4..eb77ade 100644
--- a/linux-user/syscall.c
+++ b/linux-user/syscall.c
@@ -4021,7 +4021,7 @@  static inline abi_long host_to_target_stat64(void *cpu_env,
     } else
 #endif
     {
-#if (TARGET_LONG_BITS == 64) && (!defined(TARGET_ALPHA))
+#if TARGET_ABI_BITS == 64 && !defined(TARGET_ALPHA)
         struct target_stat *target_st;
 #else
         struct target_stat64 *target_st;