CVS commit: src/tests/lib/libcurses

2022-04-21 Thread Brett Lymn
Module Name:src
Committed By:   blymn
Date:   Thu Apr 21 07:03:44 UTC 2022

Modified Files:
src/tests/lib/libcurses: t_curses.sh
src/tests/lib/libcurses/tests: bkgrndset

Log Message:
Actually add the bkgrndset test case so it runs plus fix a typo in
the bkgrndset test script.


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/tests/lib/libcurses/t_curses.sh
cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libcurses/tests/bkgrndset

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

Modified files:

Index: src/tests/lib/libcurses/t_curses.sh
diff -u src/tests/lib/libcurses/t_curses.sh:1.29 src/tests/lib/libcurses/t_curses.sh:1.30
--- src/tests/lib/libcurses/t_curses.sh:1.29	Wed Apr 20 07:43:05 2022
+++ src/tests/lib/libcurses/t_curses.sh	Thu Apr 21 07:03:44 2022
@@ -2410,6 +2410,7 @@ atf_init_test_cases()
 	# curses background attribute manipulation routines
 	atf_add_test_case background
 	atf_add_test_case bkgdset
+	atf_add_test_case bkgrndset
 	atf_add_test_case getbkgd
 
 	# curses border drawing routines

Index: src/tests/lib/libcurses/tests/bkgrndset
diff -u src/tests/lib/libcurses/tests/bkgrndset:1.1 src/tests/lib/libcurses/tests/bkgrndset:1.2
--- src/tests/lib/libcurses/tests/bkgrndset:1.1	Wed Apr 20 07:43:05 2022
+++ src/tests/lib/libcurses/tests/bkgrndset	Thu Apr 21 07:03:44 2022
@@ -7,4 +7,4 @@ call OK refresh
 compare bkgrndset1.chk
 call OK erase
 call OK refresh
-compare bgkrndset2.chk
+compare bkgrndset2.chk



CVS commit: src/tests/lib/libcurses

2022-04-21 Thread Brett Lymn
Module Name:src
Committed By:   blymn
Date:   Thu Apr 21 07:03:44 UTC 2022

Modified Files:
src/tests/lib/libcurses: t_curses.sh
src/tests/lib/libcurses/tests: bkgrndset

Log Message:
Actually add the bkgrndset test case so it runs plus fix a typo in
the bkgrndset test script.


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/tests/lib/libcurses/t_curses.sh
cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libcurses/tests/bkgrndset

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



CVS commit: src/sys/kern

2022-04-21 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Apr 21 12:05:13 UTC 2022

Modified Files:
src/sys/kern: sys_futex.c

Log Message:
futex(9): Convert membar_enter/exit to membar_acquire/release.

No functional change -- this is just in an illustrative comment!


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/kern/sys_futex.c

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



CVS commit: src/sys/kern

2022-04-21 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Apr 21 12:05:13 UTC 2022

Modified Files:
src/sys/kern: sys_futex.c

Log Message:
futex(9): Convert membar_enter/exit to membar_acquire/release.

No functional change -- this is just in an illustrative comment!


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/kern/sys_futex.c

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

Modified files:

Index: src/sys/kern/sys_futex.c
diff -u src/sys/kern/sys_futex.c:1.17 src/sys/kern/sys_futex.c:1.18
--- src/sys/kern/sys_futex.c:1.17	Sat Apr  9 23:38:33 2022
+++ src/sys/kern/sys_futex.c	Thu Apr 21 12:05:13 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: sys_futex.c,v 1.17 2022/04/09 23:38:33 riastradh Exp $	*/
+/*	$NetBSD: sys_futex.c,v 1.18 2022/04/21 12:05:13 riastradh Exp $	*/
 
 /*-
  * Copyright (c) 2018, 2019, 2020 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: sys_futex.c,v 1.17 2022/04/09 23:38:33 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sys_futex.c,v 1.18 2022/04/21 12:05:13 riastradh Exp $");
 
 /*
  * Futexes
@@ -63,13 +63,13 @@ __KERNEL_RCSID(0, "$NetBSD: sys_futex.c,
  *continue;
  *			}
  *		} while (atomic_cas_uint(&lock, v, v & ~1) != v);
- *		membar_enter();
+ *		membar_acquire();
  *
  *		...
  *
  *		// Release the lock.  Optimistically assume there are
  *		// no waiters first until demonstrated otherwise.
- *		membar_exit();
+ *		membar_release();
  *		if (atomic_cas_uint(&lock, 1, 0) != 1) {
  *			// There may be waiters.
  *			v = atomic_swap_uint(&lock, 0);



CVS commit: src

2022-04-21 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Apr 21 12:06:32 UTC 2022

Modified Files:
src/common/lib/libc/arch/mips/atomic: membar_ops.S
src/sys/arch/mips/include: asm.h

Log Message:
mips/cavium: Take advantage of Octeon's guaranteed r/rw ordering.


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/common/lib/libc/arch/mips/atomic/membar_ops.S
cvs rdiff -u -r1.70 -r1.71 src/sys/arch/mips/include/asm.h

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



CVS commit: src

2022-04-21 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Thu Apr 21 12:06:32 UTC 2022

Modified Files:
src/common/lib/libc/arch/mips/atomic: membar_ops.S
src/sys/arch/mips/include: asm.h

Log Message:
mips/cavium: Take advantage of Octeon's guaranteed r/rw ordering.


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/common/lib/libc/arch/mips/atomic/membar_ops.S
cvs rdiff -u -r1.70 -r1.71 src/sys/arch/mips/include/asm.h

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

Modified files:

Index: src/common/lib/libc/arch/mips/atomic/membar_ops.S
diff -u src/common/lib/libc/arch/mips/atomic/membar_ops.S:1.12 src/common/lib/libc/arch/mips/atomic/membar_ops.S:1.13
--- src/common/lib/libc/arch/mips/atomic/membar_ops.S:1.12	Sat Apr  9 23:32:51 2022
+++ src/common/lib/libc/arch/mips/atomic/membar_ops.S	Thu Apr 21 12:06:31 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: membar_ops.S,v 1.12 2022/04/09 23:32:51 riastradh Exp $	*/
+/*	$NetBSD: membar_ops.S,v 1.13 2022/04/21 12:06:31 riastradh Exp $	*/
 
 /*-
  * Copyright (c) 2006, 2007 The NetBSD Foundation, Inc.
@@ -38,44 +38,80 @@ LEAF(_membar_sync)
 	j	ra
 	 BDSYNC
 END(_membar_sync)
+ATOMIC_OP_ALIAS(membar_sync,_membar_sync)
+
+STRONG_ALIAS(_membar_enter,_membar_sync)
+ATOMIC_OP_ALIAS(membar_enter,_membar_sync)
 
 #ifdef __OCTEON__
+
+/*
+ * cnMIPS guarantees load-before-load/store ordering without any
+ * barriers.  So the only barriers we need are store-before-load (sync)
+ * and store-before-store (syncw, i.e., sync 4).  See Table 2-32
+ * `Execution Ordering Rules' on p. 104 of Cavium OCTEON III CN78XX
+ * Hardware Reference Manual, CN78XX-HM-0.99E, September 2014:
+ *
+ *	First Operation		DLD [load instruction to a physical
+ *address that is L2/DRAM]
+ *	Second Operation	Any
+ *	Execution Ordering Comments
+ *
+ *		The second operation cannot appear to execute before
+ *		the first (DLD) operation, regardless of the presence
+ *		or absence of SYNC* instructions.
+ *
+ * Note: I'm not sure if this applies to earlier cnMIPS -- can't find
+ * it in the Cavium Networks OCTEON Plus CN50XX Hardware Reference
+ * Manual CN50XX-HM-0.99E, July 2008.  Experimentally, on an erlite3
+ * (Cavium Octeon CN5020-500), I can easily detect reordering of
+ * store-before-store and store-before-load, but I haven't been able to
+ * detect any reordering of load-before-load or load-before-store.
+ *
+ * Note: On early cnMIPS (CN3xxx), there is an erratum which sometimes
+ * requires issuing two syncw's in a row.  I don't know the details --
+ * don't have documentation -- and in Linux it is only used for I/O
+ * purposes.
+ *
+ * Currently we don't build kernels that work on both Octeon and
+ * non-Octeon MIPS CPUs, so none of this is done with binary patching.
+ * For userlands we could use a separate shared library on Octeon with
+ * ld.so.conf to override the symbols with cheaper definitions, but we
+ * don't do that now.
+ */
+
+LEAF(_membar_acquire)
+	j	ra
+	 nop
+END(_membar_acquire)
+ATOMIC_OP_ALIAS(membar_acquire,_membar_acquire)
+
+STRONG_ALIAS(_membar_consumer,_membar_acquire)
+ATOMIC_OP_ALIAS(membar_consumer,_membar_acquire)
+
 LEAF(_membar_release)
-	/*
-	 * syncw is documented as ordering store-before-store in
-	 *
-	 *	Cavium OCTEON III CN78XX Hardware Reference Manual,
-	 *	CN78XX-HM-0.99E, September 2014.
-	 *
-	 * It's unclear from the documentation the architecture
-	 * guarantees load-before-store ordering without barriers, but
-	 * this code assumes it does.  If that assumption is wrong, we
-	 * can only use syncw for membar_producer -- membar_release has
-	 * to use the full sync.
-	 */
 	j	ra
 	 syncw
 END(_membar_release)
-#endif
+ATOMIC_OP_ALIAS(membar_release,_membar_release)
 
-ATOMIC_OP_ALIAS(membar_sync,_membar_sync)
-ATOMIC_OP_ALIAS(membar_acquire,_membar_sync)
-STRONG_ALIAS(_membar_acquire,_membar_sync)
-ATOMIC_OP_ALIAS(membar_enter,_membar_sync)
-STRONG_ALIAS(_membar_enter,_membar_sync)
-#ifdef __OCTEON__
-ATOMIC_OP_ALIAS(membar_exit,_membar_release)
 STRONG_ALIAS(_membar_exit,_membar_release)
-ATOMIC_OP_ALIAS(membar_release,_membar_release)
-ATOMIC_OP_ALIAS(membar_producer,_membar_release)
+ATOMIC_OP_ALIAS(membar_exit,_membar_release)
+
 STRONG_ALIAS(_membar_producer,_membar_release)
-#else
-ATOMIC_OP_ALIAS(membar_exit,_membar_sync)
-STRONG_ALIAS(_membar_exit,_membar_sync)
-ATOMIC_OP_ALIAS(membar_release,_membar_sync)
+ATOMIC_OP_ALIAS(membar_producer,_membar_release)
+
+#else  /* !__OCTEON__ */
+
+STRONG_ALIAS(_membar_acquire,_membar_sync)
+ATOMIC_OP_ALIAS(membar_acquire,_membar_sync)
 STRONG_ALIAS(_membar_release,_membar_sync)
-ATOMIC_OP_ALIAS(membar_producer,_membar_sync)
+ATOMIC_OP_ALIAS(membar_release,_membar_sync)
+STRONG_ALIAS(_membar_exit,_membar_sync)
+ATOMIC_OP_ALIAS(membar_exit,_membar_sync)
+STRONG_ALIAS(_membar_consumer,_membar_sync)
+ATOMIC_OP_ALIAS(membar_consumer,_membar_sync)
 STRONG_ALIAS(_membar_producer,_membar_sync)
