diff options
author | Aurelien Jarno <aurelien@aurel32.net> | 2010-03-29 02:12:51 +0200 |
---|---|---|
committer | Aurelien Jarno <aurelien@aurel32.net> | 2010-04-01 21:51:58 +0200 |
commit | 60e99246d6b4d1de32aec3281483cdd85b415570 (patch) | |
tree | eceb5960b58ccc461b6b242bd9c6a66e11db2e7a /cpu-exec.c | |
parent | 9bc6304c156dcc01c619672ca33d7152bb18bcb9 (diff) |
linux-user/ia64: workaround ia64 strangenesses
ia64 has some strangenesses that need to be workaround:
- it has a __clone2() syscall instead of the using clone() one, with
different arguments, and which is not declared in the usual headers.
- ucontext.uc_sigmask is declared with type long int, while it is
actually of type sigset_t.
- uc_mcontext, uc_sigmask, uc_stack, uc_link are declared using #define,
which clashes with the target_ucontext fields. Change their names to
tuc_*, as already done for some target architectures.
Diffstat (limited to 'cpu-exec.c')
-rw-r--r-- | cpu-exec.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/cpu-exec.c b/cpu-exec.c index bcfcda207b..372aeac1a3 100644 --- a/cpu-exec.c +++ b/cpu-exec.c @@ -81,7 +81,11 @@ void cpu_resume_from_signal(CPUState *env1, void *puc) if (puc) { /* XXX: use siglongjmp ? */ #ifdef __linux__ +#ifdef __ia64 + sigprocmask(SIG_SETMASK, (sigset_t *)&uc->uc_sigmask, NULL); +#else sigprocmask(SIG_SETMASK, &uc->uc_sigmask, NULL); +#endif #elif defined(__OpenBSD__) sigprocmask(SIG_SETMASK, &uc->sc_mask, NULL); #endif @@ -1150,7 +1154,7 @@ int cpu_signal_handler(int host_signum, void *pinfo, void *puc) } return handle_cpu_signal(ip, (unsigned long)info->si_addr, is_write, - &uc->uc_sigmask, puc); + (sigset_t *)&uc->uc_sigmask, puc); } #elif defined(__s390__) |