CVS commit: src/sys/dev/usb

2016-05-05 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri May  6 05:19:32 UTC 2016

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
Fix polling mode and USB keyboards in ddb


To generate a diff of this commit:
cvs rdiff -u -r1.169 -r1.170 src/sys/dev/usb/usbdi.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/usb/usbdi.c
diff -u src/sys/dev/usb/usbdi.c:1.169 src/sys/dev/usb/usbdi.c:1.170
--- src/sys/dev/usb/usbdi.c:1.169	Sat Apr 23 10:15:32 2016
+++ src/sys/dev/usb/usbdi.c	Fri May  6 05:19:32 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: usbdi.c,v 1.169 2016/04/23 10:15:32 skrll Exp $	*/
+/*	$NetBSD: usbdi.c,v 1.170 2016/05/06 05:19:32 skrll Exp $	*/
 
 /*
  * Copyright (c) 1998, 2012, 2015 The NetBSD Foundation, Inc.
@@ -32,7 +32,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: usbdi.c,v 1.169 2016/04/23 10:15:32 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: usbdi.c,v 1.170 2016/05/06 05:19:32 skrll Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -910,10 +910,6 @@ usb_transfer_complete(struct usbd_xfer *
 	KASSERT(xfer->ux_state == XFER_ONQU);
 	KASSERT(pipe != NULL);
 
-	/*  */
-	if (polling)
-		pipe->up_running = 0;
-
 	if (!repeat) {
 		/* Remove request from queue. */
 



CVS commit: src/sys/dev/usb

2016-05-05 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri May  6 05:19:32 UTC 2016

Modified Files:
src/sys/dev/usb: usbdi.c

Log Message:
Fix polling mode and USB keyboards in ddb


To generate a diff of this commit:
cvs rdiff -u -r1.169 -r1.170 src/sys/dev/usb/usbdi.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

2016-05-05 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Fri May  6 04:55:10 UTC 2016

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

Log Message:
Revise/update. List the functions in a sensible order. Document all
the modes and flags. Document the structure fields properly.
Distinguish internals from public interfaces. Mention historic dead
flags like SAVESTART because they still exist in other projects.
Explain the current layout of vfs_lookup.c, or at least the primary
points of it.

Etc.

This ended up being a much larger rewrite than I intended.

Bump date again.


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/share/man/man9/namei.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/namei.9
diff -u src/share/man/man9/namei.9:1.35 src/share/man/man9/namei.9:1.36
--- src/share/man/man9/namei.9:1.35	Thu May  5 17:06:41 2016
+++ src/share/man/man9/namei.9	Fri May  6 04:55:10 2016
@@ -1,4 +1,4 @@
-.\" $NetBSD: namei.9,v 1.35 2016/05/05 17:06:41 salazar Exp $
+.\" $NetBSD: namei.9,v 1.36 2016/05/06 04:55:10 dholland Exp $
 .\"
 .\" Copyright (c) 2001, 2005, 2006 The NetBSD Foundation, Inc.
 .\" All rights reserved.
@@ -27,43 +27,42 @@
 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\" POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd May 05, 2016
+.Dd May 6, 2016
 .Dt NAMEI 9
 .Os
 .Sh NAME
 .Nm namei ,
-.Nm lookup_for_nfsd ,
-.Nm lookup_for_nfsd_index ,
-.Nm relookup ,
 .Nm NDINIT ,
 .Nm NDAT ,
 .Nm namei_simple_kernel ,
 .Nm namei_simple_user
+.Nm relookup ,
+.Nm lookup_for_nfsd ,
+.Nm lookup_for_nfsd_index ,
 .Nd pathname lookup
 .Sh SYNOPSIS
 .In sys/namei.h
 .In sys/uio.h
 .In sys/vnode.h
-.Ft int
-.Fn namei "struct nameidata *ndp"
-.Ft int
-.Fn lookup_for_nfsd "struct nameidata *ndp" "struct vnode *startdir" \
-"int neverfollow"
-.Ft int
-.Fn lookup_for_nfsd_index "struct nameidata *ndp"
-.Ft int
-.Fn relookup "struct vnode *dvp" "struct vnode **vpp" \
-"struct componentname *cnp"
-.Ft void
 .Fn NDINIT "struct nameidata *ndp" "u_long op" "u_long flags" \
 "struct pathbuf *pathbuf"
 .Fn NDAT "struct nameidata *ndp" "struct vnode *dvp"
 .Ft int
+.Fn namei "struct nameidata *ndp"
+.Ft int
 .Fn namei_simple_kernel "const char *path" "namei_simple_flags_t sflags" \
 "struct vnode **ret"
 .Ft int
 .Fn namei_simple_user "const char *path" "namei_simple_flags_t sflags" \
 "struct vnode **ret"
+.Ft int
+.Fn relookup "struct vnode *dvp" "struct vnode **vpp" \
+"struct componentname *cnp"
+.Ft int
+.Fn lookup_for_nfsd "struct nameidata *ndp" "struct vnode *startdir" \
+"int neverfollow"
+.Ft int
+.Fn lookup_for_nfsd_index "struct nameidata *ndp"
 .Sh DESCRIPTION
 The
 .Nm
@@ -81,39 +80,61 @@ Except for the simple forms, the argumen
 encapsulated in the
 .Em nameidata
 structure.
-It has the following layout:
-.Bd -literal
-struct nameidata {
-	/*
-	 * Arguments to namei/lookup.
-	 */
-	struct vnode *ni_atdir;		/* startup dir, cwd if null */
-	struct pathbuf *ni_pathbuf;	/* pathname container */
-	char *ni_pnbuf;			/* extra pathname buffer ref (XXX) */
-	/*
-	 * Arguments to lookup.
-	 */
-	struct	vnode *ni_rootdir;	/* logical root directory */
-	struct	vnode *ni_erootdir;	/* emulation root directory */
-	/*
-	 * Results: returned from/manipulated by lookup
-	 */
-	struct	vnode *ni_vp;		/* vnode of result */
-	struct	vnode *ni_dvp;		/* vnode of intermediate directory */
-	/*
-	 * Shared between namei and lookup/commit routines.
-	 */
-	size_t		ni_pathlen;	/* remaining chars in path */
-	const char	*ni_next;	/* next location in pathname */
-	unsigned int	ni_loopcnt;	/* count of symlinks encountered */
-	/*
-	 * Lookup parameters: this structure describes the subset of
-	 * information from the nameidata structure that is passed
-	 * through the VOP interface.
-	 */
-	struct componentname ni_cnd;
-};
-.Ed
+The public interface to this structure is as follows.
+.Bl -offset indent
+.It
+It contains a member
+.Em ni_erootdir
+that may be set to the emulation root directory before the call if
+the
+.Dv EMULROOTSET
+flag is also set and
+.Dv TRYEMULROOT
+is in effect.
+This is only necessary (or allowed) if the emulation root is not yet
+set in the current process.
+.It
+It contains a member
+.Em ni_vp
+that upon successful return contains the result vnode.
+.It
+It contains a member
+.Em ni_dvp
+that upon successful return contains the vnode of the directory
+containing the result vnode or
+.Dv NULL .
+If the
+.Dv LOCKPARENT
+flag is set, the containing vnode is returned; otherwise this field is
+left set to
+.Dv NULL .
+.It
+It contains a member
+.Em ni_cnd
+that is a
+.Em componentname
+structure (described in just a moment).
+This may be used by callers to pass to certain vnode operations that
+operate on pathnames.
+.El
+.Pp
+The other fields in the structure should not be examined or altered
+directly.
+Note that the
+.Xr nfs 4
+code misuses the
+.Em 

CVS commit: src/share/man/man9

2016-05-05 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Fri May  6 04:55:10 UTC 2016

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

Log Message:
Revise/update. List the functions in a sensible order. Document all
the modes and flags. Document the structure fields properly.
Distinguish internals from public interfaces. Mention historic dead
flags like SAVESTART because they still exist in other projects.
Explain the current layout of vfs_lookup.c, or at least the primary
points of it.

Etc.

This ended up being a much larger rewrite than I intended.

Bump date again.


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/share/man/man9/namei.9

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



CVS commit: src/sys/dev/ic

2016-05-05 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Fri May  6 04:46:17 UTC 2016

Modified Files:
src/sys/dev/ic: wdc.c

Log Message:
KNF. No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.280 -r1.281 src/sys/dev/ic/wdc.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/ic/wdc.c
diff -u src/sys/dev/ic/wdc.c:1.280 src/sys/dev/ic/wdc.c:1.281
--- src/sys/dev/ic/wdc.c:1.280	Mon Jan 18 04:46:47 2016
+++ src/sys/dev/ic/wdc.c	Fri May  6 04:46:17 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: wdc.c,v 1.280 2016/01/18 04:46:47 msaitoh Exp $ */
+/*	$NetBSD: wdc.c,v 1.281 2016/05/06 04:46:17 msaitoh Exp $ */
 
 /*
  * Copyright (c) 1998, 2001, 2003 Manuel Bouyer.  All rights reserved.
@@ -58,7 +58,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: wdc.c,v 1.280 2016/01/18 04:46:47 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: wdc.c,v 1.281 2016/05/06 04:46:17 msaitoh Exp $");
 
 #include "opt_ata.h"
 #include "opt_wdc.h"
@@ -989,10 +989,8 @@ wdc_reset_channel(struct ata_channel *ch
  * DMA engine
  */
 if (chp->ch_flags & ATACH_DMA_WAIT) {
-	(*wdc->dma_finish)(
-	wdc->dma_arg,
-	chp->ch_channel,
-	xfer->c_drive,
+	(*wdc->dma_finish)(wdc->dma_arg,
+	chp->ch_channel, xfer->c_drive,
 	WDC_DMAEND_ABRT_QUIET);
 	chp->ch_flags &= ~ATACH_DMA_WAIT;
 }
@@ -1027,10 +1025,11 @@ wdcreset(struct ata_channel *chp, int po
 #endif
 	wdc->reset(chp, poll);
 
-	drv_mask1 = (chp->ch_drive[0].drive_type !=  ATA_DRIVET_NONE) ? 0x01:0x00;
+	drv_mask1 = (chp->ch_drive[0].drive_type !=  ATA_DRIVET_NONE)
+	? 0x01 : 0x00;
 	if (chp->ch_ndrives > 1) 
-		drv_mask1 |=
-		(chp->ch_drive[1].drive_type != ATA_DRIVET_NONE) ? 0x02:0x00;
+		drv_mask1 |= (chp->ch_drive[1].drive_type != ATA_DRIVET_NONE)
+		? 0x02 : 0x00;
 	drv_mask2 = __wdcwait_reset(chp, drv_mask1,
 	(poll == RESET_SLEEP) ? 0 : 1);
 	if (drv_mask2 != drv_mask1) {
@@ -1336,15 +1335,13 @@ wdctimeout(void *arg)
 	if ((chp->ch_flags & ATACH_IRQ_WAIT) != 0) {
 		__wdcerror(chp, "lost interrupt");
 		printf("\ttype: %s tc_bcount: %d tc_skip: %d\n",
-		(xfer->c_flags & C_ATAPI) ?  "atapi" : "ata",
-		xfer->c_bcount,
-		xfer->c_skip);
+		(xfer->c_flags & C_ATAPI) ? "atapi" : "ata",
+		xfer->c_bcount, xfer->c_skip);
 #if NATA_DMA || NATA_PIOBM
 		if (chp->ch_flags & ATACH_DMA_WAIT) {
 			wdc->dma_status =
-			(*wdc->dma_finish)(wdc->dma_arg,
-chp->ch_channel, xfer->c_drive,
-WDC_DMAEND_ABRT);
+			(*wdc->dma_finish)(wdc->dma_arg, chp->ch_channel,
+xfer->c_drive, WDC_DMAEND_ABRT);
 			chp->ch_flags &= ~ATACH_DMA_WAIT;
 		}
 #endif
@@ -1432,8 +1429,7 @@ __wdccommand_start(struct ata_channel *c
 
 	ATADEBUG_PRINT(("__wdccommand_start %s:%d:%d\n",
 	device_xname(chp->ch_atac->atac_dev), chp->ch_channel,
-	xfer->c_drive),
-	DEBUG_FUNCS);
+	xfer->c_drive), DEBUG_FUNCS);
 
 	if (wdc->select)
 		wdc->select(chp,drive);



CVS commit: src/sys/dev/ic

2016-05-05 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Fri May  6 04:46:17 UTC 2016

Modified Files:
src/sys/dev/ic: wdc.c

Log Message:
KNF. No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.280 -r1.281 src/sys/dev/ic/wdc.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/man4

2016-05-05 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Fri May  6 03:04:14 UTC 2016

Modified Files:
src/share/man/man4: rnd.4

Log Message:
Correct rc.conf variable for random seed.

Note that it is enabled by default.


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/share/man/man4/rnd.4

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



CVS commit: src/share/man/man4

2016-05-05 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Fri May  6 03:04:14 UTC 2016

Modified Files:
src/share/man/man4: rnd.4

Log Message:
Correct rc.conf variable for random seed.

Note that it is enabled by default.


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/share/man/man4/rnd.4

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/man4/rnd.4
diff -u src/share/man/man4/rnd.4:1.22 src/share/man/man4/rnd.4:1.23
--- src/share/man/man4/rnd.4:1.22	Mon Apr 13 22:23:54 2015
+++ src/share/man/man4/rnd.4	Fri May  6 03:04:14 2016
@@ -1,4 +1,4 @@
-.\"	$NetBSD: rnd.4,v 1.22 2015/04/13 22:23:54 riastradh Exp $
+.\"	$NetBSD: rnd.4,v 1.23 2016/05/06 03:04:14 riastradh Exp $
 .\"
 .\" Copyright (c) 2014 The NetBSD Foundation, Inc.
 .\" All rights reserved.
@@ -199,10 +199,10 @@ kernel has started.
 For those that don't, the
 .Xr rndctl 8
 command can do it once userland has started, for example by setting
-.Dq Va rndctl=YES
+.Dq Va random_seed=YES
 in
-.Pa /etc/rc.conf ;
-see
+.Pa /etc/rc.conf ,
+which is enabled by default; see
 .Xr rc.conf 5 .
 .Sh LIMITATIONS
 Some people worry about recovery from state compromise -- that is,



CVS commit: src/sbin

2016-05-05 Thread Pierre Pronchery
Module Name:src
Committed By:   khorben
Date:   Fri May  6 00:24:45 UTC 2016

Modified Files:
src/sbin/modload: main.c
src/sbin/modunload: main.c

Log Message:
More friendly error messages for modload(8) and modunload(8)

Tested on NetBSD/amd64.

>From Christian Koch (cfkoch@) of EdgeBSD; thanks!


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sbin/modload/main.c
cvs rdiff -u -r1.4 -r1.5 src/sbin/modunload/main.c

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



CVS commit: src/sbin

2016-05-05 Thread Pierre Pronchery
Module Name:src
Committed By:   khorben
Date:   Fri May  6 00:24:45 UTC 2016

Modified Files:
src/sbin/modload: main.c
src/sbin/modunload: main.c

Log Message:
More friendly error messages for modload(8) and modunload(8)

Tested on NetBSD/amd64.

>From Christian Koch (cfkoch@) of EdgeBSD; thanks!


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sbin/modload/main.c
cvs rdiff -u -r1.4 -r1.5 src/sbin/modunload/main.c

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

Modified files:

Index: src/sbin/modload/main.c
diff -u src/sbin/modload/main.c:1.15 src/sbin/modload/main.c:1.16
--- src/sbin/modload/main.c:1.15	Thu Feb  7 12:04:01 2013
+++ src/sbin/modload/main.c	Fri May  6 00:24:45 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: main.c,v 1.15 2013/02/07 12:04:01 apb Exp $	*/
+/*	$NetBSD: main.c,v 1.16 2016/05/06 00:24:45 khorben Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -28,7 +28,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: main.c,v 1.15 2013/02/07 12:04:01 apb Exp $");
+__RCSID("$NetBSD: main.c,v 1.16 2016/05/06 00:24:45 khorben Exp $");
 #endif /* !lint */
 
 #include 
@@ -170,7 +170,7 @@ main(int argc, char **argv)
 		cmdargs.ml_propslen = strlen(propsstr);
 
 		if (prog_modctl(MODCTL_LOAD, )) {
-			err(EXIT_FAILURE, NULL);
+			err(EXIT_FAILURE, "%s", cmdargs.ml_filename);
 		}
 	}
 

Index: src/sbin/modunload/main.c
diff -u src/sbin/modunload/main.c:1.4 src/sbin/modunload/main.c:1.5
--- src/sbin/modunload/main.c:1.4	Mon Dec 13 20:48:45 2010
+++ src/sbin/modunload/main.c	Fri May  6 00:24:45 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: main.c,v 1.4 2010/12/13 20:48:45 pooka Exp $	*/
+/*	$NetBSD: main.c,v 1.5 2016/05/06 00:24:45 khorben Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -28,7 +28,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: main.c,v 1.4 2010/12/13 20:48:45 pooka Exp $");
+__RCSID("$NetBSD: main.c,v 1.5 2016/05/06 00:24:45 khorben Exp $");
 #endif /* !lint */
 
 #include 
@@ -57,7 +57,7 @@ main(int argc, char **argv)
 
 	for (i = 1; i < argc; i++) {
 		if (prog_modctl(MODCTL_UNLOAD, argv[i])) {
-			err(EXIT_FAILURE, NULL);
+			err(EXIT_FAILURE, "%s", argv[i]);
 		}
 	}
 



CVS commit: src/sys/arch

2016-05-05 Thread Robert Swindells
Module Name:src
Committed By:   rjs
Date:   Thu May  5 21:14:15 UTC 2016

Modified Files:
src/sys/arch/aarch64/conf: Makefile.aarch64
src/sys/arch/evbarm64/conf: std.a64emul std.evbarm64

Log Message:
Fix config(1) errors and warnings.

Set up arm headers for the build.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/aarch64/conf/Makefile.aarch64
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/evbarm64/conf/std.a64emul
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/evbarm64/conf/std.evbarm64

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/conf/Makefile.aarch64
diff -u src/sys/arch/aarch64/conf/Makefile.aarch64:1.6 src/sys/arch/aarch64/conf/Makefile.aarch64:1.7
--- src/sys/arch/aarch64/conf/Makefile.aarch64:1.6	Mon Aug 24 14:04:24 2015
+++ src/sys/arch/aarch64/conf/Makefile.aarch64	Thu May  5 21:14:14 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.aarch64,v 1.6 2015/08/24 14:04:24 uebayasi Exp $
+#	$NetBSD: Makefile.aarch64,v 1.7 2016/05/05 21:14:14 rjs Exp $
 
 # Makefile for NetBSD
 #
@@ -88,6 +88,16 @@ spl.o vectors.o: assym.h
 ## (7) misc settings
 ##
 
+# define .MAIN _before_ the make() check, so that implicit target
+# would be defined
+.MAIN: all
+
+.if make(depend) || make(all) || make(dependall)
+.BEGIN:
+	@rm -f arm && \
+		ln -s $S/arch/arm/include arm
+.endif
+
 ##
 ## (8) config(8) generated machinery
 ##

Index: src/sys/arch/evbarm64/conf/std.a64emul
diff -u src/sys/arch/evbarm64/conf/std.a64emul:1.1 src/sys/arch/evbarm64/conf/std.a64emul:1.2
--- src/sys/arch/evbarm64/conf/std.a64emul:1.1	Sun Aug 10 05:47:38 2014
+++ src/sys/arch/evbarm64/conf/std.a64emul	Thu May  5 21:14:15 2016
@@ -1,6 +1,6 @@
-# $NetBSD: std.a64emul,v 1.1 2014/08/10 05:47:38 matt Exp $
+# $NetBSD: std.a64emul,v 1.2 2016/05/05 21:14:15 rjs Exp $
 
-machine evbarm64 aarch64 arm
+machine evbarm64 aarch64
 maxpartitions	16
 
 include "arch/evbarm64/conf/std.evbarm64"

Index: src/sys/arch/evbarm64/conf/std.evbarm64
diff -u src/sys/arch/evbarm64/conf/std.evbarm64:1.2 src/sys/arch/evbarm64/conf/std.evbarm64:1.3
--- src/sys/arch/evbarm64/conf/std.evbarm64:1.2	Thu May  7 19:14:56 2015
+++ src/sys/arch/evbarm64/conf/std.evbarm64	Thu May  5 21:14:15 2016
@@ -1,7 +1,5 @@
-#	$NetBSD: std.evbarm64,v 1.2 2015/05/07 19:14:56 mrg Exp $
+#	$NetBSD: std.evbarm64,v 1.3 2016/05/05 21:14:15 rjs Exp $
 
 include		"conf/std"
 include		"arch/aarch64/conf/std.aarch64"	# arch standard options
 
-options 	CHILD_MAX=1024	# 160 is too few
-options 	OPEN_MAX=1024	# 128 is too few



CVS commit: src/sys/arch

2016-05-05 Thread Robert Swindells
Module Name:src
Committed By:   rjs
Date:   Thu May  5 21:14:15 UTC 2016

Modified Files:
src/sys/arch/aarch64/conf: Makefile.aarch64
src/sys/arch/evbarm64/conf: std.a64emul std.evbarm64

Log Message:
Fix config(1) errors and warnings.

Set up arm headers for the build.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/aarch64/conf/Makefile.aarch64
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/evbarm64/conf/std.a64emul
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/evbarm64/conf/std.evbarm64

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



CVS commit: src/tests/dev/usb

2016-05-05 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu May  5 17:40:26 UTC 2016

Modified Files:
src/tests/dev/usb: t_hid.c

Log Message:
Use rump_schedule() before calling things in the rump context.
Hopefully fixes these tests on all ports.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/tests/dev/usb/t_hid.c

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

Modified files:

Index: src/tests/dev/usb/t_hid.c
diff -u src/tests/dev/usb/t_hid.c:1.7 src/tests/dev/usb/t_hid.c:1.8
--- src/tests/dev/usb/t_hid.c:1.7	Thu May  5 16:55:56 2016
+++ src/tests/dev/usb/t_hid.c	Thu May  5 17:40:26 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: t_hid.c,v 1.7 2016/05/05 16:55:56 jakllsch Exp $	*/
+/*	$NetBSD: t_hid.c,v 1.8 2016/05/05 17:40:26 jakllsch Exp $	*/
 
 /*
  * Copyright (c) 2016 Jonathan A. Kollasch
@@ -27,7 +27,7 @@
  */
 
 #include 
-__RCSID("$NetBSD: t_hid.c,v 1.7 2016/05/05 16:55:56 jakllsch Exp $");
+__RCSID("$NetBSD: t_hid.c,v 1.8 2016/05/05 17:40:26 jakllsch Exp $");
 
 #include 
 #include 
@@ -105,12 +105,12 @@ ATF_TC_BODY(khid, tc)
 	int ret;
 	struct hid_item hi;
 
-	atf_tc_expect_fail("test case does not use rump correctly");
-
 	uhidevdebug = 0;
 
 	rump_init();
 
+	rump_schedule();
+
 	ret = locate_item(range_test_report_descriptor,
 	sizeof(range_test_report_descriptor), 0xff03, 0, hid_input,
 	);
@@ -225,6 +225,8 @@ ATF_TC_BODY(khid, tc)
 	), 0xfe);
 	MYlx_ATF_CHECK_EQ(hid_get_udata(unsigned_range_test_maximum_report,
 	), 0xff);
+
+	rump_unschedule();
 }
 
 ATF_TC(khid_parse_just_pop);
@@ -241,15 +243,17 @@ ATF_TC_BODY(khid_parse_just_pop, tc)
 	struct hid_data *hdp;
 	struct hid_item hi;
 
-	atf_tc_expect_fail("test case does not use rump correctly");
-
 	rump_init();
 
+	rump_schedule();
+
 	hdp = hid_start_parse(just_pop_report_descriptor,
 	sizeof just_pop_report_descriptor, hid_none);
 	while (hid_get_item(hdp, ) > 0) {
 	}
 	hid_end_parse(hdp);
+
+	rump_unschedule();
 }
 
 ATF_TP_ADD_TCS(tp)



CVS commit: src/tests/dev/usb

2016-05-05 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu May  5 17:40:26 UTC 2016

Modified Files:
src/tests/dev/usb: t_hid.c

Log Message:
Use rump_schedule() before calling things in the rump context.
Hopefully fixes these tests on all ports.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/tests/dev/usb/t_hid.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

2016-05-05 Thread Guilherme Salazar
Module Name:src
Committed By:   salazar
Date:   Thu May  5 17:06:41 UTC 2016

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

Log Message:
update struct nameidata documentation


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/share/man/man9/namei.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

2016-05-05 Thread Guilherme Salazar
Module Name:src
Committed By:   salazar
Date:   Thu May  5 17:06:41 UTC 2016

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

