Changeset View
Changeset View
Standalone View
Standalone View
sys/mips/mips/pm_machdep.c
Show First 20 Lines • Show All 141 Lines • ▼ Show 20 Lines | sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask) | ||||
if (SIGISMEMBER(psp->ps_siginfo, sig)) { | if (SIGISMEMBER(psp->ps_siginfo, sig)) { | ||||
/* Signal handler installed with SA_SIGINFO. */ | /* Signal handler installed with SA_SIGINFO. */ | ||||
regs->a1 = (register_t)(intptr_t)&sfp->sf_si; | regs->a1 = (register_t)(intptr_t)&sfp->sf_si; | ||||
/* sf.sf_ahu.sf_action = (__siginfohandler_t *)catcher; */ | /* sf.sf_ahu.sf_action = (__siginfohandler_t *)catcher; */ | ||||
/* fill siginfo structure */ | /* fill siginfo structure */ | ||||
sf.sf_si = ksi->ksi_info; | sf.sf_si = ksi->ksi_info; | ||||
sf.sf_si.si_signo = sig; | sf.sf_si.si_signo = sig; | ||||
sf.sf_si.si_code = ksi->ksi_code; | |||||
sf.sf_si.si_addr = (void*)(intptr_t)regs->badvaddr; | |||||
} else { | } else { | ||||
/* Old FreeBSD-style arguments. */ | /* Old FreeBSD-style arguments. */ | ||||
regs->a1 = ksi->ksi_code; | regs->a1 = ksi->ksi_code; | ||||
regs->a3 = regs->badvaddr; | regs->a3 = (uintptr_t)ksi->ksi_addr; | ||||
/* sf.sf_ahu.sf_handler = catcher; */ | /* sf.sf_ahu.sf_handler = catcher; */ | ||||
} | } | ||||
mtx_unlock(&psp->ps_mtx); | mtx_unlock(&psp->ps_mtx); | ||||
PROC_UNLOCK(p); | PROC_UNLOCK(p); | ||||
/* | /* | ||||
* Copy the sigframe out to the user's stack. | * Copy the sigframe out to the user's stack. | ||||
▲ Show 20 Lines • Show All 347 Lines • Show Last 20 Lines |