Module Name:    src
Committed By:   thorpej
Date:           Mon Nov  1 05:07:17 UTC 2021

Modified Files:
        src/sys/arch/aarch64/aarch64: netbsd32_machdep.c sig_machdep.c
        src/sys/arch/amd64/amd64: netbsd32_machdep.c
        src/sys/arch/powerpc/powerpc: sig_machdep.c
        src/sys/arch/sh3/sh3: sh3_machdep.c
        src/sys/arch/vax/vax: sig_machdep.c
        src/sys/compat/common: compat_sigaltstack.h kern_sig_43.c
        src/sys/compat/linux/arch/aarch64: linux_machdep.c
        src/sys/compat/linux/arch/i386: linux_machdep.c
        src/sys/compat/linux/common: linux_signal.c linux_signal.h
        src/sys/compat/linux32/arch/amd64: linux32_machdep.c
        src/sys/compat/linux32/common: linux32_signal.c linux32_signal.h
        src/sys/compat/netbsd32: netbsd32_compat_43.c
        src/sys/compat/sys: signalvar.h
        src/sys/kern: sys_sig.c syscalls.master
        src/sys/sys: signalvar.h

Log Message:
Use "stack_t" instead of "struct sigaltstack", as the former is the
newer standardized name.  NFC.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/aarch64/aarch64/netbsd32_machdep.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/aarch64/aarch64/sig_machdep.c
cvs rdiff -u -r1.138 -r1.139 src/sys/arch/amd64/amd64/netbsd32_machdep.c
cvs rdiff -u -r1.53 -r1.54 src/sys/arch/powerpc/powerpc/sig_machdep.c
cvs rdiff -u -r1.110 -r1.111 src/sys/arch/sh3/sh3/sh3_machdep.c
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/vax/vax/sig_machdep.c
cvs rdiff -u -r1.3 -r1.4 src/sys/compat/common/compat_sigaltstack.h
cvs rdiff -u -r1.37 -r1.38 src/sys/compat/common/kern_sig_43.c
cvs rdiff -u -r1.2 -r1.3 src/sys/compat/linux/arch/aarch64/linux_machdep.c
cvs rdiff -u -r1.168 -r1.169 src/sys/compat/linux/arch/i386/linux_machdep.c
cvs rdiff -u -r1.87 -r1.88 src/sys/compat/linux/common/linux_signal.c
cvs rdiff -u -r1.33 -r1.34 src/sys/compat/linux/common/linux_signal.h
cvs rdiff -u -r1.46 -r1.47 \
    src/sys/compat/linux32/arch/amd64/linux32_machdep.c
cvs rdiff -u -r1.22 -r1.23 src/sys/compat/linux32/common/linux32_signal.c
cvs rdiff -u -r1.3 -r1.4 src/sys/compat/linux32/common/linux32_signal.h
cvs rdiff -u -r1.62 -r1.63 src/sys/compat/netbsd32/netbsd32_compat_43.c
cvs rdiff -u -r1.2 -r1.3 src/sys/compat/sys/signalvar.h
cvs rdiff -u -r1.53 -r1.54 src/sys/kern/sys_sig.c
cvs rdiff -u -r1.308 -r1.309 src/sys/kern/syscalls.master
cvs rdiff -u -r1.103 -r1.104 src/sys/sys/signalvar.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/aarch64/aarch64/netbsd32_machdep.c
diff -u src/sys/arch/aarch64/aarch64/netbsd32_machdep.c:1.20 src/sys/arch/aarch64/aarch64/netbsd32_machdep.c:1.21
--- src/sys/arch/aarch64/aarch64/netbsd32_machdep.c:1.20	Wed Oct 27 04:14:59 2021
+++ src/sys/arch/aarch64/aarch64/netbsd32_machdep.c	Mon Nov  1 05:07:15 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: netbsd32_machdep.c,v 1.20 2021/10/27 04:14:59 thorpej Exp $	*/
+/*	$NetBSD: netbsd32_machdep.c,v 1.21 2021/11/01 05:07:15 thorpej Exp $	*/
 
 /*
  * Copyright (c) 2018 Ryo Shimizu <r...@nerv.org>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_machdep.c,v 1.20 2021/10/27 04:14:59 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_machdep.c,v 1.21 2021/11/01 05:07:15 thorpej Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -306,7 +306,7 @@ netbsd32_sendsig_siginfo(const ksiginfo_
 	struct lwp * const l = curlwp;
 	struct proc * const p = l->l_proc;
 	struct trapframe * const tf = lwp_trapframe(l);
-	struct sigaltstack * const ss = &l->l_sigstk;
+	stack_t * const ss = &l->l_sigstk;
 	const int signo = ksi->ksi_signo;
 	const struct sigaction * const sa = &SIGACTION(p, signo);
 	const struct sigact_sigdesc * const sdesc =

Index: src/sys/arch/aarch64/aarch64/sig_machdep.c
diff -u src/sys/arch/aarch64/aarch64/sig_machdep.c:1.7 src/sys/arch/aarch64/aarch64/sig_machdep.c:1.8
--- src/sys/arch/aarch64/aarch64/sig_machdep.c:1.7	Wed Oct 27 04:14:59 2021
+++ src/sys/arch/aarch64/aarch64/sig_machdep.c	Mon Nov  1 05:07:15 2021
@@ -1,4 +1,4 @@
-/* $NetBSD: sig_machdep.c,v 1.7 2021/10/27 04:14:59 thorpej Exp $ */
+/* $NetBSD: sig_machdep.c,v 1.8 2021/11/01 05:07:15 thorpej Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
 
 #include <sys/cdefs.h>
 
-__KERNEL_RCSID(1, "$NetBSD: sig_machdep.c,v 1.7 2021/10/27 04:14:59 thorpej Exp $");
+__KERNEL_RCSID(1, "$NetBSD: sig_machdep.c,v 1.8 2021/11/01 05:07:15 thorpej Exp $");
 
 #include <sys/param.h>
 #include <sys/types.h>
@@ -48,7 +48,7 @@ sendsig_siginfo(const ksiginfo_t *ksi, c
 	struct lwp * const l = curlwp;
 	struct proc * const p = l->l_proc;
 	struct trapframe * const tf = lwp_trapframe(l);
-	struct sigaltstack * const ss = &l->l_sigstk;
+	stack_t * const ss = &l->l_sigstk;
 	const struct sigact_sigdesc * const sd =
 	    &p->p_sigacts->sa_sigdesc[ksi->ksi_signo];
 

Index: src/sys/arch/amd64/amd64/netbsd32_machdep.c
diff -u src/sys/arch/amd64/amd64/netbsd32_machdep.c:1.138 src/sys/arch/amd64/amd64/netbsd32_machdep.c:1.139
--- src/sys/arch/amd64/amd64/netbsd32_machdep.c:1.138	Wed Oct 27 04:14:59 2021
+++ src/sys/arch/amd64/amd64/netbsd32_machdep.c	Mon Nov  1 05:07:15 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: netbsd32_machdep.c,v 1.138 2021/10/27 04:14:59 thorpej Exp $	*/
+/*	$NetBSD: netbsd32_machdep.c,v 1.139 2021/11/01 05:07:15 thorpej Exp $	*/
 
 /*
  * Copyright (c) 2001 Wasabi Systems, Inc.
@@ -36,7 +36,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_machdep.c,v 1.138 2021/10/27 04:14:59 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_machdep.c,v 1.139 2021/11/01 05:07:15 thorpej Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_compat_netbsd.h"
@@ -218,7 +218,7 @@ netbsd32_sendsig_siginfo(const ksiginfo_
 	const struct sigaction *sa = &SIGACTION(p, sig);
 	sig_t catcher = sa->sa_handler;
 	struct trapframe *tf = l->l_md.md_regs;
-	struct sigaltstack * const ss = &l->l_sigstk;
+	stack_t * const ss = &l->l_sigstk;
 
 	/* Do we need to jump onto the signal stack? */
 	onstack =

Index: src/sys/arch/powerpc/powerpc/sig_machdep.c
diff -u src/sys/arch/powerpc/powerpc/sig_machdep.c:1.53 src/sys/arch/powerpc/powerpc/sig_machdep.c:1.54
--- src/sys/arch/powerpc/powerpc/sig_machdep.c:1.53	Wed Oct 27 04:15:00 2021
+++ src/sys/arch/powerpc/powerpc/sig_machdep.c	Mon Nov  1 05:07:15 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: sig_machdep.c,v 1.53 2021/10/27 04:15:00 thorpej Exp $	*/
+/*	$NetBSD: sig_machdep.c,v 1.54 2021/11/01 05:07:15 thorpej Exp $	*/
 
 /*
  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sig_machdep.c,v 1.53 2021/10/27 04:15:00 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sig_machdep.c,v 1.54 2021/11/01 05:07:15 thorpej Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_altivec.h"
@@ -63,7 +63,7 @@ sendsig_siginfo(const ksiginfo_t *ksi, c
 	struct lwp * const l = curlwp;
 	struct proc * const p = l->l_proc;
 	struct trapframe * const tf = l->l_md.md_utf;
-	struct sigaltstack * const ss = &l->l_sigstk;
+	stack_t * const ss = &l->l_sigstk;
 	const struct sigact_sigdesc * const sd =
 	    &p->p_sigacts->sa_sigdesc[ksi->ksi_signo];
 	/* save handler before sendsig_reset trashes it! */

Index: src/sys/arch/sh3/sh3/sh3_machdep.c
diff -u src/sys/arch/sh3/sh3/sh3_machdep.c:1.110 src/sys/arch/sh3/sh3/sh3_machdep.c:1.111
--- src/sys/arch/sh3/sh3/sh3_machdep.c:1.110	Thu Jun 11 19:20:45 2020
+++ src/sys/arch/sh3/sh3/sh3_machdep.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: sh3_machdep.c,v 1.110 2020/06/11 19:20:45 ad Exp $	*/
+/*	$NetBSD: sh3_machdep.c,v 1.111 2021/11/01 05:07:16 thorpej Exp $	*/
 
 /*-
  * Copyright (c) 1996, 1997, 1998, 2002 The NetBSD Foundation, Inc.
@@ -65,7 +65,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sh3_machdep.c,v 1.110 2020/06/11 19:20:45 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sh3_machdep.c,v 1.111 2021/11/01 05:07:16 thorpej Exp $");
 
 #include "opt_ddb.h"
 #include "opt_kgdb.h"
@@ -334,7 +334,7 @@ void *
 getframe(const struct lwp *l, int sig, int *onstack)
 {
 	const struct proc *p = l->l_proc;
-	const struct sigaltstack *sigstk= &l->l_sigstk;
+	const stack_t *sigstk = &l->l_sigstk;
 
 	/* Do we need to jump onto the signal stack? */
 	*onstack = (sigstk->ss_flags & (SS_DISABLE | SS_ONSTACK)) == 0

Index: src/sys/arch/vax/vax/sig_machdep.c
diff -u src/sys/arch/vax/vax/sig_machdep.c:1.25 src/sys/arch/vax/vax/sig_machdep.c:1.26
--- src/sys/arch/vax/vax/sig_machdep.c:1.25	Wed Oct 27 04:15:00 2021
+++ src/sys/arch/vax/vax/sig_machdep.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/* $NetBSD: sig_machdep.c,v 1.25 2021/10/27 04:15:00 thorpej Exp $	 */
+/* $NetBSD: sig_machdep.c,v 1.26 2021/11/01 05:07:16 thorpej Exp $	 */
 
 /*
  * Copyright (c) 1982, 1986, 1990 The Regents of the University of California.
@@ -79,7 +79,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sig_machdep.c,v 1.25 2021/10/27 04:15:00 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sig_machdep.c,v 1.26 2021/11/01 05:07:16 thorpej Exp $");
 
 #include "opt_ddb.h"
 #include "opt_compat_netbsd.h"
@@ -195,7 +195,7 @@ sendsig_sighelper(const ksiginfo_t *ksi,
 	struct lwp * const l = curlwp;
 	struct proc * const p = l->l_proc;
 	struct trapframe * const tf = l->l_md.md_utf;
-	struct sigaltstack * const ss = &l->l_sigstk;
+	stack_t * const ss = &l->l_sigstk;
 	const struct sigact_sigdesc * const sd =
 	    &p->p_sigacts->sa_sigdesc[ksi->ksi_signo];
 	vaddr_t sp;

Index: src/sys/compat/common/compat_sigaltstack.h
diff -u src/sys/compat/common/compat_sigaltstack.h:1.3 src/sys/compat/common/compat_sigaltstack.h:1.4
--- src/sys/compat/common/compat_sigaltstack.h:1.3	Sun Jun  5 09:37:10 2011
+++ src/sys/compat/common/compat_sigaltstack.h	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*      $NetBSD: compat_sigaltstack.h,v 1.3 2011/06/05 09:37:10 dsl Exp $        */
+/*      $NetBSD: compat_sigaltstack.h,v 1.4 2021/11/01 05:07:16 thorpej Exp $        */
 
 /* Wrapper for calling sigaltstack1() from compat (or other) code */
 
@@ -17,7 +17,7 @@
 
 #define compat_sigaltstack(uap, compat_ss, ss_onstack, ss_disable) do { \
 	struct compat_ss css; \
