From c355804023f1c2468290994160115275efd42173 Mon Sep 17 00:00:00 2001 From: deraadt Date: Sat, 1 Feb 1997 21:49:30 +0000 Subject: [PATCH] add type & union sigval args to sendsig/trapsignal --- sys/arch/i386/i386/freebsd_machdep.c | 7 +- sys/arch/i386/i386/linux_machdep.c | 7 +- sys/arch/i386/i386/machdep.c | 95 +++---------------------- sys/arch/i386/i386/svr4_machdep.c | 14 ++-- sys/arch/i386/i386/trap.c | 32 ++++++--- sys/arch/i386/i386/vm86.c | 4 +- sys/arch/i386/include/freebsd_machdep.h | 2 +- sys/arch/i386/include/linux_machdep.h | 2 +- sys/arch/i386/include/svr4_machdep.h | 2 +- sys/arch/i386/isa/npx.c | 2 +- sys/compat/ibcs2/ibcs2_exec.c | 4 +- sys/compat/sunos/sunos.h | 4 +- sys/kern/kern_sig.c | 35 +++++++-- sys/sys/proc.h | 5 +- sys/sys/siginfo.h | 5 +- sys/sys/signalvar.h | 7 +- 16 files changed, 95 insertions(+), 132 deletions(-) diff --git a/sys/arch/i386/i386/freebsd_machdep.c b/sys/arch/i386/i386/freebsd_machdep.c index a27a24630ef..48b9381fc52 100644 --- a/sys/arch/i386/i386/freebsd_machdep.c +++ b/sys/arch/i386/i386/freebsd_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: freebsd_machdep.c,v 1.8 1997/01/27 22:47:57 deraadt Exp $ */ +/* $OpenBSD: freebsd_machdep.c,v 1.9 1997/02/01 21:53:18 deraadt Exp $ */ /* $NetBSD: freebsd_machdep.c,v 1.10 1996/05/03 19:42:05 christos Exp $ */ /*- @@ -76,11 +76,12 @@ * specified pc, psl. */ void -freebsd_sendsig(catcher, sig, mask, code, addr) +freebsd_sendsig(catcher, sig, mask, code, type, val) sig_t catcher; int sig, mask; u_long code; - caddr_t addr; + int type; + union sigval val; { register struct proc *p = curproc; register struct trapframe *tf; diff --git a/sys/arch/i386/i386/linux_machdep.c b/sys/arch/i386/i386/linux_machdep.c index 52d9bcd578a..4b6e195cf98 100644 --- a/sys/arch/i386/i386/linux_machdep.c +++ b/sys/arch/i386/i386/linux_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: linux_machdep.c,v 1.9 1997/01/27 22:47:58 deraadt Exp $ */ +/* $OpenBSD: linux_machdep.c,v 1.10 1997/02/01 21:53:20 deraadt Exp $ */ /* $NetBSD: linux_machdep.c,v 1.29 1996/05/03 19:42:11 christos Exp $ */ /* @@ -104,11 +104,12 @@ int linux_write_ldt __P((struct proc *, struct linux_sys_modify_ldt_args *, */ void -linux_sendsig(catcher, sig, mask, code, addr) +linux_sendsig(catcher, sig, mask, code, type, val) sig_t catcher; int sig, mask; u_long code; - caddr_t addr; + int type; + union sigval val; { register struct proc *p = curproc; register struct trapframe *tf; diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c index 51ab4809612..aff31758dff 100644 --- a/sys/arch/i386/i386/machdep.c +++ b/sys/arch/i386/i386/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.38 1997/02/01 00:58:25 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.39 1997/02/01 21:53:23 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.202 1996/05/18 15:54:59 christos Exp $ */ /*- @@ -570,18 +570,19 @@ cpu_sysctl(name, namelen, oldp, oldlenp, newp, newlen, p) } #ifdef COMPAT_IBCS2 -void ibcs2_sendsig __P((sig_t, int, int, u_long, caddr_t)); +void ibcs2_sendsig __P((sig_t, int, int, u_long, int, union sigval)); void -ibcs2_sendsig(catcher, sig, mask, code, addr) +ibcs2_sendsig(catcher, sig, mask, code, type, val) sig_t catcher; int sig, mask; u_long code; - caddr_t addr; + int type; + union sigval val; { extern int bsd_to_ibcs2_sig[]; - sendsig(catcher, bsd_to_ibcs2_sig[sig], mask, code, addr); + sendsig(catcher, bsd_to_ibcs2_sig[sig], mask, code, type, val); } #endif @@ -596,11 +597,12 @@ ibcs2_sendsig(catcher, sig, mask, code, addr) * specified pc, psl. */ void -sendsig(catcher, sig, mask, code, addr) +sendsig(catcher, sig, mask, code, type, val) sig_t catcher; int sig, mask; u_long code; - caddr_t addr; + int type; + union sigval val; { register struct proc *p = curproc; register struct trapframe *tf; @@ -671,15 +673,7 @@ sendsig(catcher, sig, mask, code, addr) if (psp->ps_siginfo & sigmask(sig)) { frame.sf_sip = &fp->sf_si; - initsiginfo(frame.sf_sip, sig); - fixsiginfo(frame.sf_sip, sig, code, addr); - if (sig == SIGSEGV) { - /* try to be more specific about read or write */ - if (tf->tf_err & PGEX_W) - frame.sf_si.si_code = SEGV_ACCERR; - else - frame.sf_si.si_code = SEGV_MAPERR; - } + initsiginfo(frame.sf_sip, sig, code, type, val); } /* XXX don't copyout siginfo if not needed? */ @@ -788,75 +782,6 @@ sys_sigreturn(p, v, retval) return (EJUSTRETURN); } -void -fixsiginfo(si, sig, code, addr) - siginfo_t *si; - int sig; - u_long code; - caddr_t addr; -{ - si->si_addr = addr; - - switch (code) { - case T_PRIVINFLT: - si->si_code = ILL_PRVOPC; - si->si_trapno = T_PRIVINFLT; - break; - case T_BPTFLT: - si->si_code = TRAP_BRKPT; - si->si_trapno = T_BPTFLT; - break; - case T_ARITHTRAP: - si->si_code = FPE_INTOVF; - si->si_trapno = T_DIVIDE; - break; - case T_PROTFLT: - si->si_code = SEGV_ACCERR; - si->si_trapno = T_PROTFLT; - break; - case T_TRCTRAP: - si->si_code = TRAP_TRACE; - si->si_trapno = T_TRCTRAP; - break; - case T_PAGEFLT: - si->si_code = SEGV_ACCERR; - si->si_trapno = T_PAGEFLT; - break; - case T_ALIGNFLT: - si->si_code = BUS_ADRALN; - si->si_trapno = T_ALIGNFLT; - break; - case T_DIVIDE: - si->si_code = FPE_FLTDIV; - si->si_trapno = T_DIVIDE; - break; - case T_OFLOW: - si->si_code = FPE_FLTOVF; - si->si_trapno = T_DIVIDE; - break; - case T_BOUND: - si->si_code = FPE_FLTSUB; - si->si_trapno = T_BOUND; - break; - case T_DNA: - si->si_code = FPE_FLTINV; - si->si_trapno = T_DNA; - break; - case T_FPOPFLT: - si->si_code = FPE_FLTINV; - si->si_trapno = T_FPOPFLT; - break; - case T_SEGNPFLT: - si->si_code = SEGV_MAPERR; - si->si_trapno = T_SEGNPFLT; - break; - case T_STKFLT: - si->si_code = ILL_BADSTK; - si->si_trapno = T_STKFLT; - break; - } -} - int waittime = -1; struct pcb dumppcb; diff --git a/sys/arch/i386/i386/svr4_machdep.c b/sys/arch/i386/i386/svr4_machdep.c index 1d3a1c241bd..0bdfcf9c2c8 100644 --- a/sys/arch/i386/i386/svr4_machdep.c +++ b/sys/arch/i386/i386/svr4_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: svr4_machdep.c,v 1.9 1997/01/27 22:48:00 deraadt Exp $ */ +/* $OpenBSD: svr4_machdep.c,v 1.10 1997/02/01 21:53:26 deraadt Exp $ */ /* $NetBSD: svr4_machdep.c,v 1.24 1996/05/03 19:42:26 christos Exp $ */ /* @@ -56,7 +56,7 @@ #include #include -static void svr4_getsiginfo __P((union svr4_siginfo *, int, u_long, caddr_t)); +static void svr4_getsiginfo __P((union svr4_siginfo *, int, u_long, int, caddr_t)); void svr4_getcontext(p, uc, mask, oonstack) @@ -212,10 +212,11 @@ svr4_setcontext(p, uc) static void -svr4_getsiginfo(si, sig, code, addr) +svr4_getsiginfo(si, sig, code, type, addr) union svr4_siginfo *si; int sig; u_long code; + int type; caddr_t addr; { si->svr4_si_signo = bsd_to_svr4_sig[sig]; @@ -315,11 +316,12 @@ svr4_getsiginfo(si, sig, code, addr) * will return to the user pc, psl. */ void -svr4_sendsig(catcher, sig, mask, code, addr) +svr4_sendsig(catcher, sig, mask, code, type, val) sig_t catcher; int sig, mask; u_long code; - caddr_t addr; + int type; + union sigval val; { register struct proc *p = curproc; register struct trapframe *tf; @@ -354,7 +356,7 @@ svr4_sendsig(catcher, sig, mask, code, addr) */ svr4_getcontext(p, &frame.sf_uc, mask, oonstack); - svr4_getsiginfo(&frame.sf_si, sig, code, addr); + svr4_getsiginfo(&frame.sf_si, sig, code, type, val.sival_ptr); frame.sf_signum = frame.sf_si.svr4_si_signo; frame.sf_sip = &fp->sf_si; diff --git a/sys/arch/i386/i386/trap.c b/sys/arch/i386/i386/trap.c index 2d90e9b7911..1d52f0da160 100644 --- a/sys/arch/i386/i386/trap.c +++ b/sys/arch/i386/i386/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.14 1997/01/27 22:48:01 deraadt Exp $ */ +/* $OpenBSD: trap.c,v 1.15 1997/02/01 21:53:29 deraadt Exp $ */ /* $NetBSD: trap.c,v 1.95 1996/05/05 06:50:02 mycroft Exp $ */ #undef DEBUG @@ -281,17 +281,23 @@ trap(frame) } #endif case T_SEGNPFLT|T_USER: + trapsignal(p, SIGSEGV, type &~ T_USER, SEGV_MAPERR, (caddr_t)rcr2()); + goto out; + case T_STKFLT|T_USER: - trapsignal(p, SIGSEGV, type &~ T_USER, (caddr_t)rcr2()); + trapsignal(p, SIGSEGV, type &~ T_USER, ILL_BADSTK, (caddr_t)rcr2()); goto out; case T_ALIGNFLT|T_USER: - trapsignal(p, SIGBUS, type &~ T_USER, (caddr_t)rcr2()); + trapsignal(p, SIGBUS, type &~ T_USER, BUS_ADRALN, (caddr_t)rcr2()); goto out; case T_PRIVINFLT|T_USER: /* privileged instruction fault */ + trapsignal(p, SIGILL, type &~ T_USER, ILL_PRVOPC, (caddr_t)rcr2()); + goto out; + case T_FPOPFLT|T_USER: /* coprocessor operand fault */ - trapsignal(p, SIGILL, type &~ T_USER, (caddr_t)rcr2()); + trapsignal(p, SIGILL, type &~ T_USER, FPE_FLTINV, (caddr_t)rcr2()); goto out; case T_ASTFLT|T_USER: /* Allow process switch */ @@ -310,24 +316,28 @@ trap(frame) goto trace; return; } - trapsignal(p, rv, type &~ T_USER, (caddr_t)rcr2()); + trapsignal(p, rv, type &~ T_USER, FPE_FLTINV, (caddr_t)rcr2()); goto out; #else printf("pid %d killed due to lack of floating point\n", p->p_pid); - trapsignal(p, SIGKILL, type &~ T_USER, (caddr_t)rcr2()); + trapsignal(p, SIGKILL, type &~ T_USER, FPE_FLTINV, (caddr_t)rcr2()); goto out; #endif } case T_BOUND|T_USER: + trapsignal(p, SIGFPE, type &~ T_USER, FPE_FLTSUB, (caddr_t)rcr2()); + goto out; case T_OFLOW|T_USER: + trapsignal(p, SIGFPE, type &~ T_USER, FPE_FLTOVF, (caddr_t)rcr2()); + goto out; case T_DIVIDE|T_USER: - trapsignal(p, SIGFPE, type &~ T_USER, (caddr_t)rcr2()); + trapsignal(p, SIGFPE, type &~ T_USER, FPE_FLTDIV, (caddr_t)rcr2()); goto out; case T_ARITHTRAP|T_USER: - trapsignal(p, SIGFPE, frame.tf_err, (caddr_t)rcr2()); + trapsignal(p, SIGFPE, frame.tf_err, FPE_INTOVF, (caddr_t)rcr2()); goto out; case T_PAGEFLT: /* allow page faults in kernel mode */ @@ -427,7 +437,7 @@ trap(frame) map, va, ftype, rv); goto we_re_toast; } - trapsignal(p, SIGSEGV, T_PAGEFLT, vv); + trapsignal(p, SIGSEGV, T_PAGEFLT, SEGV_ACCERR, vv); break; } @@ -439,11 +449,13 @@ trap(frame) #endif case T_BPTFLT|T_USER: /* bpt instruction fault */ + trapsignal(p, SIGTRAP, type &~ T_USER, TRAP_BRKPT, (caddr_t)rcr2()); + break; case T_TRCTRAP|T_USER: /* trace trap */ #if defined(MATH_EMULATE) || defined(GPL_MATH_EMULATE) trace: #endif - trapsignal(p, SIGTRAP, type &~ T_USER, (caddr_t)rcr2()); + trapsignal(p, SIGTRAP, type &~ T_USER, TRAP_TRACE, (caddr_t)rcr2()); break; #include "isa.h" diff --git a/sys/arch/i386/i386/vm86.c b/sys/arch/i386/i386/vm86.c index ba61d16555b..8fd4467e48c 100644 --- a/sys/arch/i386/i386/vm86.c +++ b/sys/arch/i386/i386/vm86.c @@ -253,7 +253,7 @@ vm86_return(p, retval) sigexit(p, SIGILL); /* NOTREACHED */ } - trapsignal(p, SIGURG, retval, 0); + trapsignal(p, SIGURG, retval, 0, 0); } #define CLI 0xFA @@ -369,7 +369,7 @@ vm86_gpfault(p, type) } if (trace && tf->tf_eflags & PSL_VM) - trapsignal(p, SIGTRAP, T_TRCTRAP, 0); + trapsignal(p, SIGTRAP, T_TRCTRAP, TRAP_TRACE, 0); return; bad: diff --git a/sys/arch/i386/include/freebsd_machdep.h b/sys/arch/i386/include/freebsd_machdep.h index 7ee92189afd..e9fd2cf977e 100644 --- a/sys/arch/i386/include/freebsd_machdep.h +++ b/sys/arch/i386/include/freebsd_machdep.h @@ -157,6 +157,6 @@ struct freebsd_ptrace_reg { /* sys/i386/include/exec.h */ #define FREEBSD___LDPGSZ 4096 -void freebsd_sendsig __P((sig_t, int, int, u_long, caddr_t)); +void freebsd_sendsig __P((sig_t, int, int, u_long, int, union sigval)); #endif /* _FREEBSD_MACHDEP_H */ diff --git a/sys/arch/i386/include/linux_machdep.h b/sys/arch/i386/include/linux_machdep.h index c5a09d1cc93..453593beee6 100644 --- a/sys/arch/i386/include/linux_machdep.h +++ b/sys/arch/i386/include/linux_machdep.h @@ -76,7 +76,7 @@ struct linux_sigframe { sig_t sf_handler; }; -void linux_sendsig __P((sig_t, int, int, u_long, caddr_t)); +void linux_sendsig __P((sig_t, int, int, u_long, int, union sigval)); dev_t linux_fakedev __P((dev_t)); /* diff --git a/sys/arch/i386/include/svr4_machdep.h b/sys/arch/i386/include/svr4_machdep.h index fd39dd6c121..13bbdb27419 100644 --- a/sys/arch/i386/include/svr4_machdep.h +++ b/sys/arch/i386/include/svr4_machdep.h @@ -71,7 +71,7 @@ struct svr4_ucontext; void svr4_getcontext __P((struct proc *, struct svr4_ucontext *, int, int)); int svr4_setcontext __P((struct proc *p, struct svr4_ucontext *)); -void svr4_sendsig __P((sig_t, int, int, u_long, caddr_t)); +void svr4_sendsig __P((sig_t, int, int, u_long, int, union sigval)); typedef struct { svr4_gregset_t greg; diff --git a/sys/arch/i386/isa/npx.c b/sys/arch/i386/isa/npx.c index 6774126fd5b..683332aeb9a 100644 --- a/sys/arch/i386/isa/npx.c +++ b/sys/arch/i386/isa/npx.c @@ -448,7 +448,7 @@ npxintr(arg) #else code = 0; /* XXX */ #endif - trapsignal(p, SIGFPE, code, 0); + trapsignal(p, SIGFPE, code, 0, 0); /* XXX type? */ } else { /* * Nested interrupt. These losers occur when: diff --git a/sys/compat/ibcs2/ibcs2_exec.c b/sys/compat/ibcs2/ibcs2_exec.c index f7c394017ba..e874647ef14 100644 --- a/sys/compat/ibcs2/ibcs2_exec.c +++ b/sys/compat/ibcs2/ibcs2_exec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ibcs2_exec.c,v 1.6 1997/01/27 22:48:30 deraadt Exp $ */ +/* $OpenBSD: ibcs2_exec.c,v 1.7 1997/02/01 21:49:48 deraadt Exp $ */ /* $NetBSD: ibcs2_exec.c,v 1.12 1996/10/12 02:13:52 thorpej Exp $ */ /* @@ -77,7 +77,7 @@ static int coff_find_section __P((struct proc *, struct vnode *, extern int bsd2ibcs_errno[]; extern struct sysent ibcs2_sysent[]; extern char *ibcs2_syscallnames[]; -extern void ibcs2_sendsig __P((sig_t, int, int, u_long, caddr_t)); +extern void ibcs2_sendsig __P((sig_t, int, int, u_long, int, union sigval)); extern char sigcode[], esigcode[]; const char ibcs2_emul_path[] = "/emul/ibcs2"; diff --git a/sys/compat/sunos/sunos.h b/sys/compat/sunos/sunos.h index 65ef0e58073..6513c044cb6 100644 --- a/sys/compat/sunos/sunos.h +++ b/sys/compat/sunos/sunos.h @@ -1,4 +1,4 @@ -/* $OpenBSD: sunos.h,v 1.5 1997/01/27 22:48:33 deraadt Exp $ */ +/* $OpenBSD: sunos.h,v 1.6 1997/02/01 21:49:53 deraadt Exp $ */ /* $NetBSD: sunos.h,v 1.8 1996/05/05 16:07:43 veego Exp $ */ #define SUNM_RDONLY 0x01 /* mount fs read-only */ @@ -146,6 +146,6 @@ struct sunos_audio_info { __BEGIN_DECLS /* Defined in arch/m68k/m68k/sunos_machdep.c -- sparc uses regular sendsig() */ #ifndef sparc -void sunos_sendsig __P((sig_t, int, int, u_long, caddr_t)); +void sunos_sendsig __P((sig_t, int, int, u_long, int, union sigval)); #endif __END_DECLS diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c index e8f19c40b25..4aa5bd87f1d 100644 --- a/sys/kern/kern_sig.c +++ b/sys/kern/kern_sig.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_sig.c,v 1.15 1997/01/27 22:48:36 deraadt Exp $ */ +/* $OpenBSD: kern_sig.c,v 1.16 1997/02/01 21:49:41 deraadt Exp $ */ /* $NetBSD: kern_sig.c,v 1.54 1996/04/22 01:38:32 christos Exp $ */ /* @@ -519,11 +519,12 @@ pgsignal(pgrp, signum, checkctty) * Otherwise, post it normally. */ void -trapsignal(p, signum, code, addr) +trapsignal(p, signum, code, type, sigval) struct proc *p; register int signum; u_long code; - caddr_t addr; + int type; + union sigval sigval; { register struct sigacts *ps = p->p_sigacts; int mask; @@ -538,7 +539,7 @@ trapsignal(p, signum, code, addr) p->p_sigmask, code); #endif (*p->p_emul->e_sendsig)(ps->ps_sigact[signum], signum, - p->p_sigmask, code, addr); + p->p_sigmask, code, type, sigval); p->p_sigmask |= ps->ps_catchmask[signum]; if ((ps->ps_sigreset & mask) != 0) { p->p_sigcatch &= ~mask; @@ -1003,7 +1004,8 @@ postsig(signum) code = ps->ps_code; ps->ps_code = 0; } - (*p->p_emul->e_sendsig)(action, signum, returnmask, code, 0); + (*p->p_emul->e_sendsig)(action, signum, returnmask, code, + SI_USER, (union sigval *)0); } } @@ -1180,11 +1182,30 @@ sys_nosys(p, v, retval) } void -initsiginfo(si, sig) +initsiginfo(si, sig, code, type, val) siginfo_t *si; int sig; + u_long code; + int type; + union sigval val; { bzero(si, sizeof *si); + si->si_signo = sig; - si->si_addr = (caddr_t)-1; + si->si_code = type; + if (type == SI_USER) { + si->si_value = val; + } else { + switch (sig) { + case SIGSEGV: + case SIGILL: + case SIGBUS: + case SIGFPE: + si->si_addr = val.sival_ptr; + si->si_trapno = code; + break; + case SIGXFSZ: + break; + } + } } diff --git a/sys/sys/proc.h b/sys/sys/proc.h index 6d83564a554..0685ae7c9b8 100644 --- a/sys/sys/proc.h +++ b/sys/sys/proc.h @@ -1,4 +1,4 @@ -/* $OpenBSD: proc.h,v 1.12 1997/01/27 22:48:41 deraadt Exp $ */ +/* $OpenBSD: proc.h,v 1.13 1997/02/01 21:49:30 deraadt Exp $ */ /* $NetBSD: proc.h,v 1.44 1996/04/22 01:23:21 christos Exp $ */ /*- @@ -75,12 +75,13 @@ struct pgrp { */ struct exec_package; struct ps_strings; +union sigval; struct emul { char e_name[8]; /* Symbolic name */ int *e_errno; /* Errno array */ /* Signal sending function */ - void (*e_sendsig) __P((sig_t, int, int, u_long, caddr_t)); + void (*e_sendsig) __P((sig_t, int, int, u_long, int, union sigval)); int e_nosys; /* Offset of the nosys() syscall */ int e_nsysent; /* Number of system call entries */ struct sysent *e_sysent; /* System call array */ diff --git a/sys/sys/siginfo.h b/sys/sys/siginfo.h index 0cae60ceaa3..e333812ffab 100644 --- a/sys/sys/siginfo.h +++ b/sys/sys/siginfo.h @@ -1,4 +1,4 @@ -/* $OpenBSD: siginfo.h,v 1.3 1997/01/27 23:21:22 deraadt Exp $ */ +/* $OpenBSD: siginfo.h,v 1.4 1997/02/01 21:49:34 deraadt Exp $ */ /* * Copyright (c) 1997 Theo de Raadt @@ -205,8 +205,7 @@ typedef struct { #define si_mstate _data._prof._mstate #if defined(_KERNEL) -void initsiginfo __P((siginfo_t *, int)); -void fixsiginfo __P((siginfo_t *, int, u_long, caddr_t)); +void initsiginfo __P((siginfo_t *, int, u_long, int, union sigval)); #endif #endif /* _SYS_SIGINFO_H */ diff --git a/sys/sys/signalvar.h b/sys/sys/signalvar.h index e3282f9ae56..bf84942038a 100644 --- a/sys/sys/signalvar.h +++ b/sys/sys/signalvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: signalvar.h,v 1.5 1997/01/27 22:48:42 deraadt Exp $ */ +/* $OpenBSD: signalvar.h,v 1.6 1997/02/01 21:49:36 deraadt Exp $ */ /* $NetBSD: signalvar.h,v 1.17 1996/04/22 01:23:31 christos Exp $ */ /* @@ -161,7 +161,8 @@ void pgsignal __P((struct pgrp *pgrp, int sig, int checkctty)); void postsig __P((int sig)); void psignal __P((struct proc *p, int sig)); void siginit __P((struct proc *p)); -void trapsignal __P((struct proc *p, int sig, u_long code, caddr_t addr)); +void trapsignal __P((struct proc *p, int sig, u_long code, int type, + union sigval val)); void sigexit __P((struct proc *, int)); void setsigvec __P((struct proc *, int, struct sigaction *)); int killpg1 __P((struct proc *, int, int, int)); @@ -170,7 +171,7 @@ int killpg1 __P((struct proc *, int, int, int)); * Machine-dependent functions: */ void sendsig __P((sig_t action, int sig, int returnmask, u_long code, - caddr_t addr)); + int type, union sigval val)); struct core; struct vnode; struct ucred; -- 2.20.1