+ATOMIC_OP_ALIAS(membar_

CVS commit: src/usr.sbin/sysinst

2022-04-21 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Apr 21 17:30:15 UTC 2022

Modified Files:
src/usr.sbin/sysinst: configmenu.c defs.h install.c msg.entropy.de
msg.entropy.en msg.entropy.es msg.entropy.fr msg.entropy.pl
msg.mi.de msg.mi.en msg.mi.es msg.mi.fr msg.mi.pl run.c upgrade.c
util.c

Log Message:
Make default installations a bit more secure:
 - push a bit harder for setup of a root password
 - simplify/clarify manual entropy setup
 - visit the entropy setup (on machines where it is needed) on the
   default path through sysinst


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/usr.sbin/sysinst/configmenu.c \
src/usr.sbin/sysinst/run.c
cvs rdiff -u -r1.80 -r1.81 src/usr.sbin/sysinst/defs.h
cvs rdiff -u -r1.22 -r1.23 src/usr.sbin/sysinst/install.c
cvs rdiff -u -r1.4 -r1.5 src/usr.sbin/sysinst/msg.entropy.de \
src/usr.sbin/sysinst/msg.entropy.es src/usr.sbin/sysinst/msg.entropy.fr \
src/usr.sbin/sysinst/msg.entropy.pl
cvs rdiff -u -r1.3 -r1.4 src/usr.sbin/sysinst/msg.entropy.en
cvs rdiff -u -r1.35 -r1.36 src/usr.sbin/sysinst/msg.mi.de
cvs rdiff -u -r1.37 -r1.38 src/usr.sbin/sysinst/msg.mi.en \
src/usr.sbin/sysinst/msg.mi.pl
cvs rdiff -u -r1.31 -r1.32 src/usr.sbin/sysinst/msg.mi.es
cvs rdiff -u -r1.36 -r1.37 src/usr.sbin/sysinst/msg.mi.fr
cvs rdiff -u -r1.19 -r1.20 src/usr.sbin/sysinst/upgrade.c
cvs rdiff -u -r1.65 -r1.66 src/usr.sbin/sysinst/util.c

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

Modified files:

Index: src/usr.sbin/sysinst/configmenu.c
diff -u src/usr.sbin/sysinst/configmenu.c:1.14 src/usr.sbin/sysinst/configmenu.c:1.15
--- src/usr.sbin/sysinst/configmenu.c:1.14	Sat Oct  9 09:06:28 2021
+++ src/usr.sbin/sysinst/configmenu.c	Thu Apr 21 17:30:15 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: configmenu.c,v 1.14 2021/10/09 09:06:28 martin Exp $ */
+/* $NetBSD: configmenu.c,v 1.15 2022/04/21 17:30:15 martin Exp $ */
 
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -291,6 +291,14 @@ add_new_user(struct menudesc *menu, void
 	return 0;
 }
 
+void
+root_pw_setup(void)
+{
+	msg_display(MSG_force_rootpw);
+	run_program(RUN_DISPLAY | RUN_PROGRESS | RUN_CHROOT | RUN_STDSCR,
+	"passwd -l root");
+}
+
 static int
 change_root_password(struct menudesc *menu, void *arg)
 {
Index: src/usr.sbin/sysinst/run.c
diff -u src/usr.sbin/sysinst/run.c:1.14 src/usr.sbin/sysinst/run.c:1.15
--- src/usr.sbin/sysinst/run.c:1.14	Tue Aug  3 13:34:04 2021
+++ src/usr.sbin/sysinst/run.c	Thu Apr 21 17:30:15 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: run.c,v 1.14 2021/08/03 13:34:04 martin Exp $	*/
+/*	$NetBSD: run.c,v 1.15 2022/04/21 17:30:15 martin Exp $	*/
 
 /*
  * Copyright 1997 Piermont Information Systems Inc.
@@ -655,14 +655,19 @@ run_program(int flags, const char *cmd, 
 		win.ws_col = 80;
 
 	if ((flags & RUN_DISPLAY) != 0) {
-		if (flags & RUN_FULLSCREEN) {
+		if (flags & RUN_STDSCR) {
+			actionwin = stdscr;
+			wmove(stdscr, msg_row()+2, 0);
+			wrefresh(stdscr);
+		} else if (flags & RUN_FULLSCREEN) {
 			wclear(stdscr);
 			clearok(stdscr, 1);
 			touchwin(stdscr);
 			refresh();
 			actionwin = stdscr;
-		} else
+		} else {
 			actionwin = show_cmd(scmd, &win);
+		}
 	} else
 		win.ws_row -= 4;
 

Index: src/usr.sbin/sysinst/defs.h
diff -u src/usr.sbin/sysinst/defs.h:1.80 src/usr.sbin/sysinst/defs.h:1.81
--- src/usr.sbin/sysinst/defs.h:1.80	Thu Feb 10 16:11:41 2022
+++ src/usr.sbin/sysinst/defs.h	Thu Apr 21 17:30:15 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: defs.h,v 1.80 2022/02/10 16:11:41 martin Exp $	*/
+/*	$NetBSD: defs.h,v 1.81 2022/04/21 17:30:15 martin Exp $	*/
 
 /*
  * Copyright 1997 Piermont Information Systems Inc.
@@ -108,6 +108,7 @@ const char *getfslabelname(uint, uint);
 #define RUN_PROGRESS	0x0080		/* Output is just progess test */
 #define RUN_NO_CLEAR	0x0100		/* Leave program output after error */
 #define RUN_XFER_DIR	0x0200		/* cd to xfer_dir in child */
+#define	RUN_STDSCR	0x0400		/* run program in standard screen */
 
 /* for bsddisklabel.c */
 enum layout_type {
@@ -1004,6 +1005,7 @@ void	save_kb_encoding(void);
 
 /* from configmenu.c */
 void	do_configmenu(struct install_partition_desc*);
+void	root_pw_setup(void);
 
 /* from checkrc.c */
 int	check_rcvar(const char *);

Index: src/usr.sbin/sysinst/install.c
diff -u src/usr.sbin/sysinst/install.c:1.22 src/usr.sbin/sysinst/install.c:1.23
--- src/usr.sbin/sysinst/install.c:1.22	Sat Jan 29 16:01:16 2022
+++ src/usr.sbin/sysinst/install.c	Thu Apr 21 17:30:15 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: install.c,v 1.22 2022/01/29 16:01:16 martin Exp $	*/
+/*	$NetBSD: install.c,v 1.23 2022/04/21 17:30:15 martin Exp $	*/
 
 /*
  * Copyright 1997 Piermont Information Systems Inc.
@@ -233,6 +233,10 @@ do_install(void)
 	if (md_post_extract(&install, false) != 0)
 		goto error;
 
+	root_pw_setup();
+#if CHECK_ENTROPY
+	do_add_entropy();
+#endif
 	do_configmenu(&install);
 
 	sanity_check();

Index: src/usr.sbin

CVS commit: src/usr.sbin/sysinst

2022-04-21 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Apr 21 17:30:15 UTC 2022

Modified Files:
src/usr.sbin/sysinst: configmenu.c defs.h install.c msg.entropy.de
msg.entropy.en msg.entropy.es msg.entropy.fr msg.entropy.pl
msg.mi.de msg.mi.en msg.mi.es msg.mi.fr msg.mi.pl run.c upgrade.c
util.c

Log Message:
Make default installations a bit more secure:
 - push a bit harder for setup of a root password
 - simplify/clarify manual entropy setup
 - visit the entropy setup (on machines where it is needed) on the
   default path through sysinst


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/usr.sbin/sysinst/configmenu.c \
src/usr.sbin/sysinst/run.c
cvs rdiff -u -r1.80 -r1.81 src/usr.sbin/sysinst/defs.h
cvs rdiff -u -r1.22 -r1.23 src/usr.sbin/sysinst/install.c
cvs rdiff -u -r1.4 -r1.5 src/usr.sbin/sysinst/msg.entropy.de \
src/usr.sbin/sysinst/msg.entropy.es src/usr.sbin/sysinst/msg.entropy.fr \
src/usr.sbin/sysinst/msg.entropy.pl
cvs rdiff -u -r1.3 -r1.4 src/usr.sbin/sysinst/msg.entropy.en
cvs rdiff -u -r1.35 -r1.36 src/usr.sbin/sysinst/msg.mi.de
cvs rdiff -u -r1.37 -r1.38 src/usr.sbin/sysinst/msg.mi.en \
src/usr.sbin/sysinst/msg.mi.pl
cvs rdiff -u -r1.31 -r1.32 src/usr.sbin/sysinst/msg.mi.es
cvs rdiff -u -r1.36 -r1.37 src/usr.sbin/sysinst/msg.mi.fr
cvs rdiff -u -r1.19 -r1.20 src/usr.sbin/sysinst/upgrade.c
cvs rdiff -u -r1.65 -r1.66 src/usr.sbin/sysinst/util.c

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



CVS commit: src/crypto/dist/ipsec-tools/src/racoon

2022-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Thu Apr 21 19:14:46 UTC 2022

Modified Files:
src/crypto/dist/ipsec-tools/src/racoon: gnuc.h

Log Message:
ipsec-tools: in lint mode, keep keyword 'inline'

This avoids hundreds of lint warnings for OpenSSL's stack definitions:

openssl/x509.h(75): warning:
static function sk_X509_NAME_ENTRY_num unused [236]


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/crypto/dist/ipsec-tools/src/racoon/gnuc.h

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

Modified files:

Index: src/crypto/dist/ipsec-tools/src/racoon/gnuc.h
diff -u src/crypto/dist/ipsec-tools/src/racoon/gnuc.h:1.4 src/crypto/dist/ipsec-tools/src/racoon/gnuc.h:1.5
--- src/crypto/dist/ipsec-tools/src/racoon/gnuc.h:1.4	Sat Sep  9 16:22:09 2006
+++ src/crypto/dist/ipsec-tools/src/racoon/gnuc.h	Thu Apr 21 19:14:46 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: gnuc.h,v 1.4 2006/09/09 16:22:09 manu Exp $	*/
+/*	$NetBSD: gnuc.h,v 1.5 2022/04/21 19:14:46 rillig Exp $	*/
 
 /* Id: gnuc.h,v 1.4 2004/11/18 15:14:44 ludvigm Exp */
 
@@ -13,7 +13,7 @@
 #endif
 
 /* inline foo */
-#ifdef __GNUC__
+#if defined(__GNUC__) || defined(lint)
 #define inline __inline
 #else
 #define inline



CVS commit: src/crypto/dist/ipsec-tools/src/racoon

2022-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Thu Apr 21 19:14:46 UTC 2022

Modified Files:
src/crypto/dist/ipsec-tools/src/racoon: gnuc.h

Log Message:
ipsec-tools: in lint mode, keep keyword 'inline'

This avoids hundreds of lint warnings for OpenSSL's stack definitions:

openssl/x509.h(75): warning:
static function sk_X509_NAME_ENTRY_num unused [236]


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/crypto/dist/ipsec-tools/src/racoon/gnuc.h

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



CVS commit: src/tests/usr.bin/xlint/lint1

2022-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Thu Apr 21 19:48:18 UTC 2022

Modified Files:
src/tests/usr.bin/xlint/lint1: msg_132.c msg_132.exp

Log Message:
tests/lint: extend test for lossy integer conversion


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/tests/usr.bin/xlint/lint1/msg_132.c
cvs rdiff -u -r1.7 -r1.8 src/tests/usr.bin/xlint/lint1/msg_132.exp

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

Modified files:

Index: src/tests/usr.bin/xlint/lint1/msg_132.c
diff -u src/tests/usr.bin/xlint/lint1/msg_132.c:1.8 src/tests/usr.bin/xlint/lint1/msg_132.c:1.9
--- src/tests/usr.bin/xlint/lint1/msg_132.c:1.8	Wed Apr 20 22:50:56 2022
+++ src/tests/usr.bin/xlint/lint1/msg_132.c	Thu Apr 21 19:48:18 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: msg_132.c,v 1.8 2022/04/20 22:50:56 rillig Exp $	*/
+/*	$NetBSD: msg_132.c,v 1.9 2022/04/21 19:48:18 rillig Exp $	*/
 # 3 "msg_132.c"
 
 // Test for message: conversion from '%s' to '%s' may lose accuracy [132]
@@ -6,67 +6,107 @@
 /*
  * NetBSD's default lint flags only include a single -a, which only flags
  * narrowing conversions from long.  To get warnings for all narrowing
- * conversions, -aa needs to be given more than once.
+ * conversions, -a needs to be given more than once.
  *
  * https://gnats.netbsd.org/14531
  */
 
 /* lint1-extra-flags: -aa */
 
-typedef unsigned char u8;
-typedef unsigned short u16;
-typedef unsigned int u32;
-typedef unsigned long long u64;
-
-typedef signed char i8;
-typedef signed short i16;
-typedef signed int i32;
-typedef signed long long i64;
+unsigned char u8;
+unsigned short u16;
+unsigned int u32;
+unsigned long long u64;
+
+signed char s8;
+signed short s16;
+signed int s32;
+signed long long s64;
 
 void
-convert_unsigned(u8 v8, u16 v16, u32 v32, u64 v64)
+unsigned_to_unsigned(void)
 {
-	v8 = v16;		/* expect: 132 */
-	v8 = v32;		/* expect: 132 */
-	v8 = v64;		/* expect: 132 */
-
-	v16 = v8;
-	v16 = v32;		/* expect: 132 */
-	v16 = v64;		/* expect: 132 */
-
-	v32 = v8;
-	v32 = v16;
-	v32 = v64;		/* expect: 132 */
-
-	v64 = v8;
-	v64 = v16;
-	v64 = v32;
+	u8 = u16;		/* expect: 132 */
+	u8 = u32;		/* expect: 132 */
+	u8 = u64;		/* expect: 132 */
+
+	u16 = u8;
+	u16 = u32;		/* expect: 132 */
+	u16 = u64;		/* expect: 132 */
+
+	u32 = u8;
+	u32 = u16;
+	u32 = u64;		/* expect: 132 */
+
+	u64 = u8;
+	u64 = u16;
+	u64 = u32;
 }
 
 void
-convert_signed(i8 v8, i16 v16, i32 v32, i64 v64)
+unsigned_to_signed(void)
 {
-	v8 = v16;		/* expect: 132 */
-	v8 = v32;		/* expect: 132 */
-	v8 = v64;		/* expect: 132 */
-
-	v16 = v8;
-	v16 = v32;		/* expect: 132 */
-	v16 = v64;		/* expect: 132 */
-
-	v32 = v8;
-	v32 = v16;
-	v32 = v64;		/* expect: 132 */
-
-	v64 = v8;
-	v64 = v16;
-	v64 = v32;
+	s8 = u16;		/* expect: 132 */
+	s8 = u32;		/* expect: 132 */
+	s8 = u64;		/* expect: 132 */
+
+	s16 = u8;
+	s16 = u32;		/* expect: 132 */
+	s16 = u64;		/* expect: 132 */
+
+	s32 = u8;
+	s32 = u16;
+	s32 = u64;		/* expect: 132 */
+
+	s64 = u8;
+	s64 = u16;
+	s64 = u32;
+}
+
+void
+signed_to_unsigned(void)
+{
+	u8 = s16;		/* expect: 132 */
+	u8 = s32;		/* expect: 132 */
+	u8 = s64;		/* expect: 132 */
+
+	u16 = s8;
+	u16 = s32;		/* expect: 132 */
+	u16 = s64;		/* expect: 132 */
+
+	u32 = s8;
+	u32 = s16;
+	u32 = s64;		/* expect: 132 */
+
+	u64 = s8;
+	u64 = s16;
+	u64 = s32;
+}
+
+void
+signed_to_signed(void)
+{
+	s8 = s16;		/* expect: 132 */
+	s8 = s32;		/* expect: 132 */
+	s8 = s64;		/* expect: 132 */
+
+	s16 = s8;
+	s16 = s32;		/* expect: 132 */
+	s16 = s64;		/* expect: 132 */
+
+	s32 = s8;
+	s32 = s16;
+	s32 = s64;		/* expect: 132 */
+
+	s64 = s8;
+	s64 = s16;
+	s64 = s32;
 }
 
 /*
- * Before tree.c 1.268 from 2021-04-06, lint wrongly warned that conversion to
- * _Bool might lose accuracy.  C99 6.3.1.2 defines a special conversion rule
- * from scalar to _Bool though.
+ * Before tree.c 1.268 from 2021-04-06, lint wrongly warned that conversion
+ * to _Bool might lose accuracy.  C99 6.3.1.2 defines a special conversion
+ * rule from scalar to _Bool though by comparing the value to 0.
  */
 _Bool
 to_bool(long a, long b)

Index: src/tests/usr.bin/xlint/lint1/msg_132.exp
diff -u src/tests/usr.bin/xlint/lint1/msg_132.exp:1.7 src/tests/usr.bin/xlint/lint1/msg_132.exp:1.8
--- src/tests/usr.bin/xlint/lint1/msg_132.exp:1.7	Wed Apr 20 22:50:56 2022
+++ src/tests/usr.bin/xlint/lint1/msg_132.exp	Thu Apr 21 19:48:18 2022
@@ -4,12 +4,24 @@ msg_132.c(31): warning: conversion from 
 msg_132.c(34): warning: conversion from 'unsigned int' to 'unsigned short' may lose accuracy [132]
 msg_132.c(35): warning: conversion from 'unsigned long long' to 'unsigned short' may lose accuracy [132]
 msg_132.c(39): warning: conversion from 'unsigned long long' to 'unsigned int' may lose accuracy [132]
-msg_132.c(49): warning: conversion from 'short' to 'signed char' may lose accuracy [132]
-msg_132.c(50): warning: conversion from 'int' to 'signed char' may lose accuracy [132]
-msg_132.c(51): war

CVS commit: src/tests/usr.bin/xlint/lint1

2022-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Thu Apr 21 19:48:18 UTC 2022

Modified Files:
src/tests/usr.bin/xlint/lint1: msg_132.c msg_132.exp

Log Message:
tests/lint: extend test for lossy integer conversion


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/tests/usr.bin/xlint/lint1/msg_132.c
cvs rdiff -u -r1.7 -r1.8 src/tests/usr.bin/xlint/lint1/msg_132.exp

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



CVS commit: src/usr.bin/xlint/lint2

2022-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Thu Apr 21 21:09:13 UTC 2022

Modified Files:
src/usr.bin/xlint/lint2: chk.c

Log Message:
lint: expand the last remaining __arraycount

For consistency with the other expressions for an array length, which
already use the expanded form.

No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.46 -r1.47 src/usr.bin/xlint/lint2/chk.c

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



CVS commit: src/usr.bin/xlint/lint2

2022-04-21 Thread Roland Illig
Module Name:src
Committed By:   rillig
Date:   Thu Apr 21 21:09:13 UTC 2022

Modified Files:
src/usr.bin/xlint/lint2: chk.c

Log Message:
lint: expand the last remaining __arraycount

For consistency with the other expressions for an array length, which
already use the expanded form.

No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.46 -r1.47 src/usr.bin/xlint/lint2/chk.c

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

Modified files:

Index: src/usr.bin/xlint/lint2/chk.c
diff -u src/usr.bin/xlint/lint2/chk.c:1.46 src/usr.bin/xlint/lint2/chk.c:1.47
--- src/usr.bin/xlint/lint2/chk.c:1.46	Tue Nov 16 22:12:44 2021
+++ src/usr.bin/xlint/lint2/chk.c	Thu Apr 21 21:09:13 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: chk.c,v 1.46 2021/11/16 22:12:44 rillig Exp $ */
+/* $NetBSD: chk.c,v 1.47 2022/04/21 21:09:13 rillig Exp $ */
 
 /*
  * Copyright (c) 1996 Christopher G. Demetriou.  All Rights Reserved.
@@ -38,7 +38,7 @@
 
 #include 
 #if defined(__RCSID) && !defined(lint)
-__RCSID("$NetBSD: chk.c,v 1.46 2021/11/16 22:12:44 rillig Exp $");
+__RCSID("$NetBSD: chk.c,v 1.47 2022/04/21 21:09:13 rillig Exp $");
 #endif
 
 #include 
@@ -1084,15 +1084,16 @@ chkrvu(const hte_t *hte, sym_t *def)
 
 	if (def->s_function_has_return_value) {
 		/*
-		 * XXX as soon as we are able to disable single warnings
+		 * XXX as soon as we are able to disable single warnings,
 		 * the following dependencies from hflag should be removed.
-		 * but for now I don't want to be bothered by this warnings
+		 * But for now I don't want to be bothered by these warnings
 		 * which are almost always useless.
 		 */
 		if (!hflag)
 			return;
 		if (hflag && bsearch(hte->h_name, ignorelist,
-		__arraycount(ignorelist), sizeof(ignorelist[0]),
+		sizeof(ignorelist) / sizeof(ignorelist[0]),
+		sizeof(ignorelist[0]),
 		(int (*)(const void *, const void *))strcmp) != NULL)
 			return;
 



CVS commit: src/sys/arch/arm

2022-04-21 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Thu Apr 21 21:22:25 UTC 2022

Modified Files:
src/sys/arch/arm/nvidia: tegra_drm.c
src/sys/arch/arm/rockchip: rk_drm.c
src/sys/arch/arm/sunxi: sunxi_drm.c
src/sys/arch/arm/ti: ti_lcdc.c

Log Message:
s/subesquent/subsequent/ in copy pasted comments.


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/nvidia/tegra_drm.c
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/rockchip/rk_drm.c
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/sunxi/sunxi_drm.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/ti/ti_lcdc.c

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



CVS commit: src/sys/arch/arm

2022-04-21 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Thu Apr 21 21:22:25 UTC 2022

Modified Files:
src/sys/arch/arm/nvidia: tegra_drm.c
src/sys/arch/arm/rockchip: rk_drm.c
src/sys/arch/arm/sunxi: sunxi_drm.c
src/sys/arch/arm/ti: ti_lcdc.c

Log Message:
s/subesquent/subsequent/ in copy pasted comments.


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/nvidia/tegra_drm.c
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/rockchip/rk_drm.c
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/sunxi/sunxi_drm.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/ti/ti_lcdc.c

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/arm/nvidia/tegra_drm.c
diff -u src/sys/arch/arm/nvidia/tegra_drm.c:1.15 src/sys/arch/arm/nvidia/tegra_drm.c:1.16
--- src/sys/arch/arm/nvidia/tegra_drm.c:1.15	Wed Feb 23 07:55:56 2022
+++ src/sys/arch/arm/nvidia/tegra_drm.c	Thu Apr 21 21:22:25 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: tegra_drm.c,v 1.15 2022/02/23 07:55:56 skrll Exp $ */
+/* $NetBSD: tegra_drm.c,v 1.16 2022/04/21 21:22:25 andvar Exp $ */
 
 /*-
  * Copyright (c) 2015 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: tegra_drm.c,v 1.15 2022/02/23 07:55:56 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tegra_drm.c,v 1.16 2022/04/21 21:22:25 andvar Exp $");
 
 #include 
 #include 
@@ -249,7 +249,7 @@ tegra_drm_attach(device_t parent, device
 		(*task->tdt_fn)(task);
 	}
 
-out:	/* Cause any subesquent tasks to be processed by the workqueue.  */
+out:	/* Cause any subsequent tasks to be processed by the workqueue.  */
 	atomic_store_relaxed(&sc->sc_task_thread, NULL);
 }
 

Index: src/sys/arch/arm/rockchip/rk_drm.c
diff -u src/sys/arch/arm/rockchip/rk_drm.c:1.18 src/sys/arch/arm/rockchip/rk_drm.c:1.19
--- src/sys/arch/arm/rockchip/rk_drm.c:1.18	Mon Dec 20 00:27:17 2021
+++ src/sys/arch/arm/rockchip/rk_drm.c	Thu Apr 21 21:22:25 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: rk_drm.c,v 1.18 2021/12/20 00:27:17 riastradh Exp $ */
+/* $NetBSD: rk_drm.c,v 1.19 2022/04/21 21:22:25 andvar Exp $ */
 
 /*-
  * Copyright (c) 2019 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: rk_drm.c,v 1.18 2021/12/20 00:27:17 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rk_drm.c,v 1.19 2022/04/21 21:22:25 andvar Exp $");
 
 #include 
 #include 
@@ -205,7 +205,7 @@ rk_drm_init(device_t dev)
 		(*task->rdt_fn)(task);
 	}
 
-out:	/* Cause any subesquent tasks to be processed by the workqueue.  */
+out:	/* Cause any subsequent tasks to be processed by the workqueue.  */
 	atomic_store_relaxed(&sc->sc_task_thread, NULL);
 }
 

Index: src/sys/arch/arm/sunxi/sunxi_drm.c
diff -u src/sys/arch/arm/sunxi/sunxi_drm.c:1.23 src/sys/arch/arm/sunxi/sunxi_drm.c:1.24
--- src/sys/arch/arm/sunxi/sunxi_drm.c:1.23	Sun Dec 19 12:28:44 2021
+++ src/sys/arch/arm/sunxi/sunxi_drm.c	Thu Apr 21 21:22:25 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: sunxi_drm.c,v 1.23 2021/12/19 12:28:44 riastradh Exp $ */
+/* $NetBSD: sunxi_drm.c,v 1.24 2022/04/21 21:22:25 andvar Exp $ */
 
 /*-
  * Copyright (c) 2019 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: sunxi_drm.c,v 1.23 2021/12/19 12:28:44 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sunxi_drm.c,v 1.24 2022/04/21 21:22:25 andvar Exp $");
 
 #include 
 #include 
@@ -217,7 +217,7 @@ sunxi_drm_init(device_t dev)
 		(*task->sdt_fn)(task);
 	}
 
-out:	/* Cause any subesquent tasks to be processed by the workqueue.  */
+out:	/* Cause any subsequent tasks to be processed by the workqueue.  */
 	atomic_store_relaxed(&sc->sc_task_thread, NULL);
 }
 

Index: src/sys/arch/arm/ti/ti_lcdc.c
diff -u src/sys/arch/arm/ti/ti_lcdc.c:1.10 src/sys/arch/arm/ti/ti_lcdc.c:1.11
--- src/sys/arch/arm/ti/ti_lcdc.c:1.10	Sun Dec 19 12:44:57 2021
+++ src/sys/arch/arm/ti/ti_lcdc.c	Thu Apr 21 21:22:25 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: ti_lcdc.c,v 1.10 2021/12/19 12:44:57 riastradh Exp $ */
+/* $NetBSD: ti_lcdc.c,v 1.11 2022/04/21 21:22:25 andvar Exp $ */
 
 /*-
  * Copyright (c) 2019 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ti_lcdc.c,v 1.10 2021/12/19 12:44:57 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ti_lcdc.c,v 1.11 2022/04/21 21:22:25 andvar Exp $");
 
 #include 
 #include 
@@ -472,7 +472,7 @@ tilcdc_attach(device_t parent, device_t 
 		(*task->tdt_fn)(task);
 	}
 
-out:	/* Cause any subesquent tasks to be processed by the workqueue.  */
+out:	/* Cause any subsequent tasks to be processed by the workqueue.  */
 	atomic_store_relaxed(&sc->sc_task_thread, NULL);
 }
 



