mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-07-27 04:13:53 -06:00
bsd-user/signal.c: Implement signal_init()
Initialize the signal state for the emulator. Setup a set of sane default signal handlers, mirroring the host's signals. For fatal signals (those that exit by default), establish our own set of signal handlers. Stub out the actual signal handler we use for the moment. Signed-off-by: Stacey Son <sson@FreeBSD.org> Signed-off-by: Kyle Evans <kevans@freebsd.org> Signed-off-by: Warner Losh <imp@bsdimp.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> XXX SIGPROF PENDING
This commit is contained in:
parent
1366ef817a
commit
149076ade7
2 changed files with 74 additions and 0 deletions
|
@ -94,6 +94,13 @@ typedef struct TaskState {
|
|||
* from multiple threads.)
|
||||
*/
|
||||
int signal_pending;
|
||||
/*
|
||||
* This thread's signal mask, as requested by the guest program.
|
||||
* The actual signal mask of this thread may differ:
|
||||
* + we don't let SIGSEGV and SIGBUS be blocked while running guest code
|
||||
* + sometimes we block all signals to avoid races
|
||||
*/
|
||||
sigset_t signal_mask;
|
||||
|
||||
uint8_t stack[];
|
||||
} __attribute__((aligned(16))) TaskState;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue