Re: CVS commit: src/sys/kern

2019-08-15 Thread Nick Hudson

On 15/08/2019 23:05, matthew green wrote:

"Maxime Villard" writes:

Module Name:src
Committed By:   maxv
Date:   Thu Aug 15 12:06:42 UTC 2019

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

Log Message:
Retire KMEM_GUARD. It has been superseded by kASan, which is much more
powerful, has much more coverage - far beyond just kmem(9) -, and also
consumes less memory.

KMEM_GUARD was a debug-only option that required special DDB tweaking, and
had no use in releases or even diagnostic kernels.

As a general rule, the policy now is to harden the pool layer by default
in GENERIC, and use kASan as a diagnostic/debug/fuzzing feature to verify
each memory allocation & access in the system.


was this discussed?

KMEM_GUARD is useful for platforms that don't have kasan yet.


yet? Can 32bit platforms and limit KVA have KASAN?

Nick


CVS commit: [netbsd-9] src/doc

2019-08-15 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Fri Aug 16 02:09:21 UTC 2019

Modified Files:
src/doc [netbsd-9]: CHANGES-9.0

Log Message:
 Add missing file names and revision numbers for sysinst/disks.c.


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.18 -r1.1.2.19 src/doc/CHANGES-9.0

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



CVS commit: src/sys/arch/macppc/dev

2019-08-15 Thread Michael Lorenz
Module Name:src
Committed By:   macallan
Date:   Thu Aug 15 22:35:39 UTC 2019

Modified Files:
src/sys/arch/macppc/dev: ki2c.c

Log Message:
pass sensor location info to drivers if we can find it


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/macppc/dev/ki2c.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/macppc/dev/ki2c.c
diff -u src/sys/arch/macppc/dev/ki2c.c:1.25 src/sys/arch/macppc/dev/ki2c.c:1.26
--- src/sys/arch/macppc/dev/ki2c.c:1.25	Thu Mar  8 21:53:20 2018
+++ src/sys/arch/macppc/dev/ki2c.c	Thu Aug 15 22:35:39 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: ki2c.c,v 1.25 2018/03/08 21:53:20 macallan Exp $	*/
+/*	$NetBSD: ki2c.c,v 1.26 2019/08/15 22:35:39 macallan Exp $	*/
 /*	Id: ki2c.c,v 1.7 2002/10/05 09:56:05 tsubai Exp	*/
 
 /*-
@@ -84,13 +84,13 @@ ki2c_attach(device_t parent, device_t se
 	struct ki2c_softc *sc = device_private(self);
 	struct confargs *ca = aux;
 	int node = ca->ca_node;
-	uint32_t addr, channel;
+	uint32_t addr, channel, reg;
 	int rate, child, /*namelen,*/ i2cbus;
 	struct i2cbus_attach_args iba;
 	prop_dictionary_t dict = device_properties(self);
 	prop_array_t cfg;
-	int devs;
-	char compat[256];
+	int devs, devc;
+	char compat[256], num[8], descr[32];
 	prop_dictionary_t dev;
 	prop_data_t data;
 	char name[32];