CVS commit: src/sys

2022-04-21 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Thu Apr 21 21:31:11 UTC 2022

Modified Files:
src/sys/arch/atari/include: pmap.h
src/sys/dev/microcode/siop: ncr53cxxx.c
src/sys/kern: sys_sig.c

Log Message:
s/substract/subtract/ in comments and error message.
s/obtainted/obtained/ in one comment.


To generate a diff of this commit:
cvs rdiff -u -r1.41 -r1.42 src/sys/arch/atari/include/pmap.h
cvs rdiff -u -r1.16 -r1.17 src/sys/dev/microcode/siop/ncr53cxxx.c
cvs rdiff -u -r1.55 -r1.56 src/sys/kern/sys_sig.c

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



CVS commit: src/sys

2022-04-21 Thread Andrius Varanavicius
Module Name:src
Committed By:   andvar
Date:   Thu Apr 21 21:31:11 UTC 2022

Modified Files:
src/sys/arch/atari/include: pmap.h
src/sys/dev/microcode/siop: ncr53cxxx.c
src/sys/kern: sys_sig.c

Log Message:
s/substract/subtract/ in comments and error message.
s/obtainted/obtained/ in one comment.


To generate a diff of this commit:
cvs rdiff -u -r1.41 -r1.42 src/sys/arch/atari/include/pmap.h
cvs rdiff -u -r1.16 -r1.17 src/sys/dev/microcode/siop/ncr53cxxx.c
cvs rdiff -u -r1.55 -r1.56 src/sys/kern/sys_sig.c

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/atari/include/pmap.h
diff -u src/sys/arch/atari/include/pmap.h:1.41 src/sys/arch/atari/include/pmap.h:1.42
--- src/sys/arch/atari/include/pmap.h:1.41	Sun Dec  6 06:41:29 2009
+++ src/sys/arch/atari/include/pmap.h	Thu Apr 21 21:31:11 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.h,v 1.41 2009/12/06 06:41:29 tsutsui Exp $	*/
+/*	$NetBSD: pmap.h,v 1.42 2022/04/21 21:31:11 andvar Exp $	*/
 
 /* 
  * Copyright (c) 1991 Regents of the University of California.
@@ -95,10 +95,10 @@ struct memseg {
 /*
  * Memory segment descriptors.
  *  - boot_segs
- *	describes the segments obtainted from the bootcode. 
+ *	describes the segments obtained from the bootcode. 
  *  - usable_segs
  *	describes the segments available after system requirements are
- *	substracted (reserved pages, etc...).
+ *	subtracted (reserved pages, etc...).
  */
 extern struct memseg	boot_segs[NMEM_SEGS];
 extern struct memseg	usable_segs[NMEM_SEGS];

