diff options
author | Philip Guenther <guenther@cvs.openbsd.org> | 2021-12-07 22:17:04 +0000 |
---|---|---|
committer | Philip Guenther <guenther@cvs.openbsd.org> | 2021-12-07 22:17:04 +0000 |
commit | d480c9d545b584076d280205cc39f690b979be45 (patch) | |
tree | 436b8f6a5aecfc20be39aabdcce0492fceaf7642 /sys/kern/kern_sig.c | |
parent | 384a2c088bee39ff5ced282af8dc4078919311dd (diff) |
Delete the last emulation callbacks: we're Just ELF, so declare
exec_elf_fixup() and coredump_elf() in <sys/exec_elf.h> and call
them and the MD setregs() directly in kern_exec.c and kern_sig.c
Also delete e_name[] (only used by sysctl), e_errno (unused), and
e_syscallnames[] (only used by SYSCALL_DEBUG) and constipate
syscallnames to 'const char *const[]'
ok kettenis@
Diffstat (limited to 'sys/kern/kern_sig.c')
-rw-r--r-- | sys/kern/kern_sig.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c index 204011407f1..27bb231b99a 100644 --- a/sys/kern/kern_sig.c +++ b/sys/kern/kern_sig.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_sig.c,v 1.290 2021/11/24 10:40:15 claudio Exp $ */ +/* $OpenBSD: kern_sig.c,v 1.291 2021/12/07 22:17:02 guenther Exp $ */ /* $NetBSD: kern_sig.c,v 1.54 1996/04/22 01:38:32 christos Exp $ */ /* @@ -64,6 +64,7 @@ #include <sys/ttycom.h> #include <sys/pledge.h> #include <sys/witness.h> +#include <sys/exec_elf.h> #include <sys/mount.h> #include <sys/syscallargs.h> @@ -1578,9 +1579,6 @@ coredump(struct proc *p) char *name; const char *dir = "/var/crash"; - if (pr->ps_emul->e_coredump == NULL) - return (EINVAL); - atomic_setbits_int(&pr->ps_flags, PS_COREDUMP); /* Don't dump if will exceed file size limit. */ @@ -1681,7 +1679,7 @@ coredump(struct proc *p) vref(vp); error = vn_close(vp, FWRITE, cred, p); if (error == 0) - error = (*pr->ps_emul->e_coredump)(p, &io); + error = coredump_elf(p, &io); vrele(vp); out: crfree(cred); |