Log Message:
update struct nameidata documentation


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/share/man/man9/namei.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/namei.9
diff -u src/share/man/man9/namei.9:1.34 src/share/man/man9/namei.9:1.35
--- src/share/man/man9/namei.9:1.34	Tue Apr 21 10:00:30 2015
+++ src/share/man/man9/namei.9	Thu May  5 17:06:41 2016
@@ -1,4 +1,4 @@
-.\" $NetBSD: namei.9,v 1.34 2015/04/21 10:00:30 wiz Exp $
+.\" $NetBSD: namei.9,v 1.35 2016/05/05 17:06:41 salazar Exp $
 .\"
 .\" Copyright (c) 2001, 2005, 2006 The NetBSD Foundation, Inc.
 .\" All rights reserved.
@@ -27,7 +27,7 @@
 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\" POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd April 21, 2015
+.Dd May 05, 2016
 .Dt NAMEI 9
 .Os
 .Sh NAME
@@ -84,45 +84,54 @@ structure.
 It has the following layout:
 .Bd -literal
 struct nameidata {
-/*
- * Arguments to namei/lookup.
- */
-struct vnode *ni_startdir;  /* starting dir, cwd if null */
-struct pathbuf *ni_pathbuf; /* pathname container */
-char *ni_pnbuf; /* extra pathname buffer ref (XXX) */
-/*
- * Arguments to lookup.
- */
-struct  vnode *ni_startdir; /* starting directory */
-struct  vnode *ni_rootdir;  /* logical root directory */
-/*
- * Results: returned from/manipulated by lookup
- */
-struct  vnode *ni_vp;   /* vnode of result */
-struct  vnode *ni_dvp;  /* vnode of intermediate dir */
-/*
- * Shared between namei and lookup/commit routines.
- */
-size_t ni_pathlen;  /* remaining chars in path */
-const char *ni_next;/* next location in pathname */
-unsigned int ni_loopcnt;/* count of symlinks encountered */
-/*
- * Lookup parameters
- */
-struct componentname {
-/*
- * Arguments to lookup.
- */
-uint32_t cn_nameiop;/* namei operation */
-uint32_t cn_flags;  /* flags to namei */
-kauth_cred_t cn_cred;   /* credentials */
-/*
- * Shared between lookup and commit routines.
- */
-const char *cn_nameptr; /* pointer to looked up name */
-size_t cn_namelen;  /* length of looked up component */
-size_t cn_consume;  /* chars to be consumed this time */
-} ni_cnd;
+	/*
+	 * Arguments to namei/lookup.
+	 */
+	struct vnode *ni_atdir;		/* startup dir, cwd if null */
+	struct pathbuf *ni_pathbuf;	/* pathname container */
+	char *ni_pnbuf;			/* extra pathname buffer ref (XXX) */
+	/*
+	 * Arguments to lookup.
+	 */
+	struct	vnode *ni_rootdir;	/* logical root directory */
+	struct	vnode *ni_erootdir;	/* emulation root directory */
+	/*
+	 * Results: returned from/manipulated by lookup
+	 */
+	struct	vnode *ni_vp;		/* vnode of result */
+	struct	vnode *ni_dvp;		/* vnode of intermediate directory */
+	/*
+	 * Shared between namei and lookup/commit routines.
+	 */
+	size_t		ni_pathlen;	/* remaining chars in path */
+	const char	*ni_next;	/* next location in pathname */
+	unsigned int	ni_loopcnt;	/* count of symlinks encountered */
+	/*
+	 * Lookup parameters: this structure describes the subset of
+	 * information from the nameidata structure that is passed
+	 * through the VOP interface.
+	 */
+	struct componentname ni_cnd;
+};
+.Ed
+.Pp
+The
+.Em componentname
+structure has the following layout:
+.Bd -literal
+struct componentname {
+	/*
+	 * Arguments to lookup.
+	 */
+	uint32_t	cn_nameiop;	/* namei operation */
+	uint32_t	cn_flags;	/* flags to namei */
+	kauth_cred_t 	cn_cred;	/* credentials */
+	/*
+	 * Shared between lookup and commit routines.
+	 */
+	const char 	*cn_nameptr;	/* pointer to looked up name */
+	size_t		cn_namelen;	/* length of looked up comp */
+	size_t		cn_consume;	/* chars to consume in lookup */
 };
 .Ed
 .Pp