@@ -178,6 +178,18 @@ ki2c_attach(device_t parent, device_t se
 		prop_object_release(data);
 		prop_dictionary_set_uint32(dev, "addr", addr);
 		prop_dictionary_set_uint64(dev, "cookie", devs);
+		/* look for location info for sensors */
+		devc = OF_child(devs);
+		while (devc != 0) {
+			if (OF_getprop(devc, "reg", , 4) < 4) goto nope;
+			if (OF_getprop(devc, "location", descr, 32) <= 0)
+goto nope;
+			DPRINTF("found '%s' at %02x\n", descr, reg);
+			snprintf(num, 7, "s%02x", reg);
+			prop_dictionary_set_cstring(dev, num, descr);
+		nope:
+			devc = OF_peer(devc);
+		}
 		prop_array_add(cfg, dev);
 		prop_object_release(dev);
 	skip:



CVS commit: src/sys/arch/macppc/dev

2019-08-15 Thread Michael Lorenz
Module Name:src
Committed By:   macallan
Date:   Thu Aug 15 22:35:39 UTC 2019

Modified Files:
src/sys/arch/macppc/dev: ki2c.c

Log Message:
pass sensor location info to drivers if we can find it


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/macppc/dev/ki2c.c

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



re: CVS commit: src/sys/kern

2019-08-15 Thread matthew green
"Maxime Villard" writes:
> Module Name:  src
> Committed By: maxv
> Date: Thu Aug 15 12:06:42 UTC 2019
> 
> Modified Files:
>   src/sys/kern: subr_kmem.c
> 
> Log Message:
> Retire KMEM_GUARD. It has been superseded by kASan, which is much more
> powerful, has much more coverage - far beyond just kmem(9) -, and also
> consumes less memory.
> 
> KMEM_GUARD was a debug-only option that required special DDB tweaking, and
> had no use in releases or even diagnostic kernels.
> 
> As a general rule, the policy now is to harden the pool layer by default
> in GENERIC, and use kASan as a diagnostic/debug/fuzzing feature to verify
> each memory allocation & access in the system.

was this discussed?

KMEM_GUARD is useful for platforms that don't have kasan yet.


.mrg.


CVS commit: src/distrib/notes/common

2019-08-15 Thread Valeriy E. Ushakov
Module Name:src
Committed By:   uwe
Date:   Thu Aug 15 21:12:16 UTC 2019

Removed Files:
src/distrib/notes/common: list-portmasters.pl

Log Message:
Remove list-portmasters.pl script.
We dropped that list from "main" some time ago.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r0 src/distrib/notes/common/list-portmasters.pl

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



CVS commit: src/distrib/notes/common

2019-08-15 Thread Valeriy E. Ushakov
Module Name:src
Committed By:   uwe
Date:   Thu Aug 15 21:12:16 UTC 2019

Removed Files:
src/distrib/notes/common: list-portmasters.pl

Log Message:
Remove list-portmasters.pl script.
We dropped that list from "main" some time ago.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r0 src/distrib/notes/common/list-portmasters.pl

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



CVS commit: src/bin/pax

2019-08-15 Thread Valeriy E. Ushakov
Module Name:src
Committed By:   uwe
Date:   Thu Aug 15 21:05:16 UTC 2019

Modified Files:
src/bin/pax: Makefile

Log Message:
Install manual pages for tar and cpio only if ${MKBSDTAR} == "no"
PR bin/54468


To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/bin/pax/Makefile

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

Modified files:

Index: src/bin/pax/Makefile
diff -u src/bin/pax/Makefile:1.39 src/bin/pax/Makefile:1.40
--- src/bin/pax/Makefile:1.39	Fri Apr 23 19:41:02 2010
+++ src/bin/pax/Makefile	Thu Aug 15 21:05:16 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.39 2010/04/23 19:41:02 joerg Exp $
+#	$NetBSD: Makefile,v 1.40 2019/08/15 21:05:16 uwe Exp $
 #   @(#)Makefile	8.1 (Berkeley) 5/31/93
 
 .include 
@@ -23,7 +23,7 @@ LDADD+= -lutil
 .endif
 .endif
 
-MAN=	pax.1 tar.1 cpio.1
+MAN=	pax.1
 
 .if defined(HOSTPROG)
 CPPFLAGS+=	-DHOSTPROG
@@ -35,9 +35,11 @@ CPPFLAGS+=	-DHAVE_SYS_MTIO_H
 .if ${MKBSDTAR} == "no"
 LINKS+=	${BINDIR}/pax ${BINDIR}/tar
 SYMLINKS+=${BINDIR}/tar /usr/bin/tar
+MAN+=tar.1
 
 LINKS+=	${BINDIR}/pax ${BINDIR}/cpio
 SYMLINKS+=${BINDIR}/cpio /usr/bin/cpio
+MAN+=cpio.1
 .endif
 .endif	# }	! HOSTPROG
 



CVS commit: src/bin/pax

2019-08-15 Thread Valeriy E. Ushakov
Module Name:src
Committed By:   uwe
Date:   Thu Aug 15 21:05:16 UTC 2019

Modified Files:
src/bin/pax: Makefile

Log Message:
Install manual pages for tar and cpio only if ${MKBSDTAR} == "no"
PR bin/54468


To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/bin/pax/Makefile

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



CVS commit: src/usr.sbin/installboot

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 19:53:01 UTC 2019

Modified Files:
src/usr.sbin/installboot: Makefile machines.c

Log Message:
Never trust a compiler that predefines i386 as 1 - do the symbol name
concatenation at the make level instead.


To generate a diff of this commit:
cvs rdiff -u -r1.53 -r1.54 src/usr.sbin/installboot/Makefile
cvs rdiff -u -r1.41 -r1.42 src/usr.sbin/installboot/machines.c

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



CVS commit: src/usr.sbin/installboot

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 19:53:01 UTC 2019

Modified Files:
src/usr.sbin/installboot: Makefile machines.c

Log Message:
Never trust a compiler that predefines i386 as 1 - do the symbol name
concatenation at the make level instead.


To generate a diff of this commit:
cvs rdiff -u -r1.53 -r1.54 src/usr.sbin/installboot/Makefile
cvs rdiff -u -r1.41 -r1.42 src/usr.sbin/installboot/machines.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/installboot/Makefile
diff -u src/usr.sbin/installboot/Makefile:1.53 src/usr.sbin/installboot/Makefile:1.54
--- src/usr.sbin/installboot/Makefile:1.53	Thu Aug 15 14:06:40 2019
+++ src/usr.sbin/installboot/Makefile	Thu Aug 15 19:53:01 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.53 2019/08/15 14:06:40 martin Exp $
+#	$NetBSD: Makefile,v 1.54 2019/08/15 19:53:01 martin Exp $
 #
 
 .include 
@@ -27,7 +27,7 @@ ARCH_FILES?= ${ARCH_XLAT:M${MACHINE}-*:S
 .if empty(ARCH_FILES)
 ARCH_FILES= ${MACHINE}.c
 .endif
-COPTS.machines.c+=	-DSINGLE_ARCH="${MACHINE}"
+COPTS.machines.c+=	-DSINGLE_ARCH=ib_mach_${MACHINE}
 .endif
 
 SRCS+=${ARCH_FILES}

Index: src/usr.sbin/installboot/machines.c
diff -u src/usr.sbin/installboot/machines.c:1.41 src/usr.sbin/installboot/machines.c:1.42
--- src/usr.sbin/installboot/machines.c:1.41	Thu Aug 15 14:06:40 2019
+++ src/usr.sbin/installboot/machines.c	Thu Aug 15 19:53:01 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: machines.c,v 1.41 2019/08/15 14:06:40 martin Exp $	*/
+/*	$NetBSD: machines.c,v 1.42 2019/08/15 19:53:01 martin Exp $	*/
 
 /*-
  * Copyright (c) 2002-2005 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
 
 #include 
 #if !defined(__lint)
-__RCSID("$NetBSD: machines.c,v 1.41 2019/08/15 14:06:40 martin Exp $");
+__RCSID("$NetBSD: machines.c,v 1.42 2019/08/15 19:53:01 martin Exp $");
 #endif	/* !__lint */
 
 #include 
@@ -43,9 +43,7 @@ __RCSID("$NetBSD: machines.c,v 1.41 2019
 
 struct ib_mach * const machines[] = {
 #ifdef	SINGLE_ARCH
-#define	IB_PREFIX(X)	ib_mach_##X
-#define	MY_ARCH(X) IB_PREFIX(X)
-_ARCH(SINGLE_ARCH),
+_ARCH,
 #else
 _mach_alpha,
 _mach_amd64,



CVS commit: src

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 16:31:17 UTC 2019

Modified Files:
src/distrib/sets/lists/comp: mi
src/external/bsd/compiler_rt/lib/clang/include/sanitizer: Makefile

Log Message:
Ship with sanitizer/lsan_interface.h for LLVM 7

Leak Sanitizer header is already needed in the distribution for built with
Address Sanitizer (MKSANITIZER):

 - dist/llvm/utils/TableGen/TableGen.cpp
 - dist/clang/utils/TableGen/TableGen.cpp

Next version of LLVM (9.0) will ship with LSan.


To generate a diff of this commit:
cvs rdiff -u -r1.2281 -r1.2282 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.1 -r1.2 \
src/external/bsd/compiler_rt/lib/clang/include/sanitizer/Makefile

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



CVS commit: src

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 16:31:17 UTC 2019

Modified Files:
src/distrib/sets/lists/comp: mi
src/external/bsd/compiler_rt/lib/clang/include/sanitizer: Makefile

Log Message:
Ship with sanitizer/lsan_interface.h for LLVM 7

Leak Sanitizer header is already needed in the distribution for built with
Address Sanitizer (MKSANITIZER):

 - dist/llvm/utils/TableGen/TableGen.cpp
 - dist/clang/utils/TableGen/TableGen.cpp

Next version of LLVM (9.0) will ship with LSan.


To generate a diff of this commit:
cvs rdiff -u -r1.2281 -r1.2282 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.1 -r1.2 \
src/external/bsd/compiler_rt/lib/clang/include/sanitizer/Makefile

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

Modified files:

Index: src/distrib/sets/lists/comp/mi
diff -u src/distrib/sets/lists/comp/mi:1.2281 src/distrib/sets/lists/comp/mi:1.2282
--- src/distrib/sets/lists/comp/mi:1.2281	Thu Aug 15 16:01:27 2019
+++ src/distrib/sets/lists/comp/mi	Thu Aug 15 16:31:17 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: mi,v 1.2281 2019/08/15 16:01:27 kamil Exp $
+#	$NetBSD: mi,v 1.2282 2019/08/15 16:31:17 kamil Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 ./etc/mtree/set.compcomp-sys-root
@@ -3302,6 +3302,7 @@
 ./usr/lib/clang/7.0.0/include/sanitizer/asan_interface.h	comp-cxx-include		llvm
 ./usr/lib/clang/7.0.0/include/sanitizer/common_interface_defs.h	comp-cxx-include		llvm
 ./usr/lib/clang/7.0.0/include/sanitizer/coverage_interface.h	comp-cxx-include		llvm
+./usr/lib/clang/7.0.0/include/sanitizer/lsan_interface.h	comp-cxx-include		llvm
 ./usr/lib/clang/7.0.0/include/sanitizer/msan_interface.h	comp-cxx-include		llvm
 ./usr/lib/clang/7.0.0/include/sanitizer/netbsd_syscall_hooks.h	comp-cxx-include		llvm
 ./usr/lib/clang/7.0.0/include/sanitizer/tsan_interface.h	comp-cxx-include		llvm

Index: src/external/bsd/compiler_rt/lib/clang/include/sanitizer/Makefile
diff -u src/external/bsd/compiler_rt/lib/clang/include/sanitizer/Makefile:1.1 src/external/bsd/compiler_rt/lib/clang/include/sanitizer/Makefile:1.2
--- src/external/bsd/compiler_rt/lib/clang/include/sanitizer/Makefile:1.1	Thu Aug  8 14:00:28 2019
+++ src/external/bsd/compiler_rt/lib/clang/include/sanitizer/Makefile	Thu Aug 15 16:31:17 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.1 2019/08/08 14:00:28 kamil Exp $
+#	$NetBSD: Makefile,v 1.2 2019/08/15 16:31:17 kamil Exp $
 
 TOPDIR=	${NETBSDSRCDIR}/sys/external/bsd/compiler_rt/dist
 
@@ -13,7 +13,7 @@ INCS+=	coverage_interface.h
 #INCS+=	dfsan_interface.h # not supported
 #INCS+=	esan_interface.h # not supported
 #INCS+=	hwasan_interface.h # not supported
-#INCS+=	lsan_interface.h # not supported
+INCS+=	lsan_interface.h
 INCS+=	msan_interface.h
 INCS+=	netbsd_syscall_hooks.h
 #INCS+=	scudo_interface.h # not ready



CVS commit: src

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 16:01:27 UTC 2019

Modified Files:
src/distrib/sets/lists/comp: mi
src/external/gpl3/gcc/usr.bin/include/sanitizer: Makefile

Log Message:
Ship with sanitizer/lsan_interface.h for GCC 7

Leak Sanitizer is there.


To generate a diff of this commit:
cvs rdiff -u -r1.2280 -r1.2281 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/gcc/usr.bin/include/sanitizer/Makefile

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



CVS commit: src

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 16:01:27 UTC 2019

Modified Files:
src/distrib/sets/lists/comp: mi
src/external/gpl3/gcc/usr.bin/include/sanitizer: Makefile

Log Message:
Ship with sanitizer/lsan_interface.h for GCC 7

Leak Sanitizer is there.


To generate a diff of this commit:
cvs rdiff -u -r1.2280 -r1.2281 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/gcc/usr.bin/include/sanitizer/Makefile

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

Modified files:

Index: src/distrib/sets/lists/comp/mi
diff -u src/distrib/sets/lists/comp/mi:1.2280 src/distrib/sets/lists/comp/mi:1.2281
--- src/distrib/sets/lists/comp/mi:1.2280	Wed Aug 14 01:42:08 2019
+++ src/distrib/sets/lists/comp/mi	Thu Aug 15 16:01:27 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: mi,v 1.2280 2019/08/14 01:42:08 kamil Exp $
+#	$NetBSD: mi,v 1.2281 2019/08/15 16:01:27 kamil Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 ./etc/mtree/set.compcomp-sys-root
@@ -2094,6 +2094,7 @@
 ./usr/include/gcc-7/sanitizer/allocator_interface.h	comp-gcc-include	gcc=7
 ./usr/include/gcc-7/sanitizer/asan_interface.h	comp-gcc-include	gcc=7
 ./usr/include/gcc-7/sanitizer/common_interface_defs.h	comp-gcc-include	gcc=7
+./usr/include/gcc-7/sanitizer/lsan_interface.h	comp-gcc-include	gcc=7
 ./usr/include/gcc-7/sanitizer/tsan_interface_atomic.h	comp-gcc-include	gcc=7
 ./usr/include/gcc-7/stdatomic.h			comp-gcc-include	gcc=7
 ./usr/include/gelf.hcomp-c-include

Index: src/external/gpl3/gcc/usr.bin/include/sanitizer/Makefile
diff -u src/external/gpl3/gcc/usr.bin/include/sanitizer/Makefile:1.3 src/external/gpl3/gcc/usr.bin/include/sanitizer/Makefile:1.4
--- src/external/gpl3/gcc/usr.bin/include/sanitizer/Makefile:1.3	Sun Aug 12 21:48:57 2018
+++ src/external/gpl3/gcc/usr.bin/include/sanitizer/Makefile	Thu Aug 15 16:01:27 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.3 2018/08/12 21:48:57 mrg Exp $
+#	$NetBSD: Makefile,v 1.4 2019/08/15 16:01:27 kamil Exp $
 
 .include "../../../Makefile.gcc_path"
 
@@ -13,7 +13,7 @@ INCS+=	allocator_interface.h
 INCS+=	asan_interface.h
 INCS+=	common_interface_defs.h
 #INCS+=	dfsan_interface.h # not supported
-#INCS+=	lsan_interface.h # not supported
+INCS+=	lsan_interface.h
 #INCS+=	msan_interface.h # not ready in GCC
 INCS+=	tsan_interface_atomic.h
 



CVS commit: src/usr.sbin/installboot

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 14:06:40 UTC 2019

Modified Files:
src/usr.sbin/installboot: Makefile machines.c

Log Message:
Replace black voodo linker magic (sometimes failing) with some
makefile + macro magic to trim the list of available machines on size
restricted install media.


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/usr.sbin/installboot/Makefile
cvs rdiff -u -r1.40 -r1.41 src/usr.sbin/installboot/machines.c

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



CVS commit: src/usr.sbin/installboot

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 14:06:40 UTC 2019

Modified Files:
src/usr.sbin/installboot: Makefile machines.c

Log Message:
Replace black voodo linker magic (sometimes failing) with some
makefile + macro magic to trim the list of available machines on size
restricted install media.


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/usr.sbin/installboot/Makefile
cvs rdiff -u -r1.40 -r1.41 src/usr.sbin/installboot/machines.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/installboot/Makefile
diff -u src/usr.sbin/installboot/Makefile:1.52 src/usr.sbin/installboot/Makefile:1.53
--- src/usr.sbin/installboot/Makefile:1.52	Tue May  7 05:02:42 2019
+++ src/usr.sbin/installboot/Makefile	Thu Aug 15 14:06:40 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.52 2019/05/07 05:02:42 thorpej Exp $
+#	$NetBSD: Makefile,v 1.53 2019/08/15 14:06:40 martin Exp $
 #
 
 .include 
@@ -27,6 +27,7 @@ ARCH_FILES?= ${ARCH_XLAT:M${MACHINE}-*:S
 .if empty(ARCH_FILES)
 ARCH_FILES= ${MACHINE}.c
 .endif
+COPTS.machines.c+=	-DSINGLE_ARCH="${MACHINE}"
 .endif
 
 SRCS+=${ARCH_FILES}

Index: src/usr.sbin/installboot/machines.c
diff -u src/usr.sbin/installboot/machines.c:1.40 src/usr.sbin/installboot/machines.c:1.41
--- src/usr.sbin/installboot/machines.c:1.40	Tue May  7 05:02:42 2019
+++ src/usr.sbin/installboot/machines.c	Thu Aug 15 14:06:40 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: machines.c,v 1.40 2019/05/07 05:02:42 thorpej Exp $	*/
+/*	$NetBSD: machines.c,v 1.41 2019/08/15 14:06:40 martin Exp $	*/
 
 /*-
  * Copyright (c) 2002-2005 The NetBSD Foundation, Inc.
@@ -35,41 +35,18 @@
 
 #include 
 #if !defined(__lint)
-__RCSID("$NetBSD: machines.c,v 1.40 2019/05/07 05:02:42 thorpej Exp $");
+__RCSID("$NetBSD: machines.c,v 1.41 2019/08/15 14:06:40 martin Exp $");
 #endif	/* !__lint */
 
 #include 
 #include "installboot.h"
 
-/*
- * Define these here so they end up as zero-filled bss if installboot
- * isn't built with all the architectures defined.
- * A lot simpler that conditionally including the definitions themselves.
- */
-struct ib_mach
-ib_mach_alpha,
-ib_mach_amd64,
-ib_mach_amiga,
-ib_mach_emips,
-ib_mach_evbarm,
-ib_mach_ews4800mips,
-ib_mach_hp300,
-ib_mach_hppa,
-ib_mach_i386,
-ib_mach_landisk,
-ib_mach_macppc,
-ib_mach_news68k,
-ib_mach_newsmips,
-ib_mach_next68k,
-ib_mach_pmax,
-ib_mach_sparc,
-ib_mach_sparc64,
-ib_mach_sun2,
-ib_mach_sun3,
-ib_mach_vax,
-ib_mach_x68k;
-
 struct ib_mach * const machines[] = {
+#ifdef	SINGLE_ARCH
+#define	IB_PREFIX(X)	ib_mach_##X
+#define	MY_ARCH(X) IB_PREFIX(X)
+_ARCH(SINGLE_ARCH),
+#else
 _mach_alpha,
 _mach_amd64,
 _mach_amiga,
@@ -91,6 +68,7 @@ struct ib_mach * const machines[] = {
 _mach_sun3,
 _mach_vax,
 _mach_x68k,
+#endif
 NULL
 };
 



CVS commit: src/doc

2019-08-15 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Thu Aug 15 13:33:15 UTC 2019

Modified Files:
src/doc: CHANGES CHANGES.prev

Log Message:
Recent rasops(9) changes have been pulled up to netbsd-9.


To generate a diff of this commit:
cvs rdiff -u -r1.2568 -r1.2569 src/doc/CHANGES
cvs rdiff -u -r1.145 -r1.146 src/doc/CHANGES.prev

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



CVS commit: src/doc

2019-08-15 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Thu Aug 15 13:33:15 UTC 2019

Modified Files:
src/doc: CHANGES CHANGES.prev

Log Message:
Recent rasops(9) changes have been pulled up to netbsd-9.


To generate a diff of this commit:
cvs rdiff -u -r1.2568 -r1.2569 src/doc/CHANGES
cvs rdiff -u -r1.145 -r1.146 src/doc/CHANGES.prev

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

Modified files:

Index: src/doc/CHANGES
diff -u src/doc/CHANGES:1.2568 src/doc/CHANGES:1.2569
--- src/doc/CHANGES:1.2568	Thu Aug 15 08:55:06 2019
+++ src/doc/CHANGES	Thu Aug 15 13:33:15 2019
@@ -1,4 +1,4 @@
-# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2568 $>
+# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2569 $>
 #
 #
 # [Note: This file does not mention every change made to the NetBSD source tree.
@@ -25,12 +25,6 @@
 
 Changes from NetBSD 9.0 to NetBSD 10.0:
 	openldap: Import 2.4.48. [christos 20180808]
-	rasops(9): Major improvements for rasops(9) routines. General putchar
-		functions added for color depths 2 and 4. Width-optimized
-		putchar functions added for depth 32. Anti-aliasing supported
-		for depths 2 and 24. Shadow framebuffer supported for all
-		depths. A lot of bug fixes, both major and minor. Dedup more
-		than 20% of lines, or 50% of characters. [rin 20190810]
 	usbnet(9): Add common framework for USB network devices.  Port the
 		axe(4), axen(4), cdce(4), cue(4), mue(4), smsc(4), udav(4),
 		ure(4), url(4), and urndis(4) drivers fixing many bugs and

Index: src/doc/CHANGES.prev
diff -u src/doc/CHANGES.prev:1.145 src/doc/CHANGES.prev:1.146
--- src/doc/CHANGES.prev:1.145	Wed Jul 31 06:25:14 2019
+++ src/doc/CHANGES.prev	Thu Aug 15 13:33:15 2019
@@ -1,4 +1,4 @@
-LIST OF CHANGES FROM PREVIOUS RELEASES:			<$Revision: 1.145 $>
+LIST OF CHANGES FROM PREVIOUS RELEASES:			<$Revision: 1.146 $>
 
 
 Changes from 386bsd 0.1 + patchkit 0.2.2 to NetBSD 0.8:
@@ -12626,4 +12626,10 @@ Changes from NetBSD 8.0 to NetBSD 9.0:
 	dhcpcd(8): Import dhcpcd-8.0.1. [roy 20190725]
 	mac68k: Add genfb(4) framebuffer driver. [rin 20190726]
 	dhcpcd(8): Import dhcpcd-8.0.2. [roy 20190730]
+	rasops(9): Major improvements for rasops(9) routines. General putchar
+		functions added for color depths 2 and 4. Width-optimized
+		putchar functions added for depth 32. Anti-aliasing supported
+		for depths 2 and 24. Shadow framebuffer supported for all
+		depths. A lot of bug fixes, both major and minor. Dedup more
+		than 20% of lines, or 50% of characters. [rin 20190810]
 



CVS commit: src

2019-08-15 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Thu Aug 15 12:24:09 UTC 2019

Modified Files:
src/share/man/man9: kmem.9
src/sys/arch/mips/mips: pmap_machdep.c
src/sys/kern: files.kern

Log Message:
Unlink KMEM_GUARD leftovers.


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/share/man/man9/kmem.9
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/mips/mips/pmap_machdep.c
cvs rdiff -u -r1.34 -r1.35 src/sys/kern/files.kern

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



CVS commit: src

2019-08-15 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Thu Aug 15 12:24:09 UTC 2019

Modified Files:
src/share/man/man9: kmem.9
src/sys/arch/mips/mips: pmap_machdep.c
src/sys/kern: files.kern

Log Message:
Unlink KMEM_GUARD leftovers.


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/share/man/man9/kmem.9
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/mips/mips/pmap_machdep.c
cvs rdiff -u -r1.34 -r1.35 src/sys/kern/files.kern

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

Modified files:

Index: src/share/man/man9/kmem.9
diff -u src/share/man/man9/kmem.9:1.23 src/share/man/man9/kmem.9:1.24
--- src/share/man/man9/kmem.9:1.23	Tue Nov  7 18:36:27 2017
+++ src/share/man/man9/kmem.9	Thu Aug 15 12:24:08 2019
@@ -1,4 +1,4 @@
-.\"	$NetBSD: kmem.9,v 1.23 2017/11/07 18:36:27 christos Exp $
+.\"	$NetBSD: kmem.9,v 1.24 2019/08/15 12:24:08 maxv Exp $
 .\"
 .\" Copyright (c)2006 YAMAMOTO Takashi,
 .\" All rights reserved.
@@ -25,7 +25,7 @@
 .\" SUCH DAMAGE.
 .\"
 .\" 
-.Dd November 7, 2017
+.Dd August 15, 2019
 .Dt KMEM 9
 .Os
 .\" 
@@ -69,8 +69,6 @@
 .\" 
 .Pp
 .Cd "options KMEM_SIZE"
-.Cd "options KMEM_REDZONE"
-.Cd "options KMEM_GUARD"
 .Sh DESCRIPTION
 .Fn kmem_alloc
 allocates kernel wired memory.
@@ -260,89 +258,7 @@ Any mismatch triggers a panic.
 .Pp
 .Dv KMEM_SIZE
 is enabled by default on
-.Dv DIAGNOSTIC
-and
-.Dv DEBUG .
-.Ss KMEM_REDZONE
-Kernels compiled with the
-.Dv KMEM_REDZONE
-option add a dynamic pattern of two bytes at the end of each allocated
-buffer, and check this pattern when freeing to ensure the caller hasn't
-written outside the requested area.
-This option does not introduce a significant performance impact,
-but has two drawbacks: it only catches write overflows, and catches
-them only on
-.Fn kmem_free .
-.Pp
-.Dv KMEM_REDZONE
-is enabled by default on
 .Dv DIAGNOSTIC .
-.Ss KMEM_GUARD
-Kernels compiled with the
-.Dv KMEM_GUARD
-option perform CPU intensive sanity checks on kmem operations.
-It adds additional, very high overhead runtime verification to kmem
-operations.
-It must be enabled with
-.Dv KMEM_SIZE .
-.Pp
-.Dv KMEM_GUARD
-tries to catch the following types of bugs:
-.Bl -bullet
-.It
-Overflow at time of occurrence, by means of a guard page.
-An unmapped guard page sits immediately after the requested area;
-a read/write overflow therefore triggers a page fault.
-.It
-Underflow at
-.Fn kmem_free ,
-by using
-.Dv KMEM_SIZE Ap s
-registered size.
-If an underflow occurs, the size stored by
-.Dv KMEM_SIZE
-will be overwritten, which means that when freeing, the kernel will
-spot the mismatch.
-.It
-Use-after-free at time of occurrence.
-When freeing, the memory is unmapped, and depending on the value
-of kmem_guard_depth, the kernel will more or less delay the recycling
-of that memory.
-Which means that any ulterior read/write access to the memory will
-trigger a page fault, given it hasn't been recycled yet.
-.El
-.Pp
-To enable it, boot the system with the
-.Fl d
-option, which causes the debugger to be entered early during the kernel
-boot process.
-Issue commands such as the following:
-.Bd -literal
-db> w kmem_guard_depth 0t3
-db> c
-.Ed
-.Pp
-This instructs
-.Dv kmem_guard
-to queue up to 6 (3*2) pages of unmapped KVA to catch
-use-after-free type errors.
-When
-.Fn kmem_free
-is called, memory backing a freed item is unmapped and the kernel VA
-space pushed onto a FIFO.
-The VA space will not be reused until another 30k items have been freed.
-Until reused the kernel will catch invalid accesses and panic with a page fault.
-Limitations:
-.Bl -bullet
-.It
-It has a severe impact on performance.
-.It
-It is best used on a 64-bit machine with lots of RAM.
-.El
-.Pp
-.Dv KMEM_GUARD
-is enabled by default on
-.Dv DEBUG .
 .Sh RETURN VALUES
 On success,
 .Fn kmem_alloc ,

Index: src/sys/arch/mips/mips/pmap_machdep.c
diff -u src/sys/arch/mips/mips/pmap_machdep.c:1.24 src/sys/arch/mips/mips/pmap_machdep.c:1.25
--- src/sys/arch/mips/mips/pmap_machdep.c:1.24	Sun Jul 14 09:31:33 2019
+++ src/sys/arch/mips/mips/pmap_machdep.c	Thu Aug 15 12:24:08 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap_machdep.c,v 1.24 2019/07/14 09:31:33 skrll Exp $	*/
+/*	$NetBSD: pmap_machdep.c,v 1.25 2019/08/15 12:24:08 maxv Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -67,7 +67,7 @@
 
 #include 
 
-__KERNEL_RCSID(0, "$NetBSD: pmap_machdep.c,v 1.24 2019/07/14 09:31:33 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap_machdep.c,v 1.25 2019/08/15 12:24:08 maxv Exp $");
 
 /*
  *	Manages physical address maps.
@@ -378,12 +378,6 @@ pmap_bootstrap(void)
 	sysmap_size = (VM_PHYS_SIZE + (ubc_nwins << ubc_winshift) +
 	bufsz + 16 * NCARGS + pager_map_size) / NBPG +
 	(maxproc * UPAGES) + 

CVS commit: [netbsd-9] src/doc

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 12:23:59 UTC 2019

Modified Files:
src/doc [netbsd-9]: CHANGES-9.0

Log Message:
Ticket #56


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.17 -r1.1.2.18 src/doc/CHANGES-9.0

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



CVS commit: [netbsd-9] src/doc

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 12:23:59 UTC 2019

Modified Files:
src/doc [netbsd-9]: CHANGES-9.0

Log Message:
Ticket #56


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.17 -r1.1.2.18 src/doc/CHANGES-9.0

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

Modified files:

Index: src/doc/CHANGES-9.0
diff -u src/doc/CHANGES-9.0:1.1.2.17 src/doc/CHANGES-9.0:1.1.2.18
--- src/doc/CHANGES-9.0:1.1.2.17	Thu Aug 15 09:51:12 2019
+++ src/doc/CHANGES-9.0	Thu Aug 15 12:23:59 2019
@@ -1,4 +1,4 @@
-# $NetBSD: CHANGES-9.0,v 1.1.2.17 2019/08/15 09:51:12 martin Exp $
+# $NetBSD: CHANGES-9.0,v 1.1.2.18 2019/08/15 12:23:59 martin Exp $
 
 A complete list of changes from the initial NetBSD 9.0 branch on 2019-07-30
 until the 9.0 release:
@@ -1730,3 +1730,34 @@ sys/arch/evbarm/conf/ZEDBOARD			1.6
 	- fix a9ptmr_delay to work with a decrementing counter!
 	[skrll, ticket #55]
 
+share/man/man9/rasops.91.18,1.19
+sys/arch/luna68k/dev/omrasops.c			1.21
+sys/dev/rasops/README1.7
+sys/dev/rasops/rasops.c1.102-1.122
+sys/dev/rasops/rasops.h1.39-1.48
+sys/dev/rasops/rasops1-4_putchar.h		1.1-1.3
+sys/dev/rasops/rasops1.c			1.32-1.37
+sys/dev/rasops/rasops15.c			1.32-1.39
+sys/dev/rasops/rasops1_putchar_width.h		1.3-1.6
+sys/dev/rasops/rasops2.c			1.27-1.33
+sys/dev/rasops/rasops24.c			1.40-1.50
+sys/dev/rasops/rasops32.c			1.40-1.46
+sys/dev/rasops/rasops4.c			1.21-1.28
+sys/dev/rasops/rasops8.c			1.45-1.51
+sys/dev/rasops/rasops_bitops.h			1.19-1.25
+sys/dev/rasops/rasops_masks.c			1.10
+sys/dev/rasops/rasops_masks.h			1.9
+sys/dev/rasops/rasops_putchar.h			1.6-1.8
+sys/dev/rasops/rasops_putchar_aa.h		delete
+sys/dev/rasops/rasops_putchar_width.h		1.10-1.15
+sys/dev/wscons/wsdisplay_vcons.c		1.40
+sys/dev/wsfb/genfb.c1.68-1.70
+
+	rasops(9): Major improvements for rasops(9) routines. General putchar
+	functions added for color depths 2 and 4. Width-optimized
+	putchar functions added for depth 32. Anti-aliasing supported
+	for depths 2 and 24. Shadow framebuffer supported for all
+	depths. A lot of bug fixes, both major and minor. Dedup more
+	than 20% of lines, or 50% of characters.
+	[rin, ticket #56]
+



CVS commit: [netbsd-9] src

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 12:21:28 UTC 2019

Modified Files:
src/share/man/man9 [netbsd-9]: rasops.9
src/sys/arch/luna68k/dev [netbsd-9]: omrasops.c
src/sys/dev/rasops [netbsd-9]: README rasops.c rasops.h rasops1.c
rasops15.c rasops1_putchar_width.h rasops2.c rasops24.c rasops32.c
rasops4.c rasops8.c rasops_bitops.h rasops_masks.c rasops_masks.h
rasops_putchar.h rasops_putchar_width.h
src/sys/dev/wscons [netbsd-9]: wsdisplay_vcons.c
src/sys/dev/wsfb [netbsd-9]: genfb.c
Added Files:
src/sys/dev/rasops [netbsd-9]: rasops1-4_putchar.h
Removed Files:
src/sys/dev/rasops [netbsd-9]: rasops_putchar_aa.h

Log Message:
Pull up following revision(s) (requested by rin in ticket #56):

sys/dev/rasops/rasops.c: revision 1.120
sys/dev/rasops/rasops.h: revision 1.40
sys/dev/rasops/rasops.c: revision 1.121
sys/dev/rasops/rasops.h: revision 1.41
sys/dev/rasops/rasops.c: revision 1.122
sys/dev/rasops/rasops.h: revision 1.42
sys/dev/rasops/rasops.h: revision 1.43
sys/dev/rasops/rasops.h: revision 1.44
sys/dev/rasops/rasops.h: revision 1.45
sys/dev/rasops/rasops.h: revision 1.46
sys/dev/rasops/rasops.h: revision 1.47
sys/dev/rasops/rasops.h: revision 1.48
sys/dev/rasops/rasops32.c: revision 1.40
sys/dev/rasops/rasops32.c: revision 1.41
sys/dev/rasops/rasops32.c: revision 1.42
sys/dev/rasops/rasops32.c: revision 1.43
sys/dev/rasops/rasops32.c: revision 1.44
sys/dev/rasops/rasops32.c: revision 1.45
sys/dev/rasops/rasops32.c: revision 1.46
sys/dev/rasops/rasops1-4_putchar.h: revision 1.1
sys/dev/rasops/rasops1-4_putchar.h: revision 1.2
sys/dev/rasops/rasops1-4_putchar.h: revision 1.3
sys/dev/rasops/rasops1_putchar_width.h: revision 1.3
sys/dev/rasops/rasops1_putchar_width.h: revision 1.4
sys/dev/rasops/rasops1_putchar_width.h: revision 1.5
sys/dev/rasops/rasops1_putchar_width.h: revision 1.6
sys/dev/rasops/README: revision 1.7
sys/dev/rasops/rasops_putchar_aa.h: revision 1.5
sys/dev/rasops/rasops_putchar_aa.h: revision 1.6
sys/dev/rasops/rasops8.c: revision 1.45
sys/dev/rasops/rasops8.c: revision 1.46
sys/dev/rasops/rasops8.c: revision 1.47
sys/dev/rasops/rasops24.c: revision 1.40
sys/dev/rasops/rasops8.c: revision 1.48
sys/dev/rasops/rasops24.c: revision 1.41
sys/dev/rasops/rasops8.c: revision 1.49
sys/dev/rasops/rasops24.c: revision 1.42
sys/dev/rasops/rasops24.c: revision 1.43
sys/dev/rasops/rasops24.c: revision 1.44
sys/dev/rasops/rasops_masks.c: revision 1.10
doc/CHANGES: revision 1.2566
sys/dev/rasops/rasops24.c: revision 1.45
doc/CHANGES: revision 1.2567
sys/dev/rasops/rasops24.c: revision 1.46
sys/dev/rasops/rasops24.c: revision 1.47
sys/dev/rasops/rasops24.c: revision 1.48
sys/dev/rasops/rasops24.c: revision 1.49
sys/dev/rasops/rasops_bitops.h: revision 1.19
sys/dev/rasops/rasops_putchar_aa.h: file removal
sys/dev/wscons/wsdisplay_vcons.c: revision 1.40
sys/dev/rasops/rasops8.c: revision 1.50
sys/dev/rasops/rasops8.c: revision 1.51
sys/dev/rasops/rasops24.c: revision 1.50
sys/arch/luna68k/dev/omrasops.c: revision 1.21
sys/dev/rasops/rasops_bitops.h: revision 1.20
sys/dev/wsfb/genfb.c: revision 1.68
sys/dev/rasops/rasops_bitops.h: revision 1.21
sys/dev/wsfb/genfb.c: revision 1.69
sys/dev/rasops/rasops_putchar_width.h: revision 1.10
sys/dev/rasops/rasops_bitops.h: revision 1.22
sys/dev/rasops/rasops_putchar_width.h: revision 1.11
sys/dev/rasops/rasops_bitops.h: revision 1.23
sys/dev/rasops/rasops_putchar_width.h: revision 1.12
sys/dev/rasops/rasops_bitops.h: revision 1.24
sys/dev/rasops/rasops_putchar_width.h: revision 1.13
sys/dev/rasops/rasops_bitops.h: revision 1.25
sys/dev/rasops/rasops_putchar_width.h: revision 1.14
sys/dev/rasops/rasops_putchar_width.h: revision 1.15
sys/dev/rasops/rasops1.c: revision 1.32
sys/dev/rasops/rasops1.c: revision 1.33
sys/dev/rasops/rasops1.c: revision 1.34
sys/dev/rasops/rasops1.c: revision 1.35
sys/dev/rasops/rasops1.c: revision 1.36
sys/dev/rasops/rasops1.c: revision 1.37
sys/dev/rasops/rasops4.c: revision 1.21
sys/dev/rasops/rasops4.c: revision 1.22
sys/dev/rasops/rasops4.c: revision 1.23
sys/dev/rasops/rasops4.c: revision 1.24
sys/dev/rasops/rasops4.c: revision 1.25
sys/dev/rasops/rasops4.c: revision 1.26
sys/dev/rasops/rasops4.c: revision 1.27
sys/dev/rasops/rasops4.c: revision 1.28

CVS commit: [netbsd-9] src

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 12:21:28 UTC 2019

Modified Files:
src/share/man/man9 [netbsd-9]: rasops.9
src/sys/arch/luna68k/dev [netbsd-9]: omrasops.c
src/sys/dev/rasops [netbsd-9]: README rasops.c rasops.h rasops1.c
rasops15.c rasops1_putchar_width.h rasops2.c rasops24.c rasops32.c
rasops4.c rasops8.c rasops_bitops.h rasops_masks.c rasops_masks.h
rasops_putchar.h rasops_putchar_width.h
src/sys/dev/wscons [netbsd-9]: wsdisplay_vcons.c
src/sys/dev/wsfb [netbsd-9]: genfb.c
Added Files:
src/sys/dev/rasops [netbsd-9]: rasops1-4_putchar.h
Removed Files:
src/sys/dev/rasops [netbsd-9]: rasops_putchar_aa.h

Log Message:
Pull up following revision(s) (requested by rin in ticket #56):

sys/dev/rasops/rasops.c: revision 1.120
sys/dev/rasops/rasops.h: revision 1.40
sys/dev/rasops/rasops.c: revision 1.121
sys/dev/rasops/rasops.h: revision 1.41
sys/dev/rasops/rasops.c: revision 1.122
sys/dev/rasops/rasops.h: revision 1.42
sys/dev/rasops/rasops.h: revision 1.43
sys/dev/rasops/rasops.h: revision 1.44
sys/dev/rasops/rasops.h: revision 1.45
sys/dev/rasops/rasops.h: revision 1.46
sys/dev/rasops/rasops.h: revision 1.47
sys/dev/rasops/rasops.h: revision 1.48
sys/dev/rasops/rasops32.c: revision 1.40
sys/dev/rasops/rasops32.c: revision 1.41
sys/dev/rasops/rasops32.c: revision 1.42
sys/dev/rasops/rasops32.c: revision 1.43
sys/dev/rasops/rasops32.c: revision 1.44
sys/dev/rasops/rasops32.c: revision 1.45
sys/dev/rasops/rasops32.c: revision 1.46
sys/dev/rasops/rasops1-4_putchar.h: revision 1.1
sys/dev/rasops/rasops1-4_putchar.h: revision 1.2
sys/dev/rasops/rasops1-4_putchar.h: revision 1.3
sys/dev/rasops/rasops1_putchar_width.h: revision 1.3
sys/dev/rasops/rasops1_putchar_width.h: revision 1.4
sys/dev/rasops/rasops1_putchar_width.h: revision 1.5
sys/dev/rasops/rasops1_putchar_width.h: revision 1.6
sys/dev/rasops/README: revision 1.7
sys/dev/rasops/rasops_putchar_aa.h: revision 1.5
sys/dev/rasops/rasops_putchar_aa.h: revision 1.6
sys/dev/rasops/rasops8.c: revision 1.45
sys/dev/rasops/rasops8.c: revision 1.46
sys/dev/rasops/rasops8.c: revision 1.47
sys/dev/rasops/rasops24.c: revision 1.40
sys/dev/rasops/rasops8.c: revision 1.48
sys/dev/rasops/rasops24.c: revision 1.41
sys/dev/rasops/rasops8.c: revision 1.49
sys/dev/rasops/rasops24.c: revision 1.42
sys/dev/rasops/rasops24.c: revision 1.43
sys/dev/rasops/rasops24.c: revision 1.44
sys/dev/rasops/rasops_masks.c: revision 1.10
doc/CHANGES: revision 1.2566
sys/dev/rasops/rasops24.c: revision 1.45
doc/CHANGES: revision 1.2567
sys/dev/rasops/rasops24.c: revision 1.46
sys/dev/rasops/rasops24.c: revision 1.47
sys/dev/rasops/rasops24.c: revision 1.48
sys/dev/rasops/rasops24.c: revision 1.49
sys/dev/rasops/rasops_bitops.h: revision 1.19
sys/dev/rasops/rasops_putchar_aa.h: file removal
sys/dev/wscons/wsdisplay_vcons.c: revision 1.40
sys/dev/rasops/rasops8.c: revision 1.50
sys/dev/rasops/rasops8.c: revision 1.51
sys/dev/rasops/rasops24.c: revision 1.50
sys/arch/luna68k/dev/omrasops.c: revision 1.21
sys/dev/rasops/rasops_bitops.h: revision 1.20
sys/dev/wsfb/genfb.c: revision 1.68
sys/dev/rasops/rasops_bitops.h: revision 1.21
sys/dev/wsfb/genfb.c: revision 1.69
sys/dev/rasops/rasops_putchar_width.h: revision 1.10
sys/dev/rasops/rasops_bitops.h: revision 1.22
sys/dev/rasops/rasops_putchar_width.h: revision 1.11
sys/dev/rasops/rasops_bitops.h: revision 1.23
sys/dev/rasops/rasops_putchar_width.h: revision 1.12
sys/dev/rasops/rasops_bitops.h: revision 1.24
sys/dev/rasops/rasops_putchar_width.h: revision 1.13
sys/dev/rasops/rasops_bitops.h: revision 1.25
sys/dev/rasops/rasops_putchar_width.h: revision 1.14
sys/dev/rasops/rasops_putchar_width.h: revision 1.15
sys/dev/rasops/rasops1.c: revision 1.32
sys/dev/rasops/rasops1.c: revision 1.33
sys/dev/rasops/rasops1.c: revision 1.34
sys/dev/rasops/rasops1.c: revision 1.35
sys/dev/rasops/rasops1.c: revision 1.36
sys/dev/rasops/rasops1.c: revision 1.37
sys/dev/rasops/rasops4.c: revision 1.21
sys/dev/rasops/rasops4.c: revision 1.22
sys/dev/rasops/rasops4.c: revision 1.23
sys/dev/rasops/rasops4.c: revision 1.24
sys/dev/rasops/rasops4.c: revision 1.25
sys/dev/rasops/rasops4.c: revision 1.26
sys/dev/rasops/rasops4.c: revision 1.27
sys/dev/rasops/rasops4.c: revision 1.28

CVS commit: src/sys/kern

2019-08-15 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Thu Aug 15 12:06:42 UTC 2019

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

Log Message:
Retire KMEM_GUARD. It has been superseded by kASan, which is much more
powerful, has much more coverage - far beyond just kmem(9) -, and also
consumes less memory.

KMEM_GUARD was a debug-only option that required special DDB tweaking, and
had no use in releases or even diagnostic kernels.

As a general rule, the policy now is to harden the pool layer by default
in GENERIC, and use kASan as a diagnostic/debug/fuzzing feature to verify
each memory allocation & access in the system.


To generate a diff of this commit:
cvs rdiff -u -r1.75 -r1.76 src/sys/kern/subr_kmem.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

2019-08-15 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Thu Aug 15 12:06:42 UTC 2019

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

Log Message:
Retire KMEM_GUARD. It has been superseded by kASan, which is much more
powerful, has much more coverage - far beyond just kmem(9) -, and also
consumes less memory.

KMEM_GUARD was a debug-only option that required special DDB tweaking, and
had no use in releases or even diagnostic kernels.

As a general rule, the policy now is to harden the pool layer by default
in GENERIC, and use kASan as a diagnostic/debug/fuzzing feature to verify
each memory allocation & access in the system.


To generate a diff of this commit:
cvs rdiff -u -r1.75 -r1.76 src/sys/kern/subr_kmem.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/subr_kmem.c
diff -u src/sys/kern/subr_kmem.c:1.75 src/sys/kern/subr_kmem.c:1.76
--- src/sys/kern/subr_kmem.c:1.75	Sun Apr  7 09:20:04 2019
+++ src/sys/kern/subr_kmem.c	Thu Aug 15 12:06:42 2019
@@ -1,6 +1,6 @@
-/*	$NetBSD: subr_kmem.c,v 1.75 2019/04/07 09:20:04 maxv Exp $	*/
+/*	$NetBSD: subr_kmem.c,v 1.76 2019/08/15 12:06:42 maxv Exp $	*/
 
-/*-
+/*
  * Copyright (c) 2009-2015 The NetBSD Foundation, Inc.
  * All rights reserved.
  *
@@ -29,7 +29,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 
-/*-
+/*
  * Copyright (c)2006 YAMAMOTO Takashi,
  * All rights reserved.
  *
@@ -66,7 +66,7 @@
  *	the exact user-requested allocation size in it. When freeing, compare
  *	it with kmem_free's "size" argument.
  *
- * This option enabled on DIAGNOSTIC.
+ * This option is enabled on DIAGNOSTIC.
  *
  *  |CHUNK|CHUNK|CHUNK|CHUNK|CHUNK|CHUNK|CHUNK|CHUNK|CHUNK|CHUNK|
  *  +-+-+-+-+-+-+-+-+-+---+-+
@@ -77,22 +77,8 @@
  *  |Size |Buffer usable by the caller (requested size)   |Unused\
  */
 
-/*
- * KMEM_GUARD
- *	A kernel with "option DEBUG" has "kmem_guard" debugging feature compiled
- *	in. See the comment below for what kind of bugs it tries to detect. Even
- *	if compiled in, it's disabled by default because it's very expensive.
- *	You can enable it on boot by:
- *		boot -d
- *		db> w kmem_guard_depth 0t3
- *		db> c
- *
- *	The default value of kmem_guard_depth is 0, which means disabled.
- *	It can be changed by KMEM_GUARD_DEPTH kernel config option.
- */
-
 #include 
-__KERNEL_RCSID(0, "$NetBSD: subr_kmem.c,v 1.75 2019/04/07 09:20:04 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_kmem.c,v 1.76 2019/08/15 12:06:42 maxv Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_kmem.h"
@@ -177,8 +163,6 @@ static size_t kmem_cache_big_maxidx __re
 #endif
 
 #if defined(DEBUG) && defined(_HARDKERNEL)
-#define	KMEM_SIZE
-#define	KMEM_GUARD
 static void *kmem_freecheck;
 #endif
 
@@ -195,31 +179,12 @@ static void kmem_size_check(void *, size
 #define	kmem_size_check(p, sz)	/* nothing */
 #endif
 
-#if defined(KMEM_GUARD)
-#ifndef KMEM_GUARD_DEPTH
-#define KMEM_GUARD_DEPTH 0
-#endif
-struct kmem_guard {
-	u_int		kg_depth;
-	intptr_t *	kg_fifo;
-	u_int		kg_rotor;
-	vmem_t *	kg_vmem;
-};
-static bool kmem_guard_init(struct kmem_guard *, u_int, vmem_t *);
-static void *kmem_guard_alloc(struct kmem_guard *, size_t, bool);
-static void kmem_guard_free(struct kmem_guard *, size_t, void *);
-int kmem_guard_depth = KMEM_GUARD_DEPTH;
-static bool kmem_guard_enabled;
-static struct kmem_guard kmem_guard;
-#endif /* defined(KMEM_GUARD) */
-
 CTASSERT(KM_SLEEP == PR_WAITOK);
 CTASSERT(KM_NOSLEEP == PR_NOWAIT);
 
 /*
  * kmem_intr_alloc: allocate wired memory.
  */
-
 void *
 kmem_intr_alloc(size_t requested_size, km_flag_t kmflags)
 {
@@ -236,13 +201,6 @@ kmem_intr_alloc(size_t requested_size, k
 	KASSERT((kmflags & KM_SLEEP) || (kmflags & KM_NOSLEEP));
 	KASSERT(!(kmflags & KM_SLEEP) || !(kmflags & KM_NOSLEEP));
 
-#ifdef KMEM_GUARD
-	if (kmem_guard_enabled) {
-		return kmem_guard_alloc(_guard, requested_size,
-		(kmflags & KM_SLEEP) != 0);
-	}
-#endif
-
 	kasan_add_redzone(_size);
 	size = kmem_roundup_size(requested_size);
 	allocsz = size + SIZE_SIZE;
@@ -280,7 +238,6 @@ kmem_intr_alloc(size_t requested_size, k
 /*
  * kmem_intr_zalloc: allocate zeroed wired memory.
  */
-
 void *
 kmem_intr_zalloc(size_t size, km_flag_t kmflags)
 {
@@ -296,7 +253,6 @@ kmem_intr_zalloc(size_t size, km_flag_t 
 /*
  * kmem_intr_free: free wired memory allocated by kmem_alloc.
  */
-
 void
 kmem_intr_free(void *p, size_t requested_size)
 {
@@ -307,13 +263,6 @@ kmem_intr_free(void *p, size_t requested
 	KASSERT(p != NULL);
 	KASSERT(requested_size > 0);
 
-#ifdef KMEM_GUARD
-	if (kmem_guard_enabled) {
-		kmem_guard_free(_guard, requested_size, p);
-		return;
-	}
-#endif
-
 	kasan_add_redzone(_size);
 	size = kmem_roundup_size(requested_size);
 	allocsz = size + SIZE_SIZE;
@@ -341,13 +290,12 @@ kmem_intr_free(void *p, size_t requested
 	pool_cache_put(pc, p);
 }
 
-/*  kmem API */
+/*  Kmem API 

CVS commit: src/usr.sbin/makemandb

2019-08-15 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Thu Aug 15 10:29:07 UTC 2019

Modified Files:
src/usr.sbin/makemandb: apropos-utils.c

Log Message:
PR/54343: Prevent NULL pointers in callback strings; use "*?*" for now to
identify them.


To generate a diff of this commit:
cvs rdiff -u -r1.45 -r1.46 src/usr.sbin/makemandb/apropos-utils.c

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



CVS commit: src/usr.sbin/makemandb

2019-08-15 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Thu Aug 15 10:29:07 UTC 2019

Modified Files:
src/usr.sbin/makemandb: apropos-utils.c

Log Message:
PR/54343: Prevent NULL pointers in callback strings; use "*?*" for now to
identify them.


To generate a diff of this commit:
cvs rdiff -u -r1.45 -r1.46 src/usr.sbin/makemandb/apropos-utils.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/makemandb/apropos-utils.c
diff -u src/usr.sbin/makemandb/apropos-utils.c:1.45 src/usr.sbin/makemandb/apropos-utils.c:1.46
--- src/usr.sbin/makemandb/apropos-utils.c:1.45	Fri Jun  7 12:43:58 2019
+++ src/usr.sbin/makemandb/apropos-utils.c	Thu Aug 15 06:29:07 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: apropos-utils.c,v 1.45 2019/06/07 16:43:58 leot Exp $	*/
+/*	$NetBSD: apropos-utils.c,v 1.46 2019/08/15 10:29:07 christos Exp $	*/
 /*-
  * Copyright (c) 2011 Abhinav Upadhyay 
  * All rights reserved.
@@ -31,7 +31,7 @@
  */
 
 #include 
-__RCSID("$NetBSD: apropos-utils.c,v 1.45 2019/06/07 16:43:58 leot Exp $");
+__RCSID("$NetBSD: apropos-utils.c,v 1.46 2019/08/15 10:29:07 christos Exp $");
 
 #include 
 #include 
@@ -654,6 +654,13 @@ RETURN:
 	return query;
 }
 
+static const char *
+get_stmt_col_text(sqlite3_stmt *stmt, int col)
+{
+	const char *t = (const char *) sqlite3_column_text(stmt, col);
+	return t == NULL ? "*?*" : t;
+}
+
 /*
  * Execute the full text search query and return the number of results
  * obtained.
@@ -695,13 +702,14 @@ execute_search_query(sqlite3 *db, char *
 	unsigned int nresults = 0;
 	while (sqlite3_step(stmt) == SQLITE_ROW) {
 		nresults++;
-		callback_args.section = (const char *) sqlite3_column_text(stmt, 0);
-		name_temp = (const char *) sqlite3_column_text(stmt, 1);
-		callback_args.name_desc = (const char *) sqlite3_column_text(stmt, 2);
-		callback_args.machine = (const char *) sqlite3_column_text(stmt, 3);
+		callback_args.section = get_stmt_col_text(stmt, 0);
+		name_temp = get_stmt_col_text(stmt, 1);
+		callback_args.name_desc = get_stmt_col_text(stmt, 2);
+		callback_args.machine = get_stmt_col_text(stmt, 3);
 		if (!args->legacy) {
-			callback_args.snippet = (const char *) sqlite3_column_text(stmt, 4);
-			callback_args.snippet_length = strlen(callback_args.snippet);
+			callback_args.snippet = get_stmt_col_text(stmt, 4);
+			callback_args.snippet_length =
+			strlen(callback_args.snippet);
 		} else {
 			callback_args.snippet = "";
 			callback_args.snippet_length = 1;
@@ -713,8 +721,7 @@ execute_search_query(sqlite3 *db, char *
 			easprintf(, "%s/%s", lower(m), name_temp);
 			free(m);
 		} else {
-			name = estrdup((const char *)
-			sqlite3_column_text(stmt, 1));
+			name = estrdup(get_stmt_col_text(stmt, 1));
 		}
 		callback_args.name = name;
 		callback_args.other_data = args->callback_data;



CVS commit: src/sys/arch/aarch64/aarch64

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 10:24:26 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: pmap.c

Log Message:
Make pmap_db_pte_print more terse so it's quicker on serial consoles


To generate a diff of this commit:
cvs rdiff -u -r1.42 -r1.43 src/sys/arch/aarch64/aarch64/pmap.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/aarch64/aarch64

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 10:24:26 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: pmap.c

Log Message:
Make pmap_db_pte_print more terse so it's quicker on serial consoles


To generate a diff of this commit:
cvs rdiff -u -r1.42 -r1.43 src/sys/arch/aarch64/aarch64/pmap.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/aarch64/aarch64/pmap.c
diff -u src/sys/arch/aarch64/aarch64/pmap.c:1.42 src/sys/arch/aarch64/aarch64/pmap.c:1.43
--- src/sys/arch/aarch64/aarch64/pmap.c:1.42	Mon Aug 12 10:28:04 2019
+++ src/sys/arch/aarch64/aarch64/pmap.c	Thu Aug 15 10:24:26 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.42 2019/08/12 10:28:04 skrll Exp $	*/
+/*	$NetBSD: pmap.c,v 1.43 2019/08/15 10:24:26 skrll Exp $	*/
 
 /*
  * Copyright (c) 2017 Ryo Shimizu 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.42 2019/08/12 10:28:04 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.43 2019/08/15 10:24:26 skrll Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_ddb.h"
@@ -2366,11 +2366,9 @@ pmap_db_pte_print(pt_entry_t pte, int le
 		pr(", PA=%lx", l3pte_pa(pte));
 
 		pr(", %s", (pte & LX_BLKPAG_UXN) ?
-		"UXN  " :
-		"user-exec");
+		"UXN" : "UX ");
 		pr(", %s", (pte & LX_BLKPAG_PXN) ?
-		   "PXN" :
-		   "kernel-exec");
+		   "PXN" :  "PX ");
 
 		if (pte & LX_BLKPAG_CONTIG)
 			pr(", CONTIG");
@@ -2401,13 +2399,13 @@ pmap_db_pte_print(pt_entry_t pte, int le
 
 		switch (pte & LX_BLKPAG_ATTR_MASK) {
 		case LX_BLKPAG_ATTR_NORMAL_WB:
-			pr(", WRITEBACK");
+			pr(", WB");
 			break;
 		case LX_BLKPAG_ATTR_NORMAL_NC:
-			pr(", NOCACHE");
+			pr(", NC");
 			break;
 		case LX_BLKPAG_ATTR_NORMAL_WT:
-			pr(", WHITETHRU");
+			pr(", WT");
 			break;
 		case LX_BLKPAG_ATTR_DEVICE_MEM:
 			pr(", DEVICE");
@@ -2421,7 +2419,7 @@ pmap_db_pte_print(pt_entry_t pte, int le
 		if (pte & LX_BLKPAG_OS_WRITE)
 			pr(", pmap_write");
 		if (pte & LX_BLKPAG_OS_WIRED)
-			pr(", pmap_wired");
+			pr(", wired");
 	} else {
 		pr(" **ILLEGAL TYPE**");
 	}



CVS commit: [netbsd-9] src/doc

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 09:51:13 UTC 2019

Modified Files:
src/doc [netbsd-9]: CHANGES-9.0

Log Message:
Ticket #55


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.16 -r1.1.2.17 src/doc/CHANGES-9.0

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



CVS commit: [netbsd-9] src/doc

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 09:51:13 UTC 2019

Modified Files:
src/doc [netbsd-9]: CHANGES-9.0

Log Message:
Ticket #55


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.16 -r1.1.2.17 src/doc/CHANGES-9.0

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

Modified files:

Index: src/doc/CHANGES-9.0
diff -u src/doc/CHANGES-9.0:1.1.2.16 src/doc/CHANGES-9.0:1.1.2.17
--- src/doc/CHANGES-9.0:1.1.2.16	Tue Aug 13 14:59:01 2019
+++ src/doc/CHANGES-9.0	Thu Aug 15 09:51:12 2019
@@ -1,4 +1,4 @@
-# $NetBSD: CHANGES-9.0,v 1.1.2.16 2019/08/13 14:59:01 martin Exp $
+# $NetBSD: CHANGES-9.0,v 1.1.2.17 2019/08/15 09:51:12 martin Exp $
 
 A complete list of changes from the initial NetBSD 9.0 branch on 2019-07-30
 until the 9.0 release:
@@ -1694,3 +1694,39 @@ sys/arch/arm/include/armreg.h			1.128
 	Add support for physical timers and sprinkle isb where needed.
 	[jmcneill, ticket #54]
 
+sys/arch/arm/amlogic/meson8b_clkc.c		1.4
+sys/arch/arm/amlogic/meson8b_pinctrl.c		1.2
+sys/arch/arm/amlogic/meson_platform.c		1.12,1.13
+sys/arch/arm/cortex/a9ptmr.c			1.1,1.2
+sys/arch/arm/cortex/a9ptmr_var.h		1.1
+sys/arch/arm/cortex/a9tmr_var.h			1.7
+sys/arch/arm/cortex/a9wdt.c			1.9,1.10
+sys/arch/arm/cortex/files.cortex		1.12
+sys/arch/arm/dts/meson8b-odroidc1.dts		1.4
+sys/arch/arm/dts/meson8b.dtsi			1.6,1.7
+sys/arch/arm/fdt/a9ptmr_fdt.c			1.1
+sys/arch/arm/fdt/a9wdt_fdt.c			1.1
+sys/arch/arm/fdt/files.fdt			1.29
+sys/arch/evbarm/conf/BCM5301X			1.34
+sys/arch/evbarm/conf/BCM56340			1.19
+sys/arch/evbarm/conf/CUBOX-I			1.23
+sys/arch/evbarm/conf/DUOVERO			1.14
+sys/arch/evbarm/conf/GENERIC			1.50
+sys/arch/evbarm/conf/HUMMINGBOARD		1.9
+sys/arch/evbarm/conf/NITROGEN6X			1.24
+sys/arch/evbarm/conf/PANDABOARD			1.30
+sys/arch/evbarm/conf/PARALLELLA			1.7
+sys/arch/evbarm/conf/ZEDBOARD			1.6
+
+	Catch up to recent mainline dts changes.
+	Add a driver for the A5/A9 Private timer.
+	FDTise the Watchdog driver.
+	Update for recent a9wdt changes.
+	Updates to get Odroid-C1 in better shape since the last DTS import.
+	Add eth_rxd3 and eth_rxd2 pinctrl groups.
+	a9ptmr.c:
+	- don't use prescaler
+	- improve AB_DEBUG output
+	- fix a9ptmr_delay to work with a decrementing counter!
+	[skrll, ticket #55]
+



CVS commit: [netbsd-9] src/sys/arch

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 09:49:49 UTC 2019

Modified Files:
src/sys/arch/arm/amlogic [netbsd-9]: meson8b_clkc.c meson8b_pinctrl.c
meson_platform.c
src/sys/arch/arm/cortex [netbsd-9]: a9tmr_var.h a9wdt.c files.cortex
src/sys/arch/arm/dts [netbsd-9]: meson8b-odroidc1.dts meson8b.dtsi
src/sys/arch/arm/fdt [netbsd-9]: files.fdt
src/sys/arch/evbarm/conf [netbsd-9]: BCM5301X BCM56340 CUBOX-I DUOVERO
GENERIC HUMMINGBOARD NITROGEN6X PANDABOARD PARALLELLA ZEDBOARD
Added Files:
src/sys/arch/arm/cortex [netbsd-9]: a9ptmr.c a9ptmr_var.h
src/sys/arch/arm/fdt [netbsd-9]: a9ptmr_fdt.c a9wdt_fdt.c

Log Message:
Pull up following revision(s) (requested by skrll in ticket #55):

sys/arch/arm/cortex/a9wdt.c: revision 1.10
sys/arch/evbarm/conf/HUMMINGBOARD: revision 1.9
sys/arch/evbarm/conf/GENERIC: revision 1.50
sys/arch/evbarm/conf/NITROGEN6X: revision 1.24
sys/arch/arm/cortex/a9tmr_var.h: revision 1.7
sys/arch/arm/fdt/files.fdt: revision 1.29
sys/arch/arm/amlogic/meson_platform.c: revision 1.12
sys/arch/arm/amlogic/meson8b_pinctrl.c: revision 1.2
sys/arch/arm/amlogic/meson_platform.c: revision 1.13
sys/arch/evbarm/conf/BCM5301X: revision 1.34
sys/arch/arm/dts/meson8b.dtsi: revision 1.6
sys/arch/arm/fdt/a9ptmr_fdt.c: revision 1.1
sys/arch/arm/dts/meson8b.dtsi: revision 1.7
sys/arch/arm/cortex/a9ptmr_var.h: revision 1.1
sys/arch/evbarm/conf/PANDABOARD: revision 1.30
sys/arch/evbarm/conf/DUOVERO: revision 1.14
sys/arch/arm/cortex/a9ptmr.c: revision 1.1
sys/arch/arm/cortex/a9ptmr.c: revision 1.2
sys/arch/arm/fdt/a9wdt_fdt.c: revision 1.1
sys/arch/evbarm/conf/BCM56340: revision 1.19
sys/arch/evbarm/conf/CUBOX-I: revision 1.23
sys/arch/arm/amlogic/meson8b_clkc.c: revision 1.4
sys/arch/evbarm/conf/PARALLELLA: revision 1.7
sys/arch/arm/cortex/files.cortex: revision 1.12
sys/arch/arm/dts/meson8b-odroidc1.dts: revision 1.4
sys/arch/arm/cortex/a9wdt.c: revision 1.9
sys/arch/evbarm/conf/ZEDBOARD: revision 1.6

spaces to tab

 -

Add a driver for the A5/A9 Private timer.
While here FDTise the Watchdog driver.

 -

Update for recent a9wdt changes
 -

Trailing whitespace

 -
Updates to get Odroid-C1 in better shape since the last DTS import

 -

Various fixes / changes
- don't use prescaler
- improve AB_DEBUG output
- fix a9ptmr_delay to work with a decrementing counter!
Thanks to jmcneill@ for proving I'm an idiot

 -

Add eth_rxd3 and eth_rxd2 pinctrl groups

 -

Catch up to recent mainline dts changes


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.3.6.1 src/sys/arch/arm/amlogic/meson8b_clkc.c
cvs rdiff -u -r1.1 -r1.1.8.1 src/sys/arch/arm/amlogic/meson8b_pinctrl.c
cvs rdiff -u -r1.11 -r1.11.4.1 src/sys/arch/arm/amlogic/meson_platform.c
cvs rdiff -u -r0 -r1.2.2.2 src/sys/arch/arm/cortex/a9ptmr.c
cvs rdiff -u -r0 -r1.1.2.2 src/sys/arch/arm/cortex/a9ptmr_var.h
cvs rdiff -u -r1.6 -r1.6.6.1 src/sys/arch/arm/cortex/a9tmr_var.h
cvs rdiff -u -r1.8 -r1.8.2.1 src/sys/arch/arm/cortex/a9wdt.c
cvs rdiff -u -r1.11 -r1.11.4.1 src/sys/arch/arm/cortex/files.cortex
cvs rdiff -u -r1.3 -r1.3.8.1 src/sys/arch/arm/dts/meson8b-odroidc1.dts
cvs rdiff -u -r1.5 -r1.5.8.1 src/sys/arch/arm/dts/meson8b.dtsi
cvs rdiff -u -r0 -r1.1.2.2 src/sys/arch/arm/fdt/a9ptmr_fdt.c \
src/sys/arch/arm/fdt/a9wdt_fdt.c
cvs rdiff -u -r1.28 -r1.28.4.1 src/sys/arch/arm/fdt/files.fdt
cvs rdiff -u -r1.33 -r1.33.4.1 src/sys/arch/evbarm/conf/BCM5301X
cvs rdiff -u -r1.18 -r1.18.4.1 src/sys/arch/evbarm/conf/BCM56340
cvs rdiff -u -r1.22 -r1.22.2.1 src/sys/arch/evbarm/conf/CUBOX-I
cvs rdiff -u -r1.13 -r1.13.2.1 src/sys/arch/evbarm/conf/DUOVERO
cvs rdiff -u -r1.48 -r1.48.2.1 src/sys/arch/evbarm/conf/GENERIC
cvs rdiff -u -r1.8 -r1.8.2.1 src/sys/arch/evbarm/conf/HUMMINGBOARD
cvs rdiff -u -r1.23 -r1.23.2.1 src/sys/arch/evbarm/conf/NITROGEN6X
cvs rdiff -u -r1.29 -r1.29.2.1 src/sys/arch/evbarm/conf/PANDABOARD
cvs rdiff -u -r1.6 -r1.6.4.1 src/sys/arch/evbarm/conf/PARALLELLA
cvs rdiff -u -r1.5 -r1.5.4.1 src/sys/arch/evbarm/conf/ZEDBOARD

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/amlogic/meson8b_clkc.c
diff -u src/sys/arch/arm/amlogic/meson8b_clkc.c:1.3 src/sys/arch/arm/amlogic/meson8b_clkc.c:1.3.6.1
--- src/sys/arch/arm/amlogic/meson8b_clkc.c:1.3	Mon Feb 25 19:30:17 2019
+++ src/sys/arch/arm/amlogic/meson8b_clkc.c	Thu Aug 15 09:49:49 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: meson8b_clkc.c,v 1.3 2019/02/25 19:30:17 jmcneill Exp $ */
+/* $NetBSD: meson8b_clkc.c,v 1.3.6.1 2019/08/15 09:49:49 martin Exp $ */
 
 /*-
  * Copyright (c) 2019 Jared McNeill 
@@ -28,7 +28,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: meson8b_clkc.c,v 1.3 2019/02/25 

CVS commit: [netbsd-9] src/sys/arch

2019-08-15 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 15 09:49:49 UTC 2019

Modified Files:
src/sys/arch/arm/amlogic [netbsd-9]: meson8b_clkc.c meson8b_pinctrl.c
meson_platform.c
src/sys/arch/arm/cortex [netbsd-9]: a9tmr_var.h a9wdt.c files.cortex
src/sys/arch/arm/dts [netbsd-9]: meson8b-odroidc1.dts meson8b.dtsi
src/sys/arch/arm/fdt [netbsd-9]: files.fdt
src/sys/arch/evbarm/conf [netbsd-9]: BCM5301X BCM56340 CUBOX-I DUOVERO
GENERIC HUMMINGBOARD NITROGEN6X PANDABOARD PARALLELLA ZEDBOARD
Added Files:
src/sys/arch/arm/cortex [netbsd-9]: a9ptmr.c a9ptmr_var.h
src/sys/arch/arm/fdt [netbsd-9]: a9ptmr_fdt.c a9wdt_fdt.c

Log Message:
Pull up following revision(s) (requested by skrll in ticket #55):

sys/arch/arm/cortex/a9wdt.c: revision 1.10
sys/arch/evbarm/conf/HUMMINGBOARD: revision 1.9
sys/arch/evbarm/conf/GENERIC: revision 1.50
sys/arch/evbarm/conf/NITROGEN6X: revision 1.24
sys/arch/arm/cortex/a9tmr_var.h: revision 1.7
sys/arch/arm/fdt/files.fdt: revision 1.29
sys/arch/arm/amlogic/meson_platform.c: revision 1.12
sys/arch/arm/amlogic/meson8b_pinctrl.c: revision 1.2
sys/arch/arm/amlogic/meson_platform.c: revision 1.13
sys/arch/evbarm/conf/BCM5301X: revision 1.34
sys/arch/arm/dts/meson8b.dtsi: revision 1.6
sys/arch/arm/fdt/a9ptmr_fdt.c: revision 1.1
sys/arch/arm/dts/meson8b.dtsi: revision 1.7
sys/arch/arm/cortex/a9ptmr_var.h: revision 1.1
sys/arch/evbarm/conf/PANDABOARD: revision 1.30
sys/arch/evbarm/conf/DUOVERO: revision 1.14
sys/arch/arm/cortex/a9ptmr.c: revision 1.1
sys/arch/arm/cortex/a9ptmr.c: revision 1.2
sys/arch/arm/fdt/a9wdt_fdt.c: revision 1.1
sys/arch/evbarm/conf/BCM56340: revision 1.19
sys/arch/evbarm/conf/CUBOX-I: revision 1.23
sys/arch/arm/amlogic/meson8b_clkc.c: revision 1.4
sys/arch/evbarm/conf/PARALLELLA: revision 1.7
sys/arch/arm/cortex/files.cortex: revision 1.12
sys/arch/arm/dts/meson8b-odroidc1.dts: revision 1.4
sys/arch/arm/cortex/a9wdt.c: revision 1.9
sys/arch/evbarm/conf/ZEDBOARD: revision 1.6

spaces to tab

 -

Add a driver for the A5/A9 Private timer.
While here FDTise the Watchdog driver.

 -

Update for recent a9wdt changes
 -

Trailing whitespace

 -
Updates to get Odroid-C1 in better shape since the last DTS import

 -

Various fixes / changes
- don't use prescaler
- improve AB_DEBUG output
- fix a9ptmr_delay to work with a decrementing counter!
Thanks to jmcneill@ for proving I'm an idiot

 -

Add eth_rxd3 and eth_rxd2 pinctrl groups

 -

Catch up to recent mainline dts changes


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.3.6.1 src/sys/arch/arm/amlogic/meson8b_clkc.c
cvs rdiff -u -r1.1 -r1.1.8.1 src/sys/arch/arm/amlogic/meson8b_pinctrl.c
cvs rdiff -u -r1.11 -r1.11.4.1 src/sys/arch/arm/amlogic/meson_platform.c
cvs rdiff -u -r0 -r1.2.2.2 src/sys/arch/arm/cortex/a9ptmr.c
cvs rdiff -u -r0 -r1.1.2.2 src/sys/arch/arm/cortex/a9ptmr_var.h
cvs rdiff -u -r1.6 -r1.6.6.1 src/sys/arch/arm/cortex/a9tmr_var.h
cvs rdiff -u -r1.8 -r1.8.2.1 src/sys/arch/arm/cortex/a9wdt.c
cvs rdiff -u -r1.11 -r1.11.4.1 src/sys/arch/arm/cortex/files.cortex
cvs rdiff -u -r1.3 -r1.3.8.1 src/sys/arch/arm/dts/meson8b-odroidc1.dts
cvs rdiff -u -r1.5 -r1.5.8.1 src/sys/arch/arm/dts/meson8b.dtsi
cvs rdiff -u -r0 -r1.1.2.2 src/sys/arch/arm/fdt/a9ptmr_fdt.c \
src/sys/arch/arm/fdt/a9wdt_fdt.c
cvs rdiff -u -r1.28 -r1.28.4.1 src/sys/arch/arm/fdt/files.fdt
cvs rdiff -u -r1.33 -r1.33.4.1 src/sys/arch/evbarm/conf/BCM5301X
cvs rdiff -u -r1.18 -r1.18.4.1 src/sys/arch/evbarm/conf/BCM56340
cvs rdiff -u -r1.22 -r1.22.2.1 src/sys/arch/evbarm/conf/CUBOX-I
cvs rdiff -u -r1.13 -r1.13.2.1 src/sys/arch/evbarm/conf/DUOVERO
cvs rdiff -u -r1.48 -r1.48.2.1 src/sys/arch/evbarm/conf/GENERIC
cvs rdiff -u -r1.8 -r1.8.2.1 src/sys/arch/evbarm/conf/HUMMINGBOARD
cvs rdiff -u -r1.23 -r1.23.2.1 src/sys/arch/evbarm/conf/NITROGEN6X
cvs rdiff -u -r1.29 -r1.29.2.1 src/sys/arch/evbarm/conf/PANDABOARD
cvs rdiff -u -r1.6 -r1.6.4.1 src/sys/arch/evbarm/conf/PARALLELLA
cvs rdiff -u -r1.5 -r1.5.4.1 src/sys/arch/evbarm/conf/ZEDBOARD

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



CVS commit: src/sys/arch/aarch64/include

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 09:07:34 UTC 2019

Modified Files:
src/sys/arch/aarch64/include: pte.h

Log Message:
Indent the field value defines.  NFCI.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/aarch64/include/pte.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/include/pte.h
diff -u src/sys/arch/aarch64/include/pte.h:1.6 src/sys/arch/aarch64/include/pte.h:1.7
--- src/sys/arch/aarch64/include/pte.h:1.6	Tue Aug 13 08:27:42 2019
+++ src/sys/arch/aarch64/include/pte.h	Thu Aug 15 09:07:34 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: pte.h,v 1.6 2019/08/13 08:27:42 skrll Exp $ */
+/* $NetBSD: pte.h,v 1.7 2019/08/15 09:07:34 skrll Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -44,17 +44,17 @@ typedef uint64_t pt_entry_t;	/* L3(4k) t
  */
 #define LX_TBL_NSTABLE		__BIT(63)	/* inherited next level */
 #define LX_TBL_APTABLE		__BITS(62,61)	/* inherited next level */
-#define LX_TBL_APTABLE_NOEFFECT		__SHIFTIN(0,LX_TBL_APTABLE)
-#define LX_TBL_APTABLE_EL0_NOACCESS	__SHIFTIN(1,LX_TBL_APTABLE)
-#define LX_TBL_APTABLE_RO		__SHIFTIN(2,LX_TBL_APTABLE)
-#define LX_TBL_APTABLE_RO_EL0_NOREAD	__SHIFTIN(3,LX_TBL_APTABLE)
+#define  LX_TBL_APTABLE_NOEFFECT	__SHIFTIN(0,LX_TBL_APTABLE)
+#define  LX_TBL_APTABLE_EL0_NOACCESS	__SHIFTIN(1,LX_TBL_APTABLE)
+#define  LX_TBL_APTABLE_RO		__SHIFTIN(2,LX_TBL_APTABLE)
+#define  LX_TBL_APTABLE_RO_EL0_NOREAD	__SHIFTIN(3,LX_TBL_APTABLE)
 #define LX_TBL_UXNTABLE		__BIT(60)	/* inherited next level */
 #define LX_TBL_PXNTABLE		__BIT(59)	/* inherited next level */
 #define LX_BLKPAG_OS		__BITS(58, 55)
-# define LX_BLKPAG_OS_0		__SHIFTIN(1,LX_BLKPAG_OS)
-# define LX_BLKPAG_OS_1		__SHIFTIN(2,LX_BLKPAG_OS)
-# define LX_BLKPAG_OS_2		__SHIFTIN(4,LX_BLKPAG_OS)
-# define LX_BLKPAG_OS_3		__SHIFTIN(8,LX_BLKPAG_OS)
+#define  LX_BLKPAG_OS_0		__SHIFTIN(1,LX_BLKPAG_OS)
+#define  LX_BLKPAG_OS_1		__SHIFTIN(2,LX_BLKPAG_OS)
+#define  LX_BLKPAG_OS_2		__SHIFTIN(4,LX_BLKPAG_OS)
+#define  LX_BLKPAG_OS_3		__SHIFTIN(8,LX_BLKPAG_OS)
 #define LX_BLKPAG_UXN		__BIT(54)	/* Unprivileged Execute Never */
 #define LX_BLKPAG_PXN		__BIT(53)	/* Privileged Execute Never */
 #define LX_BLKPAG_CONTIG	__BIT(52)	/* Hint of TLB cache */
@@ -64,12 +64,12 @@ typedef uint64_t pt_entry_t;	/* L3(4k) t
 #define LX_BLKPAG_NG		__BIT(11)	/* Not Global */
 #define LX_BLKPAG_AF		__BIT(10)	/* Access Flag */
 #define LX_BLKPAG_SH		__BITS(9,8)	/* Shareability */
-#define LX_BLKPAG_SH_NS		__SHIFTIN(0,LX_BLKPAG_SH) /* Non Shareable */
-#define LX_BLKPAG_SH_OS		__SHIFTIN(2,LX_BLKPAG_SH) /* Outer Shareable */
-#define LX_BLKPAG_SH_IS		__SHIFTIN(3,LX_BLKPAG_SH) /* Inner Shareable */
+#define  LX_BLKPAG_SH_NS	__SHIFTIN(0,LX_BLKPAG_SH) /* Non Shareable */
+#define  LX_BLKPAG_SH_OS	__SHIFTIN(2,LX_BLKPAG_SH) /* Outer Shareable */
+#define  LX_BLKPAG_SH_IS	__SHIFTIN(3,LX_BLKPAG_SH) /* Inner Shareable */
 #define LX_BLKPAG_AP		__BIT(7)
-#define LX_BLKPAG_AP_RW		__SHIFTIN(0,LX_BLKPAG_AP) /* RW */
-#define LX_BLKPAG_AP_RO		__SHIFTIN(1,LX_BLKPAG_AP) /* RO */
+#define  LX_BLKPAG_AP_RW	__SHIFTIN(0,LX_BLKPAG_AP) /* RW */
+#define  LX_BLKPAG_AP_RO	__SHIFTIN(1,LX_BLKPAG_AP) /* RO */
 #define LX_BLKPAG_APUSER	__BIT(6)
 #define LX_BLKPAG_NS		__BIT(5)
 #define LX_BLKPAG_ATTR_INDX	__BITS(4,2)	/* refer MAIR_EL1 attr */
@@ -78,9 +78,9 @@ typedef uint64_t pt_entry_t;	/* L3(4k) t
 #define  LX_BLKPAG_ATTR_INDX_2	__SHIFTIN(2,LX_BLKPAG_ATTR_INDX)
 #define  LX_BLKPAG_ATTR_INDX_3	__SHIFTIN(3,LX_BLKPAG_ATTR_INDX)
 #define LX_TYPE			__BIT(1)
-#define LX_TYPE_BLK		__SHIFTIN(0, LX_TYPE)
-#define LX_TYPE_TBL		__SHIFTIN(1, LX_TYPE)
-#define L3_TYPE_PAG		__SHIFTIN(1, LX_TYPE)
+#define  LX_TYPE_BLK		__SHIFTIN(0, LX_TYPE)
+#define  LX_TYPE_TBL		__SHIFTIN(1, LX_TYPE)
+#define  L3_TYPE_PAG		__SHIFTIN(1, LX_TYPE)
 #define LX_VALID		__BIT(0)
 
 #define L1_BLK_OA		__BITS(47, 30)	/* 1GB */
@@ -130,57 +130,57 @@ typedef uint64_t pt_entry_t;	/* L3(4k) t
 
 
 /* TCR_EL1 - Translation Control Register */
-#define TCR_TBI1	__BIT(38)		/* ignore Top Byte TTBR1_EL1 */
-#define TCR_TBI0	__BIT(37)		/* ignore Top Byte TTBR0_EL1 */
-#define TCR_AS64K	__BIT(36)		/* Use 64K ASIDs */
-#define TCR_IPS		__BITS(34,32)		/* Intermediate PhysAdr Size */
-#define TCR_IPS_256TB	__SHIFTIN(5,TCR_IPS)	/* 48 bits (256 TB) */
-#define TCR_IPS_64TB	__SHIFTIN(4,TCR_IPS)	/* 44 bits  (16 TB) */
-#define TCR_IPS_4TB	__SHIFTIN(3,TCR_IPS)	/* 42 bits  ( 4 TB) */
-#define TCR_IPS_1TB	__SHIFTIN(2,TCR_IPS)	/* 40 bits  ( 1 TB) */
-#define TCR_IPS_64GB	__SHIFTIN(1,TCR_IPS)	/* 36 bits  (64 GB) */
-#define TCR_IPS_4GB	__SHIFTIN(0,TCR_IPS)	/* 32 bits   (4 GB) */
-#define TCR_TG1		__BITS(31,30)		/* TTBR1 Page Granule Size */
-#define TCR_TG1_16KB	__SHIFTIN(1,TCR_TG1)	/* 16KB page size */
-#define TCR_TG1_4KB	__SHIFTIN(2,TCR_TG1)	/* 4KB page size */
-#define TCR_TG1_64KB	__SHIFTIN(3,TCR_TG1)	/* 64KB page size */
-#define TCR_SH1		

CVS commit: src/sys/arch/aarch64/include

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 09:07:34 UTC 2019

Modified Files:
src/sys/arch/aarch64/include: pte.h

Log Message:
Indent the field value defines.  NFCI.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/aarch64/include/pte.h

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



CVS commit: src/sys/kern

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 09:04:23 UTC 2019

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

Log Message:
More diagnostic


To generate a diff of this commit:
cvs rdiff -u -r1.88 -r1.89 src/sys/kern/subr_extent.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/subr_extent.c
diff -u src/sys/kern/subr_extent.c:1.88 src/sys/kern/subr_extent.c:1.89
--- src/sys/kern/subr_extent.c:1.88	Thu Aug 15 09:03:09 2019
+++ src/sys/kern/subr_extent.c	Thu Aug 15 09:04:22 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: subr_extent.c,v 1.88 2019/08/15 09:03:09 skrll Exp $	*/
+/*	$NetBSD: subr_extent.c,v 1.89 2019/08/15 09:04:22 skrll Exp $	*/
 
 /*-
  * Copyright (c) 1996, 1998, 2007 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: subr_extent.c,v 1.88 2019/08/15 09:03:09 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_extent.c,v 1.89 2019/08/15 09:04:22 skrll Exp $");
 
 #ifdef _KERNEL
 #ifdef _KERNEL_OPT
@@ -647,6 +647,8 @@ extent_alloc_subregion1(struct extent *e
 	if ((size < 1) || ((size - 1) > (subend - substart))) {
 		printf("extent_alloc_subregion: extent `%s', size 0x%lx\n",
 		ex->ex_name, size);
+		printf("extent_alloc_subregion: substart 0x%lx, subend 0x%lx\n",
+		substart, subend);
 		panic("extent_alloc_subregion: bad size");
 	}
 	if (alignment == 0)



CVS commit: src/sys/kern

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 09:04:23 UTC 2019

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

Log Message:
More diagnostic


To generate a diff of this commit:
cvs rdiff -u -r1.88 -r1.89 src/sys/kern/subr_extent.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

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 09:03:09 UTC 2019

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

Log Message:
Indentation and wrap the resulting long line


To generate a diff of this commit:
cvs rdiff -u -r1.87 -r1.88 src/sys/kern/subr_extent.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/subr_extent.c
diff -u src/sys/kern/subr_extent.c:1.87 src/sys/kern/subr_extent.c:1.88
--- src/sys/kern/subr_extent.c:1.87	Sun Dec 31 09:25:19 2017
+++ src/sys/kern/subr_extent.c	Thu Aug 15 09:03:09 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: subr_extent.c,v 1.87 2017/12/31 09:25:19 skrll Exp $	*/
+/*	$NetBSD: subr_extent.c,v 1.88 2019/08/15 09:03:09 skrll Exp $	*/
 
 /*-
  * Copyright (c) 1996, 1998, 2007 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: subr_extent.c,v 1.87 2017/12/31 09:25:19 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_extent.c,v 1.88 2019/08/15 09:03:09 skrll Exp $");
 
 #ifdef _KERNEL
 #ifdef _KERNEL_OPT
@@ -638,8 +638,8 @@ extent_alloc_subregion1(struct extent *e
 		panic("extent_alloc_subregion: NULL result pointer");
 	if ((substart < ex->ex_start) || (substart > ex->ex_end) ||
 	(subend > ex->ex_end) || (subend < ex->ex_start)) {
-  printf("extent_alloc_subregion: extent `%s', ex_start 0x%lx, ex_end 0x%lx\n",
-		ex->ex_name, ex->ex_start, ex->ex_end);
+  		printf("extent_alloc_subregion: extent `%s', ex_start 0x%lx, "
+		"ex_end 0x%lx\n", ex->ex_name, ex->ex_start, ex->ex_end);
 		printf("extent_alloc_subregion: substart 0x%lx, subend 0x%lx\n",
 		substart, subend);
 		panic("extent_alloc_subregion: bad subregion");



CVS commit: src/sys/kern

2019-08-15 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Aug 15 09:03:09 UTC 2019

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

Log Message:
Indentation and wrap the resulting long line


To generate a diff of this commit:
cvs rdiff -u -r1.87 -r1.88 src/sys/kern/subr_extent.c

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



CVS commit: src/sys/dev/ata

2019-08-15 Thread Andreas Gustafsson
Module Name:src
Committed By:   gson
Date:   Thu Aug 15 09:00:23 UTC 2019

Modified Files:
src/sys/dev/ata: satafis_subr.c

Log Message:
Set the ATAPI "BYTE COUNT LIMIT" field in the SATA case like we
already do in the ATA case, to make NetBSD work with the virtual
SATA CD-ROM of "qemu-system-i386 -machine q35".  Fixes PR kern/54389.
OK mlelstv.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/dev/ata/satafis_subr.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/dev/ata/satafis_subr.c
diff -u src/sys/dev/ata/satafis_subr.c:1.8 src/sys/dev/ata/satafis_subr.c:1.9
--- src/sys/dev/ata/satafis_subr.c:1.8	Sat Oct  7 16:05:32 2017
+++ src/sys/dev/ata/satafis_subr.c	Thu Aug 15 09:00:23 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: satafis_subr.c,v 1.8 2017/10/07 16:05:32 jdolecek Exp $ */
+/* $NetBSD: satafis_subr.c,v 1.9 2019/08/15 09:00:23 gson Exp $ */
 
 /*-
  * Copyright (c) 2009 Jonathan A. Kollasch.
@@ -51,7 +51,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: satafis_subr.c,v 1.8 2017/10/07 16:05:32 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: satafis_subr.c,v 1.9 2019/08/15 09:00:23 gson Exp $");
 
 #include 
 #include 
@@ -149,12 +149,16 @@ satafis_rhd_construct_bio(struct ata_xfe
 void
 satafis_rhd_construct_atapi(struct ata_xfer *xfer, uint8_t *fis)
 {
+	int bcount16;
 
 	memset(fis, 0, RHD_FISLEN);
 
 	fis[fis_type] = RHD_FISTYPE;
 	fis[rhd_c] = RHD_C;
 	fis[rhd_command] = ATAPI_PKT_CMD;
+	bcount16 = xfer->c_bcount <= 0x ? xfer->c_bcount : 0x;
+	fis[rhd_lba1] = (bcount16 >> 0) & 0xff;
+	fis[rhd_lba2] = (bcount16 >> 8) & 0xff;
 	fis[rhd_features0] = (xfer->c_flags & C_DMA) ?
 	ATAPI_PKT_CMD_FTRE_DMA : 0;
 }



CVS commit: src/sys/dev/ata

2019-08-15 Thread Andreas Gustafsson
Module Name:src
Committed By:   gson
Date:   Thu Aug 15 09:00:23 UTC 2019

Modified Files:
src/sys/dev/ata: satafis_subr.c

Log Message:
Set the ATAPI "BYTE COUNT LIMIT" field in the SATA case like we
already do in the ATA case, to make NetBSD work with the virtual
SATA CD-ROM of "qemu-system-i386 -machine q35".  Fixes PR kern/54389.
OK mlelstv.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/dev/ata/satafis_subr.c

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



CVS commit: src/doc

2019-08-15 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Thu Aug 15 08:55:06 UTC 2019

Modified Files:
src/doc: CHANGES

Log Message:
usbnet(9): Add common framework for USB network devices.  Port the
axe(4), axen(4), cdce(4), cue(4), mue(4), smsc(4), udav(4),
ure(4), url(4), and urndis(4) drivers fixing many bugs and
porting to NET_MPSAFE in the process.  [mrg 20190814]


To generate a diff of this commit:
cvs rdiff -u -r1.2567 -r1.2568 src/doc/CHANGES

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



CVS commit: src/doc

2019-08-15 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Thu Aug 15 08:55:06 UTC 2019

Modified Files:
src/doc: CHANGES

Log Message:
usbnet(9): Add common framework for USB network devices.  Port the
axe(4), axen(4), cdce(4), cue(4), mue(4), smsc(4), udav(4),
ure(4), url(4), and urndis(4) drivers fixing many bugs and
porting to NET_MPSAFE in the process.  [mrg 20190814]


To generate a diff of this commit:
cvs rdiff -u -r1.2567 -r1.2568 src/doc/CHANGES

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

Modified files:

Index: src/doc/CHANGES
diff -u src/doc/CHANGES:1.2567 src/doc/CHANGES:1.2568
--- src/doc/CHANGES:1.2567	Sat Aug 10 08:46:09 2019
+++ src/doc/CHANGES	Thu Aug 15 08:55:06 2019
@@ -1,4 +1,4 @@
-# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2567 $>
+# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2568 $>
 #
 #
 # [Note: This file does not mention every change made to the NetBSD source tree.
@@ -31,3 +31,7 @@ Changes from NetBSD 9.0 to NetBSD 10.0:
 		for depths 2 and 24. Shadow framebuffer supported for all
 		depths. A lot of bug fixes, both major and minor. Dedup more
 		than 20% of lines, or 50% of characters. [rin 20190810]
+	usbnet(9): Add common framework for USB network devices.  Port the
+		axe(4), axen(4), cdce(4), cue(4), mue(4), smsc(4), udav(4),
+		ure(4), url(4), and urndis(4) drivers fixing many bugs and
+		porting to NET_MPSAFE in the process.  [mrg 20190814]



CVS commit: src/tests/kernel

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:46:09 UTC 2019

Modified Files:
src/tests/kernel: Makefile

Log Message:
Adapt tests/kernel/t_subr_prf for MKSANITIZER

Allow to rename snprintf-like functions to avoid clashes with a sanitizer.

This tests needs a fixup to remove 'undef symbol' from the test code
generator.


To generate a diff of this commit:
cvs rdiff -u -r1.60 -r1.61 src/tests/kernel/Makefile

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



CVS commit: src/tests/kernel

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:46:09 UTC 2019

Modified Files:
src/tests/kernel: Makefile

Log Message:
Adapt tests/kernel/t_subr_prf for MKSANITIZER

Allow to rename snprintf-like functions to avoid clashes with a sanitizer.

This tests needs a fixup to remove 'undef symbol' from the test code
generator.


To generate a diff of this commit:
cvs rdiff -u -r1.60 -r1.61 src/tests/kernel/Makefile

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

Modified files:

Index: src/tests/kernel/Makefile
diff -u src/tests/kernel/Makefile:1.60 src/tests/kernel/Makefile:1.61
--- src/tests/kernel/Makefile:1.60	Fri Jun  7 21:18:16 2019
+++ src/tests/kernel/Makefile	Thu Aug 15 08:46:09 2019
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.60 2019/06/07 21:18:16 christos Exp $
+# $NetBSD: Makefile,v 1.61 2019/08/15 08:46:09 kamil Exp $
 
 NOMAN=		# defined
 
@@ -66,6 +66,11 @@ CPPFLAGS.subr_extent.c=	-D_EXTENT_TESTIN
 
 t_subr_prf.c: gen_t_subr_prf ${NETBSDSRCDIR}/sys/kern/subr_prf.c
 	${HOST_SH} ${.ALLSRC} ${.TARGET}
+.if ${MKSANITIZER:Uno} == "yes"
+	# These symbols will be redefined by MKSANITIZER
+	${TOOL_SED} -i '/undef .*printf/d' ${.TARGET}
+.endif
+
 CPPFLAGS.t_subr_prf.c=	-Wno-pointer-sign	# XXX platform vs kernel SHA2
 
 .if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc"
@@ -73,6 +78,14 @@ CPPFLAGS.t_subr_prf.c=	-Wno-pointer-sign
 CPPFLAGS.t_subr_prf.c+=	-Wno-error=format-truncation
 .endif
 
+SANITIZER_RENAME_CLASSES+=		t_subr_prf
+SANITIZER_RENAME_FILES.t_subr_prf+=	t_subr_prf.c
+SANITIZER_RENAME_SYMBOL.t_subr_prf+=	snprintf
+SANITIZER_RENAME_SYMBOL.t_subr_prf+=	vsnprintf
+SANITIZER_RENAME_SYMBOL.t_subr_prf+=	sprintf
+SANITIZER_RENAME_SYMBOL.t_subr_prf+=	vsnprintf
+SANITIZER_RENAME_SYMBOL.t_subr_prf+=	vasprintf
+
 CLEANFILES+=	t_subr_prf.c
 
 LDADD.h_segv+=	-lm



CVS commit: src/share/mk

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:42:59 UTC 2019

Modified Files:
src/share/mk: bsd.prog.mk

Log Message:
Add SANITIZER_RENAME_CLASSES in bsd.prog.mk

This adds a more flexible version of SANITIZER_RENAME_SYMBOL.

New symbol allows to specify MKSANITIZER specific renames on per-file and
per-symbol basis.


To generate a diff of this commit:
cvs rdiff -u -r1.320 -r1.321 src/share/mk/bsd.prog.mk

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



CVS commit: src/share/mk

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:42:59 UTC 2019

Modified Files:
src/share/mk: bsd.prog.mk

Log Message:
Add SANITIZER_RENAME_CLASSES in bsd.prog.mk

This adds a more flexible version of SANITIZER_RENAME_SYMBOL.

New symbol allows to specify MKSANITIZER specific renames on per-file and
per-symbol basis.


To generate a diff of this commit:
cvs rdiff -u -r1.320 -r1.321 src/share/mk/bsd.prog.mk

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

Modified files:

Index: src/share/mk/bsd.prog.mk
diff -u src/share/mk/bsd.prog.mk:1.320 src/share/mk/bsd.prog.mk:1.321
--- src/share/mk/bsd.prog.mk:1.320	Sat Aug 10 12:46:38 2019
+++ src/share/mk/bsd.prog.mk	Thu Aug 15 08:42:59 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.prog.mk,v 1.320 2019/08/10 12:46:38 christos Exp $
+#	$NetBSD: bsd.prog.mk,v 1.321 2019/08/15 08:42:59 kamil Exp $
 #	@(#)bsd.prog.mk	8.2 (Berkeley) 4/2/94
 
 .ifndef HOSTPROG
@@ -20,6 +20,16 @@ CPPFLAGS+=	-D${_symbol}=__mksanitizer_${
 .	endfor
 .endif
 
+.if ${MKSANITIZER:Uno} == "yes" && defined(SANITIZER_RENAME_CLASSES)
+.	for _class in ${SANITIZER_RENAME_CLASSES}
+.		for _file in ${SANITIZER_RENAME_FILES.${_class}}
+.			for _symbol in ${SANITIZER_RENAME_SYMBOL.${_class}}
+COPTS.${_file}+=	-D${_symbol}=__mksanitizer_${_symbol}
+.			endfor
+.		endfor
+.	endfor
+.endif
+
 #
 # Definitions and targets shared among all programs built by a single
 # Makefile.



CVS commit: src/share/man/man9

2019-08-15 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Thu Aug 15 08:37:13 UTC 2019

Modified Files:
src/share/man/man9: usbnet.9

Log Message:
Fix Xr usage.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/share/man/man9/usbnet.9

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



CVS commit: src/share/man/man9

2019-08-15 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Thu Aug 15 08:37:13 UTC 2019

Modified Files:
src/share/man/man9: usbnet.9

Log Message:
Fix Xr usage.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/share/man/man9/usbnet.9

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

Modified files:

Index: src/share/man/man9/usbnet.9
diff -u src/share/man/man9/usbnet.9:1.6 src/share/man/man9/usbnet.9:1.7
--- src/share/man/man9/usbnet.9:1.6	Thu Aug 15 08:33:14 2019
+++ src/share/man/man9/usbnet.9	Thu Aug 15 08:37:13 2019
@@ -1,4 +1,4 @@
-.\"	$NetBSD: usbnet.9,v 1.6 2019/08/15 08:33:14 mrg Exp $
+.\"	$NetBSD: usbnet.9,v 1.7 2019/08/15 08:37:13 wiz Exp $
 .\"
 .\" Copyright (c) 2019 Matthew R. Green
 .\" All rights reserved.
@@ -442,7 +442,7 @@ structure which contains these members:
 Stop interface (optional.)
 .It Ft int Fn (*uno_ioctl) "struct ifnet *ifp" "u_long cmd" "void *data"
 Simple ioctl callback (optional.)
-.It Ft int Fn (*uno_override_ioctl "struct ifnet *ifp" "u_long cmd" "void *data"
+.It Ft int Fn (*uno_override_ioctl) "struct ifnet *ifp" "u_long cmd" "void *data"
 Full ioctl callback (optional.)
 .It Ft int Fn (*uno_init) "struct ifnet *ifp"
 Initialize (bring up) interface.
@@ -597,9 +597,9 @@ enqueued with the higher layers using ei
 for devices that currently use
 .Fn if_input .
 The Rx lock will be held during this call, see
-.Xr Fn usbnet_lock_rx
+.Fn usbnet_lock_rx
 and
-.Xr Fn usbnet_unlock_rx .
+.Fn usbnet_unlock_rx .
 .Pp
 The
 .Fn uno_tx_prepare
@@ -615,9 +615,9 @@ more than the chain buffer size, as set 
 member.
 This callback is only called once per packet.
 The Tx lock will be held during this call, see
-.Xr Fn usbnet_lock_tx
+.Fn usbnet_lock_tx
 and
-.Xr Fn usbnet_unlock_tx .
+.Fn usbnet_unlock_tx .
 .Pp
 The
 .Fa struct usbnet_chain
@@ -648,9 +648,9 @@ Handle a status change event for this in
 .El
 The read and write callbacks are called with the MII lock held.
 See
-.Xr usbnet_lock_mii
+.Fn usbnet_lock_mii
 and
-.Xr usbnet_unlock_mii .
+.Fn usbnet_unlock_mii .
 .Sh INTERRUPT PIPE
 The interrupt specific callback,
 .Dq uno_intr ,



CVS commit: src/usr.sbin/installboot

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:36:09 UTC 2019

Modified Files:
src/usr.sbin/installboot: installboot.h

Log Message:
Add missing extern declaration of ib_mach_emips in installboot

Change added for the consistency with the existing code.


To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/usr.sbin/installboot/installboot.h

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/installboot/installboot.h
diff -u src/usr.sbin/installboot/installboot.h:1.40 src/usr.sbin/installboot/installboot.h:1.41
--- src/usr.sbin/installboot/installboot.h:1.40	Tue May  7 05:02:42 2019
+++ src/usr.sbin/installboot/installboot.h	Thu Aug 15 08:36:09 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: installboot.h,v 1.40 2019/05/07 05:02:42 thorpej Exp $	*/
+/*	$NetBSD: installboot.h,v 1.41 2019/08/15 08:36:09 kamil Exp $	*/
 
 /*-
  * Copyright (c) 2002 The NetBSD Foundation, Inc.
@@ -184,6 +184,7 @@ int		ext2fs_findstage2(ib_params *, uint
 extern struct ib_mach ib_mach_alpha;
 extern struct ib_mach ib_mach_amd64;
 extern struct ib_mach ib_mach_amiga;
+extern struct ib_mach ib_mach_emips;
 extern struct ib_mach ib_mach_evbarm;
 extern struct ib_mach ib_mach_ews4800mips;
 extern struct ib_mach ib_mach_hp300;



CVS commit: src/usr.sbin/installboot

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:36:09 UTC 2019

Modified Files:
src/usr.sbin/installboot: installboot.h

Log Message:
Add missing extern declaration of ib_mach_emips in installboot

Change added for the consistency with the existing code.


To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/usr.sbin/installboot/installboot.h

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



CVS commit: src/usr.sbin

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:34:19 UTC 2019

Modified Files:
src/usr.sbin/rpc.bootparamd: bootparamd.c
src/usr.sbin/rpc.lockd: lockd.c
src/usr.sbin/rpc.statd: statd.c

Log Message:
Stop defining _rpcsvcdirty in bss and data

_rpcsvcdirty is already defined in the generated code from rpcgen(1).

Detected during the build with Address Sanitizer (MKSANITIZER).


To generate a diff of this commit:
cvs rdiff -u -r1.46 -r1.47 src/usr.sbin/rpc.bootparamd/bootparamd.c
cvs rdiff -u -r1.12 -r1.13 src/usr.sbin/rpc.lockd/lockd.c
cvs rdiff -u -r1.32 -r1.33 src/usr.sbin/rpc.statd/statd.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/rpc.bootparamd/bootparamd.c
diff -u src/usr.sbin/rpc.bootparamd/bootparamd.c:1.46 src/usr.sbin/rpc.bootparamd/bootparamd.c:1.47
--- src/usr.sbin/rpc.bootparamd/bootparamd.c:1.46	Tue Aug 30 20:29:41 2011
+++ src/usr.sbin/rpc.bootparamd/bootparamd.c	Thu Aug 15 08:34:19 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bootparamd.c,v 1.46 2011/08/30 20:29:41 joerg Exp $	*/
+/*	$NetBSD: bootparamd.c,v 1.47 2019/08/15 08:34:19 kamil Exp $	*/
 
 /*
  * This code is not copyright, and is placed in the public domain.
@@ -11,7 +11,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: bootparamd.c,v 1.46 2011/08/30 20:29:41 joerg Exp $");
+__RCSID("$NetBSD: bootparamd.c,v 1.47 2019/08/15 08:34:19 kamil Exp $");
 #endif
 
 #include 
@@ -55,7 +55,7 @@ static char domain_name[MAX_MACHINE_NAME
 
 extern void bootparamprog_1(struct svc_req *, SVCXPRT *);
 
-int	_rpcsvcdirty = 0;
+extern int	_rpcsvcdirty;
 int	_rpcpmstart = 0;
 int debug = 0;
 int dolog = 0;

Index: src/usr.sbin/rpc.lockd/lockd.c
diff -u src/usr.sbin/rpc.lockd/lockd.c:1.12 src/usr.sbin/rpc.lockd/lockd.c:1.13
--- src/usr.sbin/rpc.lockd/lockd.c:1.12	Mon Aug 13 12:37:18 2012
+++ src/usr.sbin/rpc.lockd/lockd.c	Thu Aug 15 08:34:19 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: lockd.c,v 1.12 2012/08/13 12:37:18 wiz Exp $	*/
+/*	$NetBSD: lockd.c,v 1.13 2019/08/15 08:34:19 kamil Exp $	*/
 
 /*
  * Copyright (c) 1995
@@ -35,7 +35,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: lockd.c,v 1.12 2012/08/13 12:37:18 wiz Exp $");
+__RCSID("$NetBSD: lockd.c,v 1.13 2019/08/15 08:34:19 kamil Exp $");
 #endif
 
 /*
@@ -67,7 +67,7 @@ __RCSID("$NetBSD: lockd.c,v 1.12 2012/08
 #include 
 
 int		debug_level = 0;	/* 0 = no debugging syslog() calls */
-int		_rpcsvcdirty = 0;
+extern int	_rpcsvcdirty;
 
 int grace_expired;
 

Index: src/usr.sbin/rpc.statd/statd.c
diff -u src/usr.sbin/rpc.statd/statd.c:1.32 src/usr.sbin/rpc.statd/statd.c:1.33
--- src/usr.sbin/rpc.statd/statd.c:1.32	Tue Jan 23 21:06:26 2018
+++ src/usr.sbin/rpc.statd/statd.c	Thu Aug 15 08:34:19 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: statd.c,v 1.32 2018/01/23 21:06:26 sevan Exp $	*/
+/*	$NetBSD: statd.c,v 1.33 2019/08/15 08:34:19 kamil Exp $	*/
 
 /*
  * Copyright (c) 1995
@@ -36,7 +36,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: statd.c,v 1.32 2018/01/23 21:06:26 sevan Exp $");
+__RCSID("$NetBSD: statd.c,v 1.33 2019/08/15 08:34:19 kamil Exp $");
 #endif
 
 /* main() function for status monitor daemon.  Some of the code in this	*/
@@ -66,7 +66,7 @@ __RCSID("$NetBSD: statd.c,v 1.32 2018/01
 
 struct sigaction sa;
 int 	debug = 0;		/* Controls syslog() for debug msgs */
-int 	_rpcsvcdirty = 0;	/* XXX ??? */
+extern int 	_rpcsvcdirty;
 static DB	*db;			/* Database file */
 
 Header		 status_info;



CVS commit: src/usr.sbin

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:34:19 UTC 2019

Modified Files:
src/usr.sbin/rpc.bootparamd: bootparamd.c
src/usr.sbin/rpc.lockd: lockd.c
src/usr.sbin/rpc.statd: statd.c

Log Message:
Stop defining _rpcsvcdirty in bss and data

_rpcsvcdirty is already defined in the generated code from rpcgen(1).

Detected during the build with Address Sanitizer (MKSANITIZER).


To generate a diff of this commit:
cvs rdiff -u -r1.46 -r1.47 src/usr.sbin/rpc.bootparamd/bootparamd.c
cvs rdiff -u -r1.12 -r1.13 src/usr.sbin/rpc.lockd/lockd.c
cvs rdiff -u -r1.32 -r1.33 src/usr.sbin/rpc.statd/statd.c

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



CVS commit: src/share/man/man9

2019-08-15 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Thu Aug 15 08:33:14 UTC 2019

Modified Files:
src/share/man/man9: usbnet.9

Log Message:
- document locking requirements more
- expand uno_foo() docs to include return type and parameters
- expand uno_intr() docs
- add uno_tick()
- fix various typoes


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/share/man/man9/usbnet.9

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



CVS commit: src/share/man/man9

2019-08-15 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Thu Aug 15 08:33:14 UTC 2019

Modified Files:
src/share/man/man9: usbnet.9

Log Message:
- document locking requirements more
- expand uno_foo() docs to include return type and parameters
- expand uno_intr() docs
- add uno_tick()
- fix various typoes


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/share/man/man9/usbnet.9

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

Modified files:

Index: src/share/man/man9/usbnet.9
diff -u src/share/man/man9/usbnet.9:1.5 src/share/man/man9/usbnet.9:1.6
--- src/share/man/man9/usbnet.9:1.5	Mon Aug 12 00:01:23 2019
+++ src/share/man/man9/usbnet.9	Thu Aug 15 08:33:14 2019
@@ -1,4 +1,4 @@
-.\"	$NetBSD: usbnet.9,v 1.5 2019/08/12 00:01:23 mrg Exp $
+.\"	$NetBSD: usbnet.9,v 1.6 2019/08/15 08:33:14 mrg Exp $
 .\"
 .\" Copyright (c) 2019 Matthew R. Green
 .\" All rights reserved.
@@ -26,7 +26,7 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.Dd August 11, 2019
+.Dd August 14, 2019
 .Dt USBNET 9
 .Os
 .Sh NAME
@@ -346,6 +346,7 @@ on PHY number
 .Fa phy
 and return the value in
 .Fa valp .
+Called with the MII lock held.
 .It Fn usbnet_mii_writereg dev phy reg val
 Write register
 .Fa reg
@@ -353,9 +354,11 @@ on PHY number
 .Fa phy
 with
 .Fa val .
+Called with the MII lock held.
 .It Fn usbnet_mii_statchg ifp
 Trigger a status change update for interface
-.Fa ifp
+.Fa ifp .
+Unlike register access, called with the MII lock not held.
 .El
 .Pp
 Buffer enqueue handling for
@@ -435,34 +438,36 @@ Points to a
 .Va struct usbnet_ops
 structure which contains these members:
 .Bl -tag -width 4n
-.It uno_stop
+.It Ft void Fn (*uno_stop) "struct ifnet *ifp" "int disable"
 Stop interface (optional.)
-.It uno_ioctl
+.It Ft int Fn (*uno_ioctl) "struct ifnet *ifp" "u_long cmd" "void *data"
 Simple ioctl callback (optional.)
-.It uno_override_ioctl
+.It Ft int Fn (*uno_override_ioctl "struct ifnet *ifp" "u_long cmd" "void *data"
 Full ioctl callback (optional.)
-.It uno_init
+.It Ft int Fn (*uno_init) "struct ifnet *ifp"
 Initialize (bring up) interface.
 Required.
 Must call
 .Fn usbnet_rx_tx_init .
-.It uno_read_reg
+.It Ft usbd_status Fn (*uno_read_reg) "struct usbnet *un" "int phy" "int reg" "uint16_t *val"
 Read MII register.
 Required with MII.
-.It uno_write_reg
+.It Ft usbd_status Fn (*uno_write_reg) "struct usbnet *un" "int phy" "int reg" "uint16_t val"
 Write MII register.
 Required with MII.
-.It uno_statchg
+.It Ft usbd_status Fn (*uno_statchg) "struct ifnet *ifp"
 Handle MII status change.
 Required with MII.
-.It uno_tx_prepare
+.It Ft usbd_status Fn (*uno_tx_prepare) "struct usbnet *un" "struct mbuf *m" "struct usbnet_chain *c"
 Prepare an mbuf for transmit.
 Required.
-.It uno_rx_loop
+.It Ft usbd_status Fn (*uno_rx_loop) "struct usbnet *un" "struct usbnet_chain *c" "uint32_t total_len"
 Prepare one or more chain for enqueue.
 Required.
-.It uno_intr
+.It Ft void Fn (*uno_intr) "struct usbnet *un" "usbd_status status"
 Process periodic interrupt (optional.)
+.It Ft void Fn (*uno_tick) "struct usbnet *un"
+Called every second with USB task thread context (optional.)
 .El
 .It un_intr
 Points to a
@@ -473,7 +478,7 @@ structure which should have these member
 If
 .Pf non- Dv NULL ,
 points to a buffer passed to
-Fn usbd_open_pipe_intr
+.Fn usbd_open_pipe_intr
 in the device init callback, along with the size and interval.
 .It uni_intr_bufsz
 Size of interrupt pipe buffer.
@@ -483,10 +488,10 @@ Frequency of the interrupt in millisecon
 .It un_ed
 Array of endpoint descriptors.
 There indexes are provided:
-.Dq USBNET_ENDPT_RX ,
-.Dq USBNET_ENDPT_TX ,
+.Dv USBNET_ENDPT_RX ,
+.Dv USBNET_ENDPT_TX ,
 and
-.Dq USBNET_ENDPT_INTR .
+.Dv USBNET_ENDPT_INTR .
 The Rx and Tx endpoints are required.
 .It un_phyno
 MII phy number.
@@ -567,6 +572,8 @@ The optional
 .Fn uno_stop
 callback performs device-specific operations to shutdown the
 transmit or receive handling.
+.Fn uno_stop
+will be called with the usbnet lock held.
 .Pp
 The
 .Fn uno_init
@@ -589,6 +596,10 @@ enqueued with the higher layers using ei
 .Fn usbnet_input
 for devices that currently use
 .Fn if_input .
+The Rx lock will be held during this call, see
+.Xr Fn usbnet_lock_rx
+and
+.Xr Fn usbnet_unlock_rx .
 .Pp
 The
 .Fn uno_tx_prepare
@@ -603,6 +614,10 @@ more than the chain buffer size, as set 
 .Dq un_tx_bufsz
 member.
 This callback is only called once per packet.
+The Tx lock will be held during this call, see
+.Xr Fn usbnet_lock_tx
+and
+.Xr Fn usbnet_unlock_tx .
 .Pp
 The
 .Fa struct usbnet_chain
@@ -631,6 +646,11 @@ Returns
 .It uno_statchg
 Handle a status change event for this interface.
 .El
+The read and write callbacks are called with the MII lock held.
+See
+.Xr usbnet_lock_mii
+and
+.Xr usbnet_unlock_mii .
 .Sh INTERRUPT PIPE
 The interrupt specific callback,
 .Dq uno_intr ,
@@ -641,6 +661,10 @@ using the
 

CVS commit: src/usr.sbin/ypserv/ypserv

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:30:19 UTC 2019

Modified Files:
src/usr.sbin/ypserv/ypserv: Makefile

Log Message:
Avoid symbol clashes in usr.sbin/ypserv/ypserv under MKSANITIZER

Remove symbol conflicts for: gethostbyname2


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/usr.sbin/ypserv/ypserv/Makefile

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/ypserv/ypserv/Makefile
diff -u src/usr.sbin/ypserv/ypserv/Makefile:1.18 src/usr.sbin/ypserv/ypserv/Makefile:1.19
--- src/usr.sbin/ypserv/ypserv/Makefile:1.18	Thu Oct 29 14:41:02 2009
+++ src/usr.sbin/ypserv/ypserv/Makefile	Thu Aug 15 08:30:19 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.18 2009/10/29 14:41:02 christos Exp $
+#	$NetBSD: Makefile,v 1.19 2019/08/15 08:30:19 kamil Exp $
 
 .include 
 
@@ -18,4 +18,6 @@ DPADD+=	${LIBWRAP} ${LIBUTIL}
 CPPFLAGS.gethnamaddr.c=	-UYP -D_LIBC
 CPPFLAGS.getnetnamadr.c=-UYP -D_LIBC
 
+SANITIZER_RENAME_SYMBOL+=	gethostbyname2
+
 .include 



CVS commit: src/usr.sbin/ypserv/ypserv

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:30:19 UTC 2019

Modified Files:
src/usr.sbin/ypserv/ypserv: Makefile

Log Message:
Avoid symbol clashes in usr.sbin/ypserv/ypserv under MKSANITIZER

Remove symbol conflicts for: gethostbyname2


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/usr.sbin/ypserv/ypserv/Makefile

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



CVS commit: src/tests/bin/df

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:24:11 UTC 2019

Modified Files:
src/tests/bin/df: Makefile

Log Message:
Avoid symbol clashes in bin/df under MKSANITIZER

Remove symbol conflicts for: __getmntinfo13


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/tests/bin/df/Makefile

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



CVS commit: src/tests/bin/df

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:24:11 UTC 2019

Modified Files:
src/tests/bin/df: Makefile

Log Message:
Avoid symbol clashes in bin/df under MKSANITIZER

Remove symbol conflicts for: __getmntinfo13


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/tests/bin/df/Makefile

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

Modified files:

Index: src/tests/bin/df/Makefile
diff -u src/tests/bin/df/Makefile:1.1 src/tests/bin/df/Makefile:1.2
--- src/tests/bin/df/Makefile:1.1	Sat Mar 17 16:33:11 2012
+++ src/tests/bin/df/Makefile	Thu Aug 15 08:24:11 2019
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2012/03/17 16:33:11 jruoho Exp $
+# $NetBSD: Makefile,v 1.2 2019/08/15 08:24:11 kamil Exp $
 
 NOMAN=  	# defined
 
@@ -24,4 +24,6 @@ CPPFLAGS+=	-I${NETBSDSRCDIR}/lib/libc/in
 SRCS+=		humanize_number.c
 .endif
 
+SANITIZER_RENAME_SYMBOL+=	__getmntinfo13
+
 .include 



CVS commit: src/tests/fs/nfs/nfsservice

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:23:45 UTC 2019

Modified Files:
src/tests/fs/nfs/nfsservice: Makefile

Log Message:
Avoid symbol clashes in fs/nfs/nfsservice under MKSANITIZER

Remove symbol conflicts for: __getmntinfo13


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/tests/fs/nfs/nfsservice/Makefile

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



CVS commit: src/tests/fs/nfs/nfsservice

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:23:45 UTC 2019

Modified Files:
src/tests/fs/nfs/nfsservice: Makefile

Log Message:
Avoid symbol clashes in fs/nfs/nfsservice under MKSANITIZER

Remove symbol conflicts for: __getmntinfo13


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/tests/fs/nfs/nfsservice/Makefile

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

Modified files:

Index: src/tests/fs/nfs/nfsservice/Makefile
diff -u src/tests/fs/nfs/nfsservice/Makefile:1.12 src/tests/fs/nfs/nfsservice/Makefile:1.13
--- src/tests/fs/nfs/nfsservice/Makefile:1.12	Sat Aug 13 11:20:00 2016
+++ src/tests/fs/nfs/nfsservice/Makefile	Thu Aug 15 08:23:45 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.12 2016/08/13 11:20:00 christos Exp $
+#	$NetBSD: Makefile,v 1.13 2019/08/15 08:23:45 kamil Exp $
 #
 
 NOMAN=	1
@@ -48,4 +48,6 @@ CPPFLAGS+=	-I${LIBRPCDIR} -DPORTMAP -DLI
 LDADD+= -lwrap -lutil
 DPADD+= ${LIBWRAP} ${LIBUTIL}
 
+SANITIZER_RENAME_SYMBOL+=	__getmntinfo13
+
 .include 



CVS commit: src/tests/usr.bin/id

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:22:52 UTC 2019

Modified Files:
src/tests/usr.bin/id: Makefile

Log Message:
Avoid symbol clashes in tests/usr.bin/id under MKSANITIZER

Remove symbol conflicts for:

 - __getpwnam50
 - __getpwuid50
 - getgrgid
 - getgrouplist
 - getgroups


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/tests/usr.bin/id/Makefile

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/id

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:22:52 UTC 2019

Modified Files:
src/tests/usr.bin/id: Makefile

Log Message:
Avoid symbol clashes in tests/usr.bin/id under MKSANITIZER

Remove symbol conflicts for:

 - __getpwnam50
 - __getpwuid50
 - getgrgid
 - getgrouplist
 - getgroups


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/tests/usr.bin/id/Makefile

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/id/Makefile
diff -u src/tests/usr.bin/id/Makefile:1.1 src/tests/usr.bin/id/Makefile:1.2
--- src/tests/usr.bin/id/Makefile:1.1	Sat Mar 17 16:33:14 2012
+++ src/tests/usr.bin/id/Makefile	Thu Aug 15 08:22:52 2019
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2012/03/17 16:33:14 jruoho Exp $
+# $NetBSD: Makefile,v 1.2 2019/08/15 08:22:52 kamil Exp $
 
 NOMAN=		# defined
 
@@ -17,4 +17,10 @@ SRCS=		id.c pwgr.c
 
 COPTS.id.c += -Wno-format-nonliteral
 
+SANITIZER_RENAME_SYMBOL+=	__getpwnam50
+SANITIZER_RENAME_SYMBOL+=	__getpwuid50
+SANITIZER_RENAME_SYMBOL+=	getgrgid
+SANITIZER_RENAME_SYMBOL+=	getgrouplist
+SANITIZER_RENAME_SYMBOL+=	getgroups
+
 .include 



CVS commit: src/tests/lib/libc/misc

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:17:32 UTC 2019

Modified Files:
src/tests/lib/libc/misc: Makefile

Log Message:
Fix build of t_ubsan/t_ubsanxx under MKSANITIZER

Do not link micro-ubsan runtime for disabled tests.

This avoids double symbols linked into a single binary.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tests/lib/libc/misc/Makefile

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



CVS commit: src/tests/lib/libc/misc

2019-08-15 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Thu Aug 15 08:17:32 UTC 2019

Modified Files:
src/tests/lib/libc/misc: Makefile

Log Message:
Fix build of t_ubsan/t_ubsanxx under MKSANITIZER

Do not link micro-ubsan runtime for disabled tests.

This avoids double symbols linked into a single binary.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tests/lib/libc/misc/Makefile

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/libc/misc/Makefile
diff -u src/tests/lib/libc/misc/Makefile:1.3 src/tests/lib/libc/misc/Makefile:1.4
--- src/tests/lib/libc/misc/Makefile:1.3	Mon Feb  4 03:10:33 2019
+++ src/tests/lib/libc/misc/Makefile	Thu Aug 15 08:17:32 2019
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 2019/02/04 03:10:33 mrg Exp $
+# $NetBSD: Makefile,v 1.4 2019/08/15 08:17:32 kamil Exp $
 
 .include 
 
@@ -8,13 +8,15 @@ TESTS_C+=	t_ubsan
 TESTS_CXX+=	t_ubsanxx
 
 .PATH:		${NETBSDSRCDIR}/common/lib/libc/misc
-SRCS.t_ubsan=	t_ubsan.c ubsan.c
-SRCS.t_ubsanxx=	t_ubsanxx.cpp ubsan.c
+SRCS.t_ubsan=	t_ubsan.c
+SRCS.t_ubsanxx=	t_ubsanxx.cpp
 
 .if ${MKSANITIZER:Uno} != "yes" && ${MKLIBCSANITIZER:Uno} != "yes"
 # These tests are designed to be used against micro-UBSan only.
 # micro-UBSan is used in these tests as a standalone libary only.
 CPPFLAGS+=		-DENABLE_TESTS
+SRCS.t_ubsan+=		ubsan.c
+SRCS.t_ubsanxx+=	ubsan.c
 UBSAN_FLAGS=		-fsanitize=undefined
 UBSAN_FLAGS+=		${${ACTIVE_CC} == "clang" :? -fsanitize=integer :}
 UBSAN_FLAGS+=		${${ACTIVE_CC} == "clang" :? -fsanitize=nullability :}



CVS commit: src/sys/dev/usb

2019-08-15 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Thu Aug 15 08:02:32 UTC 2019

Modified Files:
src/sys/dev/usb: files.usb if_cue.c if_cuereg.h if_mue.c if_muereg.h
if_muevar.h if_url.c if_urlreg.h

Log Message:
port cue(4), mue(4) and url(4) to usbnet(9).  diffstat says:

8 files changed, 911 insertions(+), 3087 deletions(-)


To generate a diff of this commit:
cvs rdiff -u -r1.163 -r1.164 src/sys/dev/usb/files.usb
cvs rdiff -u -r1.84 -r1.85 src/sys/dev/usb/if_cue.c
cvs rdiff -u -r1.22 -r1.23 src/sys/dev/usb/if_cuereg.h
cvs rdiff -u -r1.51 -r1.52 src/sys/dev/usb/if_mue.c
cvs rdiff -u -r1.5 -r1.6 src/sys/dev/usb/if_muereg.h
cvs rdiff -u -r1.8 -r1.9 src/sys/dev/usb/if_muevar.h
cvs rdiff -u -r1.67 -r1.68 src/sys/dev/usb/if_url.c
cvs rdiff -u -r1.13 -r1.14 src/sys/dev/usb/if_urlreg.h

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