Changed the signal handling code so that handle_signals() can be called without
having the thread lock held and interrupts disabled. Cleaned up the signal handling code, and fixed some minor bugs with blockable vs. non-blockable signals. thread_debug_info was using uint64 for signals sets instead of sigset_t. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14457 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -11,29 +11,29 @@
|
||||
|
||||
|
||||
#define KILL_SIGNALS ((1L << (SIGKILL - 1)) | (1L << (SIGKILLTHR - 1)))
|
||||
#define BLOCKABLE_SIGS (~(KILL_SIGNALS | (1L << (SIGSTOP - 1))))
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern int handle_signals(struct thread *t, cpu_status *state);
|
||||
extern bool handle_signals(struct thread *thread);
|
||||
extern bool is_kill_signal_pending(void);
|
||||
extern int has_signals_pending(void *_thread);
|
||||
|
||||
extern int sigaction_etc(thread_id threadID, int signal,
|
||||
const struct sigaction *act, struct sigaction *oact);
|
||||
const struct sigaction *act, struct sigaction *oldAction);
|
||||
|
||||
extern int _user_send_signal(pid_t tid, uint sig);
|
||||
extern int _user_sigprocmask(int how, const sigset_t *set, sigset_t *oldSet);
|
||||
extern int _user_sigaction(int sig, const struct sigaction *action, struct sigaction *oldAction);
|
||||
extern int _user_sigaction(int sig, const struct sigaction *action,
|
||||
struct sigaction *oldAction);
|
||||
extern bigtime_t _user_set_alarm(bigtime_t time, uint32 mode);
|
||||
extern int _user_sigsuspend(const sigset_t *mask);
|
||||
extern int _user_sigpending(sigset_t *set);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _KERNEL_SIGNAL_H */
|
||||
|
||||
@@ -55,9 +55,9 @@ struct thread_debug_info {
|
||||
port_id debug_port;
|
||||
// the port the thread is waiting on for commands from the nub thread
|
||||
|
||||
uint64 ignore_signals;
|
||||
sigset_t ignore_signals;
|
||||
// the signals the debugger is not interested in
|
||||
uint64 ignore_signals_once;
|
||||
sigset_t ignore_signals_once;
|
||||
// the signals the debugger wishes not to be notified of, when they
|
||||
// occur the next time
|
||||
|
||||
|
||||
Reference in New Issue
Block a user