CVS commit: src/tests/dev/usb

2016-05-05 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu May  5 16:55:56 UTC 2016

Modified Files:
src/tests/dev/usb: t_hid.c

Log Message:
t_hid doesn't use rump correctly, and thus consistently fails; mark as such


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/tests/dev/usb/t_hid.c

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



CVS commit: src/tests/dev/usb

2016-05-05 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu May  5 16:55:56 UTC 2016

Modified Files:
src/tests/dev/usb: t_hid.c

Log Message:
t_hid doesn't use rump correctly, and thus consistently fails; mark as such


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/tests/dev/usb/t_hid.c

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

Modified files:

Index: src/tests/dev/usb/t_hid.c
diff -u src/tests/dev/usb/t_hid.c:1.6 src/tests/dev/usb/t_hid.c:1.7
--- src/tests/dev/usb/t_hid.c:1.6	Mon May  2 17:24:06 2016
+++ src/tests/dev/usb/t_hid.c	Thu May  5 16:55:56 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: t_hid.c,v 1.6 2016/05/02 17:24:06 jakllsch Exp $	*/
+/*	$NetBSD: t_hid.c,v 1.7 2016/05/05 16:55:56 jakllsch Exp $	*/
 
 /*
  * Copyright (c) 2016 Jonathan A. Kollasch
@@ -27,7 +27,7 @@
  */
 
 #include 