Index: src/sys/dev/microcode/siop/ncr53cxxx.c
diff -u src/sys/dev/microcode/siop/ncr53cxxx.c:1.16 src/sys/dev/microcode/siop/ncr53cxxx.c:1.17
--- src/sys/dev/microcode/siop/ncr53cxxx.c:1.16	Wed Oct 21 23:53:38 2009
+++ src/sys/dev/microcode/siop/ncr53cxxx.c	Thu Apr 21 21:31:11 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: ncr53cxxx.c,v 1.16 2009/10/21 23:53:38 snj Exp $	*/
+/*	$NetBSD: ncr53cxxx.c,v 1.17 2022/04/21 21:31:11 andvar Exp $	*/
 
 /*
  * Copyright (c) 1995,1999 Michael L. Hitch
@@ -28,7 +28,7 @@
 /*	ncr53cxxx.c	- SCSI SCRIPTS Assembler		*/
 
 #include 
-__RCSID("$NetBSD: ncr53cxxx.c,v 1.16 2009/10/21 23:53:38 snj Exp $");
+__RCSID("$NetBSD: ncr53cxxx.c,v 1.17 2022/04/21 21:31:11 andvar Exp $");
 
 #include 
 #include 
@@ -413,7 +413,7 @@ main (int argc, char *argv[])
 	if (outfp) {
 		time_t cur_time;
 
-		fprintf(outfp, "/*\t$NetBSD: ncr53cxxx.c,v 1.16 2009/10/21 23:53:38 snj Exp $\t*/\n");
+		fprintf(outfp, "/*\t$NetBSD: ncr53cxxx.c,v 1.17 2022/04/21 21:31:11 andvar Exp $\t*/\n");
 		fprintf(outfp, "/*\n");
 		fprintf(outfp, " *\tDO NOT EDIT - this file is automatically generated.\n");
 		time(&cur_time);
@@ -1386,7 +1386,7 @@ fprintf (listfp, "Move data to register:
 if (arch < ARCH825)
 	errout("wrong arch for add with SFBR");
 if (op == 8)
-	errout("can't substract SFBR");
+	errout("can't subtract SFBR");
 inst0 |= 0x0080;
 data = 0;
 			} else

Index: src/sys/kern/sys_sig.c
diff -u src/sys/kern/sys_sig.c:1.55 src/sys/kern/sys_sig.c:1.56
--- src/sys/kern/sys_sig.c:1.55	Sun Nov  7 01:51:56 2021
+++ src/sys/kern/sys_sig.c	Thu Apr 21 21:31:11 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: sys_sig.c,v 1.55 2021/11/07 01:51:56 thorpej Exp $	*/
+/*	$NetBSD: sys_sig.c,v 1.56 2022/04/21 21:31:11 andvar Exp $	*/
 
 /*-
  * Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -66,7 +66,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: sys_sig.c,v 1.55 2021/11/07 01:51:56 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sys_sig.c,v 1.56 2022/04/21 21:31:11 andvar Exp $");
 
 #include "opt_dtrace.h"
 
@@ -838,7 +838,7 @@ sigtimedwait1(struct lwp *l, const struc
 		/* Compute how much time has passed since start. */
 		timespecsub(&tsnow, &tsstart, &tsnow);
 
-		/* Substract passed time from timeout. */
+		/* Subtract passed time from timeout. */
 		timespecsub(&ts, &tsnow, &ts);
 
 		if (ts.tv_sec < 0)