diff options
author | Avi Kivity <avi@redhat.com> | 2010-08-01 17:29:21 +0300 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2010-08-01 17:29:21 +0300 |
commit | ab8c54b5a08ed8ad3d7bb930c306785b471b2d7e (patch) | |
tree | 7adefa1a3150575571da77f6e382aa8a2a6bdd3b /linux-user/signal.c | |
parent | f229c5df0796c02fc39279db24b114cc04757c4a (diff) | |
parent | fd2f659ee3f6f991f4f194f3fde5c9f957fd663d (diff) |
Merge commit 'fd2f659ee3f6f991f4f194f3fde5c9f957fd663d' into upstream-merge
* commit 'fd2f659ee3f6f991f4f194f3fde5c9f957fd663d': (58 commits)
Update version for 0.13.0-rc0
vnc: better default values for VNC options
vnc: tight: split send_sub_rect
vnc: tight: fix rgb_prepare_row
vnc: add missing lock for vnc_cursor_define()
vnc: threaded VNC server
qemu-thread: add qemu_mutex/cond_destroy and qemu_mutex_exit
vnc: fix tight png memory leak
vnc: encapsulate encoding members
vnc: tight: stop using qdict for palette stuff
vnc: tight: specific zlib level and filters for each compression level
vnc: tight add PNG encoding
vnc: tight: remove a memleak in send_jpeg_rect()
vnc: tight: don't forget do at the last color
vnc: rename vnc-encoding-* vnc-enc-*
ui: move all ui components in ui/
vnc: add lossy option
vnc: JPEG should be disabled if the client don't set tight quality
vnc: tight: add JPEG and gradient subencoding with smooth image detection
Initial documentation for migration
...
Merge 0.13 branch point.
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'linux-user/signal.c')
-rw-r--r-- | linux-user/signal.c | 26 |
1 files changed, 20 insertions, 6 deletions
diff --git a/linux-user/signal.c b/linux-user/signal.c index cc0cb10cd..77683f753 100644 --- a/linux-user/signal.c +++ b/linux-user/signal.c @@ -3064,9 +3064,23 @@ struct target_sigcontext { uint32_t oldmask; }; +struct target_stack_t { + abi_ulong ss_sp; + int ss_flags; + unsigned int ss_size; +}; + +struct target_ucontext { + abi_ulong uc_flags; + abi_ulong uc_link; + struct target_stack_t uc_stack; + struct target_sigcontext sc; + uint32_t extramask[TARGET_NSIG_WORDS - 1]; +}; + /* Signal frames. */ struct target_signal_frame { - struct target_sigcontext sc; + struct target_ucontext uc; uint32_t extramask[TARGET_NSIG_WORDS - 1]; uint32_t tramp[2]; }; @@ -3175,7 +3189,7 @@ static void setup_frame(int sig, struct target_sigaction *ka, goto badframe; /* Save the mask. */ - err |= __put_user(set->sig[0], &frame->sc.oldmask); + err |= __put_user(set->sig[0], &frame->uc.sc.oldmask); if (err) goto badframe; @@ -3184,7 +3198,7 @@ static void setup_frame(int sig, struct target_sigaction *ka, goto badframe; } - setup_sigcontext(&frame->sc, env); + setup_sigcontext(&frame->uc.sc, env); /* Set up to return from userspace. If provided, use a stub already in userspace. */ @@ -3214,7 +3228,7 @@ static void setup_frame(int sig, struct target_sigaction *ka, /* Signal handler args: */ env->regs[5] = sig; /* Arg 0: signum */ env->regs[6] = 0; - env->regs[7] = (unsigned long) &frame->sc; /* arg 1: sigcontext */ + env->regs[7] = (unsigned long) &frame->uc; /* arg 1: sigcontext */ /* Offset of 4 to handle microblaze rtid r14, 0 */ env->sregs[SR_PC] = (unsigned long)ka->_sa_handler; @@ -3247,7 +3261,7 @@ long do_sigreturn(CPUState *env) goto badframe; /* Restore blocked signals */ - if (__get_user(target_set.sig[0], &frame->sc.oldmask)) + if (__get_user(target_set.sig[0], &frame->uc.sc.oldmask)) goto badframe; for(i = 1; i < TARGET_NSIG_WORDS; i++) { if (__get_user(target_set.sig[i], &frame->extramask[i - 1])) @@ -3256,7 +3270,7 @@ long do_sigreturn(CPUState *env) target_to_host_sigset_internal(&set, &target_set); sigprocmask(SIG_SETMASK, &set, NULL); - restore_sigcontext(&frame->sc, env); + restore_sigcontext(&frame->uc.sc, env); /* We got here through a sigreturn syscall, our path back is via an rtb insn so setup r14 for that. */ env->regs[14] = env->sregs[SR_PC]; |