Lines Matching refs:signal

92 	if (unlikely(t->signal->flags & SIGNAL_UNKILLABLE) &&  in sig_task_ignored()
129 static inline bool has_pending_signals(sigset_t *signal, sigset_t *blocked) in has_pending_signals() argument
137 ready |= signal->sig[i] &~ blocked->sig[i]; in has_pending_signals()
140 case 4: ready = signal->sig[3] &~ blocked->sig[3]; in has_pending_signals()
141 ready |= signal->sig[2] &~ blocked->sig[2]; in has_pending_signals()
142 ready |= signal->sig[1] &~ blocked->sig[1]; in has_pending_signals()
143 ready |= signal->sig[0] &~ blocked->sig[0]; in has_pending_signals()
146 case 2: ready = signal->sig[1] &~ blocked->sig[1]; in has_pending_signals()
147 ready |= signal->sig[0] &~ blocked->sig[0]; in has_pending_signals()
150 case 1: ready = signal->sig[0] &~ blocked->sig[0]; in has_pending_signals()
155 #define PENDING(p,b) has_pending_signals(&(p)->signal, (b))
161 PENDING(&t->signal->shared_pending, &t->blocked) || in recalc_sigpending_tsk()
205 s = pending->signal.sig; in next_signal()
360 struct signal_struct *sig = task->signal; in task_participate_group_stop()
387 struct signal_struct *sig = current->signal; in task_join_group_stop()
459 sigemptyset(&queue->signal); in flush_sigqueue()
477 flush_sigqueue(&t->signal->shared_pending); in flush_signals()
485 sigset_t signal, retain; in __flush_itimer_signals() local
488 signal = pending->signal; in __flush_itimer_signals()
497 sigdelset(&signal, sig); in __flush_itimer_signals()
503 sigorsets(&pending->signal, &signal, &retain); in __flush_itimer_signals()
513 __flush_itimer_signals(&tsk->signal->shared_pending); in flush_itimer_signals()
583 sigdelset(&list->signal, sig); in collect_signal()
638 signr = __dequeue_signal(&tsk->signal->shared_pending, in dequeue_signal()
655 struct hrtimer *tmr = &tsk->signal->real_timer; in dequeue_signal()
658 tsk->signal->it_real_incr != 0) { in dequeue_signal()
660 tsk->signal->it_real_incr); in dequeue_signal()
715 if (!((pending->signal.sig[0] & ~tsk->blocked.sig[0]) & SYNCHRONOUS_MASK)) in dequeue_synchronous_signal()
739 sigdelset(&pending->signal, sync->info.si_signo); in dequeue_synchronous_signal()
787 sigandsets(&m, mask, &s->signal); in flush_sigqueue_mask()
791 sigandnsets(&s->signal, &s->signal, mask); in flush_sigqueue_mask()
904 struct signal_struct *signal = p->signal; in prepare_signal() local
908 if (signal->flags & SIGNAL_GROUP_EXIT) { in prepare_signal()
909 if (signal->core_state) in prepare_signal()
920 flush_sigqueue_mask(&flush, &signal->shared_pending); in prepare_signal()
929 flush_sigqueue_mask(&flush, &signal->shared_pending); in prepare_signal()
949 if (signal->flags & SIGNAL_STOP_STOPPED) in prepare_signal()
951 else if (signal->group_stop_count) in prepare_signal()
960 signal_set_stop_flags(signal, why | SIGNAL_STOP_CONTINUED); in prepare_signal()
961 signal->group_stop_count = 0; in prepare_signal()
962 signal->group_exit_code = 0; in prepare_signal()
996 struct signal_struct *signal = p->signal; in complete_signal() local
1016 t = signal->curr_target; in complete_signal()
1019 if (t == signal->curr_target) in complete_signal()
1027 signal->curr_target = t; in complete_signal()
1035 (signal->core_state || !(signal->flags & SIGNAL_GROUP_EXIT)) && in complete_signal()
1048 signal->flags = SIGNAL_GROUP_EXIT; in complete_signal()
1049 signal->group_exit_code = sig; in complete_signal()
1050 signal->group_stop_count = 0; in complete_signal()
1051 __for_each_thread(signal, t) { in complete_signal()
1053 sigaddset(&t->pending.signal, SIGKILL); in complete_signal()
1070 return (sig < SIGRTMIN) && sigismember(&signals->signal, sig); in legacy_queue()
1087 pending = (type != PIDTYPE_PID) ? &t->signal->shared_pending : &t->pending; in __send_signal_locked()
1168 sigaddset(&pending->signal, sig); in __send_signal_locked()
1173 hlist_for_each_entry(delayed, &t->signal->multiprocess, node) { in __send_signal_locked()
1174 sigset_t *signal = &delayed->signal; in __send_signal_locked() local
1177 sigdelsetmask(signal, SIG_KERNEL_STOP_MASK); in __send_signal_locked()
1179 sigdelset(signal, SIGCONT); in __send_signal_locked()
1180 sigaddset(signal, sig); in __send_signal_locked()
1350 t->signal->flags &= ~SIGNAL_UNKILLABLE; in force_sig_info_to_task()
1373 p->signal->group_stop_count = 0; in zap_other_threads()
1382 sigaddset(&t->pending.signal, SIGKILL); in zap_other_threads()
2019 pending = (type != PIDTYPE_PID) ? &t->signal->shared_pending : &t->pending; in send_sigqueue()
2021 sigaddset(&pending->signal, sig); in send_sigqueue()
2101 info.si_utime = nsec_to_clock_t(utime + tsk->signal->utime); in do_notify_parent()
2102 info.si_stime = nsec_to_clock_t(stime + tsk->signal->stime); in do_notify_parent()
2200 info.si_status = tsk->signal->group_exit_code & 0x7f; in do_notify_parent_cldstop()
2437 struct signal_struct *sig = current->signal; in do_signal_stop()
2554 struct signal_struct *signal = current->signal; in do_jobctl_trap() local
2558 if (!signal->group_stop_count && in do_jobctl_trap()
2559 !(signal->flags & SIGNAL_STOP_STOPPED)) in do_jobctl_trap()
2686 struct signal_struct *signal = current->signal; in get_signal() local
2714 if (unlikely(signal->flags & SIGNAL_CLD_MASK)) { in get_signal()
2717 if (signal->flags & SIGNAL_CLD_CONTINUED) in get_signal()
2722 signal->flags &= ~SIGNAL_CLD_MASK; in get_signal()
2750 if ((signal->flags & SIGNAL_GROUP_EXIT) || in get_signal()
2751 signal->group_exec_task) { in get_signal()
2753 sigdelset(&current->pending.signal, SIGKILL); in get_signal()
2843 if (unlikely(signal->flags & SIGNAL_UNKILLABLE) && in get_signal()
2979 sigandsets(&retarget, &tsk->signal->shared_pending.signal, which); in retarget_shared_pending()
3011 if (thread_group_empty(tsk) || (tsk->signal->flags & SIGNAL_GROUP_EXIT)) { in exit_signals()
3260 sigorsets(set, &current->pending.signal, in do_sigpending()
3261 &current->signal->shared_pending.signal); in do_sigpending()
4157 flush_sigqueue_mask(&mask, &current->signal->shared_pending); in kernel_sigaction()
4225 flush_sigqueue_mask(&mask, &p->signal->shared_pending); in do_sigaction()
4669 SYSCALL_DEFINE2(signal, int, sig, __sighandler_t, handler) in SYSCALL_DEFINE2() argument