-__RCSID("$NetBSD: t_hid.c,v 1.6 2016/05/02 17:24:06 jakllsch Exp $");
+__RCSID("$NetBSD: t_hid.c,v 1.7 2016/05/05 16:55:56 jakllsch Exp $");
 
 #include 
 #include 
@@ -105,6 +105,8 @@ ATF_TC_BODY(khid, tc)
 	int ret;
 	struct hid_item hi;
 
+	atf_tc_expect_fail("test case does not use rump correctly");
+
 	uhidevdebug = 0;
 
 	rump_init();
@@ -239,6 +241,8 @@ ATF_TC_BODY(khid_parse_just_pop, tc)
 	struct hid_data *hdp;
 	struct hid_item hi;
 
+	atf_tc_expect_fail("test case does not use rump correctly");
+
 	rump_init();
 
 	hdp = hid_start_parse(just_pop_report_descriptor,



CVS commit: src/doc/roadmaps

2016-05-05 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Thu May  5 06:17:45 UTC 2016

Modified Files:
src/doc/roadmaps: storage

Log Message:
mention some of the other known severe wapbl problems


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/doc/roadmaps/storage

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

Modified files:

Index: src/doc/roadmaps/storage
diff -u src/doc/roadmaps/storage:1.12 src/doc/roadmaps/storage:1.13
--- src/doc/roadmaps/storage:1.12	Sun May  1 20:51:36 2016
+++ src/doc/roadmaps/storage	Thu May  5 06:17:45 2016
@@ -1,4 +1,4 @@
-$NetBSD: storage,v 1.12 2016/05/01 20:51:36 dholland Exp $
+$NetBSD: storage,v 1.13 2016/05/05 06:17:45 dholland Exp $
 
 NetBSD Storage Roadmap
 ==
@@ -90,7 +90,10 @@ best option at this point is:
 
 + Fixing WAPBL (e.g. to flush newly allocated/newly written blocks to
 disk early) has been examined by several people who know the code base
-and judged difficult. Still, it might be the best way forward.
+and judged difficult. Also, some other problems have come to light
+more recently; e.g. PR 50725, PR 47146, and a problem where truncating
+large sparse files takes ~forever. Also see PR 45676. Still, it might
+be the best way forward.
 
 + There is another journaling FFS; the Harvard one done by Margo
 Seltzer's group some years back. We have a copy of this, but as it was



CVS commit: src/doc/roadmaps

2016-05-05 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Thu May  5 06:17:45 UTC 2016

Modified Files:
src/doc/roadmaps: storage

Log Message:
mention some of the other known severe wapbl problems


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/doc/roadmaps/storage

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