-	struct sigaltstack nss, oss; \
+	stack_t nss, oss; \
 	int error; \
 \
 	if (SCARG_COMPAT_PTR(uap, nss)) { \

Index: src/sys/compat/common/kern_sig_43.c
diff -u src/sys/compat/common/kern_sig_43.c:1.37 src/sys/compat/common/kern_sig_43.c:1.38
--- src/sys/compat/common/kern_sig_43.c:1.37	Tue Sep  7 11:43:02 2021
+++ src/sys/compat/common/kern_sig_43.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: kern_sig_43.c,v 1.37 2021/09/07 11:43:02 riastradh Exp $	*/
+/*	$NetBSD: kern_sig_43.c,v 1.38 2021/11/01 05:07:16 thorpej Exp $	*/
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_sig_43.c,v 1.37 2021/09/07 11:43:02 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_sig_43.c,v 1.38 2021/11/01 05:07:16 thorpej Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -70,8 +70,8 @@ void compat_43_sigmask_to_sigset(const i
 void compat_43_sigset_to_sigmask(const sigset_t *, int *);
 void compat_43_sigvec_to_sigaction(const struct sigvec *, struct sigaction *);
 void compat_43_sigaction_to_sigvec(const struct sigaction *, struct sigvec *);
-void compat_43_sigstack_to_sigaltstack(const struct sigstack *, struct sigaltstack *);
-void compat_43_sigaltstack_to_sigstack(const struct sigaltstack *, struct sigstack *);
+void compat_43_sigstack_to_sigaltstack(const struct sigstack *, stack_t *);
+void compat_43_sigaltstack_to_sigstack(const stack_t *, struct sigstack *);
 
 static struct syscall_package kern_sig_43_syscalls[] = {
 	{ SYS_compat_43_osigblock, 0, (sy_call_t *)compat_43_sys_sigblock },
@@ -121,7 +121,7 @@ compat_43_sigaction_to_sigvec(const stru
 }
 
 void
-compat_43_sigstack_to_sigaltstack(const struct sigstack *ss, struct sigaltstack *sa)
+compat_43_sigstack_to_sigaltstack(const struct sigstack *ss, stack_t *sa)
 {
 	memset(sa, 0, sizeof(*sa));
 	sa->ss_sp = ss->ss_sp;
@@ -132,7 +132,7 @@ compat_43_sigstack_to_sigaltstack(const 
 }
 
 void
-compat_43_sigaltstack_to_sigstack(const struct sigaltstack *sa, struct sigstack *ss)
+compat_43_sigaltstack_to_sigstack(const stack_t *sa, struct sigstack *ss)
 {
 	memset(ss, 0, sizeof(*ss));
 	ss->ss_sp = sa->ss_sp;
@@ -197,7 +197,7 @@ compat_43_sys_sigstack(struct lwp *l, co
 		syscallarg(struct sigstack *) oss;
 	} */
 	struct sigstack nss, oss;
-	struct sigaltstack nsa, osa;
+	stack_t nsa, osa;
 	int error;
 
 	if (SCARG(uap, nss)) {

Index: src/sys/compat/linux/arch/aarch64/linux_machdep.c
diff -u src/sys/compat/linux/arch/aarch64/linux_machdep.c:1.2 src/sys/compat/linux/arch/aarch64/linux_machdep.c:1.3
--- src/sys/compat/linux/arch/aarch64/linux_machdep.c:1.2	Sat Oct  9 07:01:34 2021
+++ src/sys/compat/linux/arch/aarch64/linux_machdep.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux_machdep.c,v 1.2 2021/10/09 07:01:34 ryo Exp $	*/
+/*	$NetBSD: linux_machdep.c,v 1.3 2021/11/01 05:07:16 thorpej Exp $	*/
 
 /*-
  * Copyright (c) 2021 Ryo Shimizu <r...@nerv.org>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.2 2021/10/09 07:01:34 ryo Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.3 2021/11/01 05:07:16 thorpej Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -133,7 +133,7 @@ linux_sendsig(const ksiginfo_t *ksi, con
 	struct lwp * const l = curlwp;
 	struct proc * const p = l->l_proc;
 	struct trapframe * const tf = lwp_trapframe(l);
-	struct sigaltstack * const ss = &l->l_sigstk;
+	stack_t * const ss = &l->l_sigstk;
 	const int sig = ksi->ksi_signo;
 	const sig_t handler = SIGACTION(p, sig).sa_handler;
 	struct linux_rt_sigframe *u_sigframe, *tmp_sigframe;

Index: src/sys/compat/linux/arch/i386/linux_machdep.c
diff -u src/sys/compat/linux/arch/i386/linux_machdep.c:1.168 src/sys/compat/linux/arch/i386/linux_machdep.c:1.169
--- src/sys/compat/linux/arch/i386/linux_machdep.c:1.168	Tue Sep  7 11:43:04 2021
+++ src/sys/compat/linux/arch/i386/linux_machdep.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux_machdep.c,v 1.168 2021/09/07 11:43:04 riastradh Exp $	*/
+/*	$NetBSD: linux_machdep.c,v 1.169 2021/11/01 05:07:16 thorpej Exp $	*/
 
 /*-
  * Copyright (c) 1995, 2000, 2008, 2009 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.168 2021/09/07 11:43:04 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.169 2021/11/01 05:07:16 thorpej Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_user_ldt.h"
@@ -109,7 +109,7 @@ extern struct disklist *x86_alldisks;
 
 static struct biosdisk_info *fd2biosinfo(struct proc *, struct file *);
 static void linux_save_ucontext(struct lwp *, struct trapframe *,
-    const sigset_t *, struct sigaltstack *, struct linux_ucontext *);
+    const sigset_t *, stack_t *, struct linux_ucontext *);
 static void linux_save_sigcontext(struct lwp *, struct trapframe *,
     const sigset_t *, struct linux_sigcontext *);
 static int linux_restore_sigcontext(struct lwp *,
@@ -175,7 +175,8 @@ linux_sendsig(const ksiginfo_t *ksi, con
 
 
 static void
-linux_save_ucontext(struct lwp *l, struct trapframe *tf, const sigset_t *mask, struct sigaltstack *sas, struct linux_ucontext *uc)
+linux_save_ucontext(struct lwp *l, struct trapframe *tf, const sigset_t *mask,
+    stack_t *sas, struct linux_ucontext *uc)
 {
 	uc->uc_flags = 0;
 	uc->uc_link = NULL;
@@ -232,7 +233,7 @@ linux_rt_sendsig(const ksiginfo_t *ksi, 
 	int onstack, error;
 	int sig = ksi->ksi_signo;
 	sig_t catcher = SIGACTION(p, sig).sa_handler;
-	struct sigaltstack *sas = &l->l_sigstk;
+	stack_t *sas = &l->l_sigstk;
 
 	tf = l->l_md.md_regs;
 	/* Do we need to jump onto the signal stack? */
@@ -311,7 +312,7 @@ linux_old_sendsig(const ksiginfo_t *ksi,
 	int onstack, error;
 	int sig = ksi->ksi_signo;
 	sig_t catcher = SIGACTION(p, sig).sa_handler;
-	struct sigaltstack *sas = &l->l_sigstk;
+	stack_t *sas = &l->l_sigstk;
 
 	tf = l->l_md.md_regs;
 
@@ -425,7 +426,7 @@ linux_restore_sigcontext(struct lwp *l, 
     register_t *retval)
 {
 	struct proc *p = l->l_proc;
-	struct sigaltstack *sas = &l->l_sigstk;
+	stack_t *sas = &l->l_sigstk;
 	struct trapframe *tf;
 	sigset_t mask;
 	ssize_t ss_gap;

Index: src/sys/compat/linux/common/linux_signal.c
diff -u src/sys/compat/linux/common/linux_signal.c:1.87 src/sys/compat/linux/common/linux_signal.c:1.88
--- src/sys/compat/linux/common/linux_signal.c:1.87	Wed Oct 27 16:40:05 2021
+++ src/sys/compat/linux/common/linux_signal.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux_signal.c,v 1.87 2021/10/27 16:40:05 thorpej Exp $	*/
+/*	$NetBSD: linux_signal.c,v 1.88 2021/11/01 05:07:16 thorpej Exp $	*/
 
 /*-
  * Copyright (c) 1995, 1998 The NetBSD Foundation, Inc.
@@ -48,7 +48,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_signal.c,v 1.87 2021/10/27 16:40:05 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_signal.c,v 1.88 2021/11/01 05:07:16 thorpej Exp $");
 
 #define COMPAT_LINUX 1
 
@@ -678,11 +678,11 @@ linux_sys_kill(struct lwp *l, const stru
 }
 
 #ifdef LINUX_SS_ONSTACK
-static void linux_to_native_sigaltstack(struct sigaltstack *,
+static void linux_to_native_sigaltstack(stack_t *,
     const struct linux_sigaltstack *);
 
 static void
-linux_to_native_sigaltstack(struct sigaltstack *bss, const struct linux_sigaltstack *lss)
+linux_to_native_sigaltstack(stack_t *bss, const struct linux_sigaltstack *lss)
 {
 	bss->ss_sp = lss->ss_sp;
 	bss->ss_size = lss->ss_size;
@@ -695,7 +695,7 @@ linux_to_native_sigaltstack(struct sigal
 }
 
 void
-native_to_linux_sigaltstack(struct linux_sigaltstack *lss, const struct sigaltstack *bss)
+native_to_linux_sigaltstack(struct linux_sigaltstack *lss, const stack_t *bss)
 {
 	memset(lss, 0, sizeof(*lss));
 	lss->ss_sp = bss->ss_sp;
@@ -716,7 +716,7 @@ linux_sys_sigaltstack(struct lwp *l, con
 		syscallarg(struct linux_sigaltstack *) oss;
 	} */
 	struct linux_sigaltstack ss;
-	struct sigaltstack nss;
+	stack_t nss;
 	struct proc *p = l->l_proc;
 	int error = 0;
 

Index: src/sys/compat/linux/common/linux_signal.h
diff -u src/sys/compat/linux/common/linux_signal.h:1.33 src/sys/compat/linux/common/linux_signal.h:1.34
--- src/sys/compat/linux/common/linux_signal.h:1.33	Thu Sep 23 06:56:27 2021
+++ src/sys/compat/linux/common/linux_signal.h	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/* 	$NetBSD: linux_signal.h,v 1.33 2021/09/23 06:56:27 ryo Exp $	*/
+/* 	$NetBSD: linux_signal.h,v 1.34 2021/11/01 05:07:16 thorpej Exp $	*/
 
 /*-
  * Copyright (c) 1995, 1998 The NetBSD Foundation, Inc.
@@ -102,8 +102,7 @@ void linux_to_native_sigaction(struct si
 void native_to_linux_sigaction(struct linux_sigaction *,
     const struct sigaction *);
 
-void native_to_linux_sigaltstack(struct linux_sigaltstack *,
-    const struct sigaltstack *);
+void native_to_linux_sigaltstack(struct linux_sigaltstack *, const stack_t *);
 
 int native_to_linux_si_code(int);
 int native_to_linux_si_status(int, int);

Index: src/sys/compat/linux32/arch/amd64/linux32_machdep.c
diff -u src/sys/compat/linux32/arch/amd64/linux32_machdep.c:1.46 src/sys/compat/linux32/arch/amd64/linux32_machdep.c:1.47
--- src/sys/compat/linux32/arch/amd64/linux32_machdep.c:1.46	Tue Sep  7 11:43:04 2021
+++ src/sys/compat/linux32/arch/amd64/linux32_machdep.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux32_machdep.c,v 1.46 2021/09/07 11:43:04 riastradh Exp $ */
+/*	$NetBSD: linux32_machdep.c,v 1.47 2021/11/01 05:07:16 thorpej Exp $ */
 
 /*-
  * Copyright (c) 2006 Emmanuel Dreyfus, all rights reserved.
@@ -31,7 +31,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux32_machdep.c,v 1.46 2021/09/07 11:43:04 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux32_machdep.c,v 1.47 2021/11/01 05:07:16 thorpej Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_user_ldt.h"
@@ -79,7 +79,7 @@ extern char linux32_rt_sigcode[];
 extern char linux32_esigcode[];
 
 static void linux32_save_ucontext(struct lwp *, struct trapframe *,
-    const sigset_t *, struct sigaltstack *, struct linux32_ucontext *);
+    const sigset_t *, stack_t *, struct linux32_ucontext *);
 static void linux32_save_sigcontext(struct lwp *, struct trapframe *,
     const sigset_t *, struct linux32_sigcontext *);
 static void linux32_rt_sendsig(const ksiginfo_t *, const sigset_t *);
@@ -107,7 +107,7 @@ linux32_old_sendsig(const ksiginfo_t *ks
 	int onstack, error;
 	int sig = ksi->ksi_signo;
 	sig_t catcher = SIGACTION(p, sig).sa_handler;
-	struct sigaltstack *sas = &l->l_sigstk;
+	stack_t *sas = &l->l_sigstk;
 
 	tf = l->l_md.md_regs;
 	/* Do we need to jump onto the signal stack? */
@@ -178,7 +178,7 @@ linux32_rt_sendsig(const ksiginfo_t *ksi
 	linux32_siginfo_t *lsi;
 	int sig = ksi->ksi_signo;
 	sig_t catcher = SIGACTION(p, sig).sa_handler;
-	struct sigaltstack *sas = &l->l_sigstk;
+	stack_t *sas = &l->l_sigstk;
 
 	tf = l->l_md.md_regs;
 	/* Do we need to jump onto the signal stack? */
@@ -325,7 +325,7 @@ linux32_setregs(struct lwp *l, struct ex
 
 static void
 linux32_save_ucontext(struct lwp *l, struct trapframe *tf,
-    const sigset_t *mask, struct sigaltstack *sas, struct linux32_ucontext *uc)
+    const sigset_t *mask, stack_t *sas, struct linux32_ucontext *uc)
 {
 
 	uc->uc_flags = 0;
@@ -410,7 +410,7 @@ linux32_restore_sigcontext(struct lwp *l
 {	
 	struct trapframe *tf;
 	struct proc *p = l->l_proc;
-	struct sigaltstack *sas = &l->l_sigstk;
+	stack_t *sas = &l->l_sigstk;
 	struct pcb *pcb;
 	sigset_t mask;
 	ssize_t ss_gap;

Index: src/sys/compat/linux32/common/linux32_signal.c
diff -u src/sys/compat/linux32/common/linux32_signal.c:1.22 src/sys/compat/linux32/common/linux32_signal.c:1.23
--- src/sys/compat/linux32/common/linux32_signal.c:1.22	Sun Sep 19 22:30:28 2021
+++ src/sys/compat/linux32/common/linux32_signal.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux32_signal.c,v 1.22 2021/09/19 22:30:28 thorpej Exp $ */
+/*	$NetBSD: linux32_signal.c,v 1.23 2021/11/01 05:07:16 thorpej Exp $ */
 
 /*-
  * Copyright (c) 2006 Emmanuel Dreyfus, all rights reserved.
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux32_signal.c,v 1.22 2021/09/19 22:30:28 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux32_signal.c,v 1.23 2021/11/01 05:07:16 thorpej Exp $");
 
 #include <sys/param.h>
 #include <sys/ucred.h>
@@ -234,7 +234,8 @@ native_to_linux32_sigaction(struct linux
 }
 
 void
-native_to_linux32_sigaltstack(struct linux32_sigaltstack *lss, const struct sigaltstack *bss)
+native_to_linux32_sigaltstack(struct linux32_sigaltstack *lss,
+    const stack_t *bss)
 {
 	memset(lss, 0, sizeof(*lss));
 	NETBSD32PTR32(lss->ss_sp, bss->ss_sp);

Index: src/sys/compat/linux32/common/linux32_signal.h
diff -u src/sys/compat/linux32/common/linux32_signal.h:1.3 src/sys/compat/linux32/common/linux32_signal.h:1.4
--- src/sys/compat/linux32/common/linux32_signal.h:1.3	Fri Nov 18 04:08:56 2011
+++ src/sys/compat/linux32/common/linux32_signal.h	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/* $NetBSD: linux32_signal.h,v 1.3 2011/11/18 04:08:56 christos Exp $ */
+/* $NetBSD: linux32_signal.h,v 1.4 2021/11/01 05:07:16 thorpej Exp $ */
 
 /*-
  * Copyright (c) 2006 Emmanuel Dreyfus, all rights reserved.
@@ -47,7 +47,7 @@ void linux32_to_native_sigaction(struct 
 void native_to_linux32_sigaction(struct linux32_sigaction *, 
 	const struct sigaction *);
 void native_to_linux32_sigaltstack(struct linux32_sigaltstack *,
-    const struct sigaltstack *);
+    const stack_t *);
 void native_to_linux32_old_sigset(linux32_old_sigset_t *, const sigset_t *);
 void linux32_old_extra_to_native_sigset(sigset_t *,
     const linux32_old_sigset_t *, const unsigned long *);

Index: src/sys/compat/netbsd32/netbsd32_compat_43.c
diff -u src/sys/compat/netbsd32/netbsd32_compat_43.c:1.62 src/sys/compat/netbsd32/netbsd32_compat_43.c:1.63
--- src/sys/compat/netbsd32/netbsd32_compat_43.c:1.62	Tue Sep  7 11:43:05 2021
+++ src/sys/compat/netbsd32/netbsd32_compat_43.c	Mon Nov  1 05:07:16 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: netbsd32_compat_43.c,v 1.62 2021/09/07 11:43:05 riastradh Exp $	*/
+/*	$NetBSD: netbsd32_compat_43.c,v 1.63 2021/11/01 05:07:16 thorpej Exp $	*/
 
 /*
  * Copyright (c) 1998, 2001 Matthew R. Green
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_43.c,v 1.62 2021/09/07 11:43:05 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_43.c,v 1.63 2021/11/01 05:07:16 thorpej Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_43.h"
@@ -688,7 +688,7 @@ compat_43_netbsd32_osigstack(struct lwp 
 		syscallarg(netbsd32_sigstackp_t) oss;
 	} */
 	struct netbsd32_sigstack ss32;
-	struct sigaltstack nsa, osa;
+	stack_t nsa, osa;
 	int error;
 
 	if (SCARG_P32(uap, nss)) {

Index: src/sys/compat/sys/signalvar.h
diff -u src/sys/compat/sys/signalvar.h:1.2 src/sys/compat/sys/signalvar.h:1.3
--- src/sys/compat/sys/signalvar.h:1.2	Sun Dec 11 12:20:29 2005
+++ src/sys/compat/sys/signalvar.h	Mon Nov  1 05:07:17 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: signalvar.h,v 1.2 2005/12/11 12:20:29 christos Exp $	*/
+/*	$NetBSD: signalvar.h,v 1.3 2021/11/01 05:07:17 thorpej Exp $	*/
 
 /*
  * Copyright (c) 1991, 1993
@@ -45,8 +45,8 @@ void	native_sigaction13_to_sigaction(con
 void	native_sigaction_to_sigaction13(const struct sigaction *,
 	    struct sigaction13 *);
 void	native_sigaltstack13_to_sigaltstack(const struct sigaltstack13 *,
-	    struct sigaltstack *);
-void	native_sigaltstack_to_sigaltstack13(const struct sigaltstack *,
+	    stack_t *);
+void	native_sigaltstack_to_sigaltstack13(const stack_t *,
 	    struct sigaltstack13 *);
 #endif	/* _KERNEL */
 

Index: src/sys/kern/sys_sig.c
diff -u src/sys/kern/sys_sig.c:1.53 src/sys/kern/sys_sig.c:1.54
--- src/sys/kern/sys_sig.c:1.53	Wed Oct 27 04:45:42 2021
+++ src/sys/kern/sys_sig.c	Mon Nov  1 05:07:17 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: sys_sig.c,v 1.53 2021/10/27 04:45:42 thorpej Exp $	*/
+/*	$NetBSD: sys_sig.c,v 1.54 2021/11/01 05:07:17 thorpej Exp $	*/
 
 /*-
  * Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -66,7 +66,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sys_sig.c,v 1.53 2021/10/27 04:45:42 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sys_sig.c,v 1.54 2021/11/01 05:07:17 thorpej Exp $");
 
 #include "opt_dtrace.h"
 
@@ -200,8 +200,8 @@ sys___sigaltstack14(struct lwp *l, const
 		syscallarg(const struct sigaltstack *)	nss;
 		syscallarg(struct sigaltstack *)	oss;
 	} */
-	struct sigaltstack	nss, oss;
-	int			error;
+	stack_t	nss, oss;
+	int	error;
 
 	if (SCARG(uap, nss)) {
 		error = copyin(SCARG(uap, nss), &nss, sizeof(nss));
@@ -691,8 +691,7 @@ sigsuspend1(struct lwp *l, const sigset_
 }
 
 int
-sigaltstack1(struct lwp *l, const struct sigaltstack *nss,
-    struct sigaltstack *oss)
+sigaltstack1(struct lwp *l, const stack_t *nss, stack_t *oss)
 {
 	struct proc *p = l->l_proc;
 	int error = 0;

Index: src/sys/kern/syscalls.master
diff -u src/sys/kern/syscalls.master:1.308 src/sys/kern/syscalls.master:1.309
--- src/sys/kern/syscalls.master:1.308	Sun Sep 19 15:51:27 2021
+++ src/sys/kern/syscalls.master	Mon Nov  1 05:07:17 2021
@@ -1,4 +1,4 @@
-	$NetBSD: syscalls.master,v 1.308 2021/09/19 15:51:27 thorpej Exp $
+	$NetBSD: syscalls.master,v 1.309 2021/11/01 05:07:17 thorpej Exp $
 
 ;	@(#)syscalls.master	8.2 (Berkeley) 1/13/94
 
@@ -591,9 +591,8 @@
 		{ int|sys|13|fstat(int fd, struct stat13 *sb); }
 280	COMPAT_30 MODULAR compat_30	\
 		{ int|sys|13|lstat(const char *path, struct stat13 *ub); }
-281	STD		{ int|sys|14|sigaltstack( \
-			    const struct sigaltstack *nss, \
-			    struct sigaltstack *oss); }
+281	STD		{ int|sys|14|sigaltstack(const stack_t *nss, \
+			    stack_t *oss); }
 282	STD		{ int|sys|14|vfork(void); }
 283	STD	RUMP	{ int|sys||__posix_chown(const char *path, uid_t uid, \
 			    gid_t gid); }

Index: src/sys/sys/signalvar.h
diff -u src/sys/sys/signalvar.h:1.103 src/sys/sys/signalvar.h:1.104
--- src/sys/sys/signalvar.h:1.103	Sun Nov  1 18:51:03 2020
+++ src/sys/sys/signalvar.h	Mon Nov  1 05:07:17 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: signalvar.h,v 1.103 2020/11/01 18:51:03 pgoyette Exp $	*/
+/*	$NetBSD: signalvar.h,v 1.104 2021/11/01 05:07:17 thorpej Exp $	*/
 
 /*
  * Copyright (c) 1991, 1993
@@ -165,8 +165,7 @@ void	sigpending1(struct lwp *, sigset_t 
 void	sigsuspendsetup(struct lwp *, const sigset_t *);
 void	sigsuspendteardown(struct lwp *);
 int	sigsuspend1(struct lwp *, const sigset_t *);
-int	sigaltstack1(struct lwp *, const struct sigaltstack *,
-	    struct sigaltstack *);
+int	sigaltstack1(struct lwp *, const stack_t *, stack_t *);
 int	sigismasked(struct lwp *, int);
 
 int	sigget(sigpend_t *, ksiginfo_t *, int, const sigset_t *);

Reply via email to