kernels/linux-2.4.0/arch/s390/kernel/signal.c
/*
 * OK, we're invoking a handler
 */
OK, we're invoking a handler
OK we ' re invoking a handler
static void
handle_signal(unsigned long sig, struct k_sigaction *ka,
	      siginfo_t *info, sigset_t *oldset, struct pt_regs * regs)
{
	if (regs->orig_gpr2 >= 0) {
		switch (regs->gprs[2]) {
			case -ERESTARTNOHAND:
				regs->gprs[2] = -EINTR;
				break;
			case -ERESTARTSYS:
				if (!(ka->sa.sa_flags & SA_RESTART)) {
					regs->gprs[2] = -EINTR;
					break;
				}
			case -ERESTARTNOINTR:
				regs->gprs[2] = regs->orig_gpr2;
				regs->psw.addr -= 2;
		}
	}
	if (ka->sa.sa_flags & SA_SIGINFO)
		setup_rt_frame(sig, ka, info, oldset, regs);
	else
		setup_frame(sig, ka, oldset, regs);
	if (ka->sa.sa_flags & SA_ONESHOT)
		ka->sa.sa_handler = SIG_DFL;
	if (!(ka->sa.sa_flags & SA_NODEFER)) {
		spin_lock_irq(&current->sigmask_lock);
		sigorsets(&current->blocked,&current->blocked,&ka->sa.sa_mask);
		sigaddset(&current->blocked,sig);
		recalc_sigpending(current);
		spin_unlock_irq(&current->sigmask_lock);
	}
}
static void handle_signal ( unsigned long sig , struct k_sigaction * ka , siginfo_t * info , sigset_t * oldset , struct pt_regs * regs ) { if ( regs -> orig_gpr2 >= 0 ) { switch ( regs -> gprs [ 2 ] ) { case - ERESTARTNOHAND : regs -> gprs [ 2 ] = - EINTR ; break ; case - ERESTARTSYS : if ( ! ( ka -> sa . sa_flags & SA_RESTART ) ) { regs -> gprs [ 2 ] = - EINTR ; break ; } case - ERESTARTNOINTR : regs -> gprs [ 2 ] = regs -> orig_gpr2 ; regs -> psw . addr -= 2 ; } } if ( ka -> sa . sa_flags & SA_SIGINFO ) setup_rt_frame ( sig , ka , info , oldset , regs ) ; else setup_frame ( sig , ka , oldset , regs ) ; if ( ka -> sa . sa_flags & SA_ONESHOT ) ka -> sa . sa_handler = SIG_DFL ; if ( ! ( ka -> sa . sa_flags & SA_NODEFER ) ) { spin_lock_irq ( & current -> sigmask_lock ) ; sigorsets ( & current -> blocked , & current -> blocked , & ka -> sa . sa_mask ) ; sigaddset ( & current -> blocked , sig ) ; recalc_sigpending ( current ) ; spin_unlock_irq ( & current -> sigmask_lock ) ; } }
OK, we're invoking a handler
OK we ' re invoking a handler
/* Are we from a system call? */ /* If so, check system call restarting.. */ /* fallthrough */ /* Set up the stack frame */