CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 05:09:12 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_alloc.c

Log Message:
Remove unused 


To generate a diff of this commit:
cvs rdiff -u -r1.132 -r1.133 src/sys/ufs/lfs/lfs_alloc.c

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



CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 05:09:12 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_alloc.c

Log Message:
Remove unused 


To generate a diff of this commit:
cvs rdiff -u -r1.132 -r1.133 src/sys/ufs/lfs/lfs_alloc.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/ufs/lfs/lfs_alloc.c
diff -u src/sys/ufs/lfs/lfs_alloc.c:1.132 src/sys/ufs/lfs/lfs_alloc.c:1.133
--- src/sys/ufs/lfs/lfs_alloc.c:1.132	Sun Aug  7 00:12:48 2016
+++ src/sys/ufs/lfs/lfs_alloc.c	Sun Aug  7 05:09:12 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: lfs_alloc.c,v 1.132 2016/08/07 00:12:48 dholland Exp $	*/
+/*	$NetBSD: lfs_alloc.c,v 1.133 2016/08/07 05:09:12 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2001, 2002, 2003, 2007 The NetBSD Foundation, Inc.
@@ -60,7 +60,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: lfs_alloc.c,v 1.132 2016/08/07 00:12:48 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: lfs_alloc.c,v 1.133 2016/08/07 05:09:12 dholland Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_quota.h"
@@ -77,7 +77,6 @@ __KERNEL_RCSID(0, "$NetBSD: lfs_alloc.c,
 #include 
 #include 
 #include 
-#include 
 #include 
 
 #include 



CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 02:42:32 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_balloc.c

Log Message:
Fix stupid thinko.


To generate a diff of this commit:
cvs rdiff -u -r1.90 -r1.91 src/sys/ufs/lfs/lfs_balloc.c

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



CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 02:42:32 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_balloc.c

Log Message:
Fix stupid thinko.


To generate a diff of this commit:
cvs rdiff -u -r1.90 -r1.91 src/sys/ufs/lfs/lfs_balloc.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/ufs/lfs/lfs_balloc.c
diff -u src/sys/ufs/lfs/lfs_balloc.c:1.90 src/sys/ufs/lfs/lfs_balloc.c:1.91
--- src/sys/ufs/lfs/lfs_balloc.c:1.90	Sun Aug  7 02:31:03 2016
+++ src/sys/ufs/lfs/lfs_balloc.c	Sun Aug  7 02:42:32 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: lfs_balloc.c,v 1.90 2016/08/07 02:31:03 dholland Exp $	*/
+/*	$NetBSD: lfs_balloc.c,v 1.91 2016/08/07 02:42:32 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@@ -60,7 +60,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: lfs_balloc.c,v 1.90 2016/08/07 02:31:03 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: lfs_balloc.c,v 1.91 2016/08/07 02:42:32 dholland Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_quota.h"
@@ -502,15 +502,15 @@ lfs_fragextend(struct vnode *vp, int osi
 	/* (XXX: except it's not clear what purpose it serves) */
 	extern long locked_queue_bytes;
 
+	ip = VTOI(vp);
+	fs = ip->i_lfs;
+
 	/*
 	 * XXX: is there some reason we know more about the seglock
 	 * state here than at the top of lfs_balloc?
 	 */
 	ASSERT_NO_SEGLOCK(fs);
 
-	ip = VTOI(vp);
-	fs = ip->i_lfs;
-
 	/* number of frags we're adding */
 	frags = (long)lfs_numfrags(fs, nsize - osize);
 



CVS commit: src/sys/dev

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sun Aug  7 02:40:41 UTC 2016

Modified Files:
src/sys/dev: ccd.c

Log Message:
Create the kern.ccd sysctl sub-tree when built as a module.  Even though
the contents of the sub-tree are all structures, and thus not displayed
via sysctl(8), the info is potentially useful to programs.  (For example,
ccdconfig could use this to determine how many units are available.)

The sub-tree is already available when the module is included as built-in
module.


To generate a diff of this commit:
cvs rdiff -u -r1.166 -r1.167 src/sys/dev/ccd.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

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sun Aug  7 02:40:41 UTC 2016

Modified Files:
src/sys/dev: ccd.c

Log Message:
Create the kern.ccd sysctl sub-tree when built as a module.  Even though
the contents of the sub-tree are all structures, and thus not displayed
via sysctl(8), the info is potentially useful to programs.  (For example,
ccdconfig could use this to determine how many units are available.)

The sub-tree is already available when the module is included as built-in
module.


To generate a diff of this commit:
cvs rdiff -u -r1.166 -r1.167 src/sys/dev/ccd.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/ccd.c
diff -u src/sys/dev/ccd.c:1.166 src/sys/dev/ccd.c:1.167
--- src/sys/dev/ccd.c:1.166	Tue Dec  8 20:36:14 2015
+++ src/sys/dev/ccd.c	Sun Aug  7 02:40:41 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ccd.c,v 1.166 2015/12/08 20:36:14 christos Exp $	*/
+/*	$NetBSD: ccd.c,v 1.167 2016/08/07 02:40:41 pgoyette Exp $	*/
 
 /*-
  * Copyright (c) 1996, 1997, 1998, 1999, 2007, 2009 The NetBSD Foundation, Inc.
@@ -88,7 +88,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ccd.c,v 1.166 2015/12/08 20:36:14 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ccd.c,v 1.167 2016/08/07 02:40:41 pgoyette Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -220,6 +220,12 @@ static LIST_HEAD(, ccd_softc) ccds = LIS
 static kmutex_t ccd_lock;
 static size_t ccd_nactive = 0;
 
+#ifdef _MODULE
+static struct sysctllog *ccd_clog;
+#endif
+
+SYSCTL_SETUP_PROTO(sysctl_kern_ccd_setup);
+
 static struct ccd_softc *
 ccdcreate(int unit) {
 	struct ccd_softc *sc = kmem_zalloc(sizeof(*sc), KM_SLEEP);
@@ -1665,6 +1671,7 @@ ccd_modcmd(modcmd_t cmd, void *arg)
 
 		error = devsw_attach("ccd", _bdevsw, ,
 		_cdevsw, );
+		sysctl_kern_ccd_setup(_clog);
 #endif
 		break;
 
@@ -1679,6 +1686,7 @@ ccd_modcmd(modcmd_t cmd, void *arg)
 			error = devsw_detach(_bdevsw, _cdevsw);
 			ccddetach();
 		}
+		sysctl_teardown(_clog);
 #endif
 		break;
 



CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 02:31:03 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_balloc.c

Log Message:
comments


To generate a diff of this commit:
cvs rdiff -u -r1.89 -r1.90 src/sys/ufs/lfs/lfs_balloc.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/ufs/lfs/lfs_balloc.c
diff -u src/sys/ufs/lfs/lfs_balloc.c:1.89 src/sys/ufs/lfs/lfs_balloc.c:1.90
--- src/sys/ufs/lfs/lfs_balloc.c:1.89	Sun Aug  7 00:25:22 2016
+++ src/sys/ufs/lfs/lfs_balloc.c	Sun Aug  7 02:31:03 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: lfs_balloc.c,v 1.89 2016/08/07 00:25:22 dholland Exp $	*/
+/*	$NetBSD: lfs_balloc.c,v 1.90 2016/08/07 02:31:03 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@@ -60,7 +60,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: lfs_balloc.c,v 1.89 2016/08/07 00:25:22 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: lfs_balloc.c,v 1.90 2016/08/07 02:31:03 dholland Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_quota.h"
@@ -97,17 +97,23 @@ static int lfs_fragextend(struct vnode *
 u_int64_t locked_fakequeue_count;
 
 /*
- * Allocate a block, and to inode and filesystem block accounting for it
- * and for any indirect blocks the may need to be created in order for
- * this block to be created.
- *
- * Blocks which have never been accounted for (i.e., which "do not exist")
- * have disk address 0, which is translated by ulfs_bmap to the special value
- * UNASSIGNED == -1, as in the historical ULFS.
- *
- * Blocks which have been accounted for but which have not yet been written
- * to disk are given the new special disk address UNWRITTEN == -2, so that
- * they can be differentiated from completely new blocks.
+ * Allocate a block, and do inode and filesystem block accounting for
+ * it and for any indirect blocks that may need to be created in order
+ * to handle this block.
+ *
+ * Blocks which have never been accounted for (i.e., which "do not
+ * exist") have disk address 0, which is translated by ulfs_bmap to
+ * the special value UNASSIGNED == -1, as in historical FFS-related
+ * code.
+ *
+ * Blocks which have been accounted for but which have not yet been
+ * written to disk are given the new special disk address UNWRITTEN ==
+ * -2, so that they can be differentiated from completely new blocks.
+ *
+ * Note: it seems that bpp is passed as NULL for blocks that are file
+ * pages that will be handled by UVM and not the buffer cache.
+ *
+ * XXX: locking?
  */
 /* VOP_BWRITE ULFS_NIADDR+2 times */
 int
@@ -126,12 +132,27 @@ lfs_balloc(struct vnode *vp, off_t start
 
 	ip = VTOI(vp);
 	fs = ip->i_lfs;
+
+	/* Declare to humans that we might have the seglock here */
+	ASSERT_MAYBE_SEGLOCK(fs);
+
+
+	/* offset within block */
 	offset = lfs_blkoff(fs, startoffset);
+
+	/* This is usually but not always exactly the block size */
 	KASSERT(iosize <= lfs_sb_getbsize(fs));
+
+	/* block number (within file) */
 	lbn = lfs_lblkno(fs, startoffset);
+
+	/*
+	 * This checks for whether pending stuff needs to be flushed
+	 * out and potentially waits. It's been disabled since UBC
+	 * support was added to LFS in 2003. -- dholland 20160806
+	 */
 	/* (void)lfs_check(vp, lbn, 0); */
 
-	ASSERT_MAYBE_SEGLOCK(fs);
 
 	/*
 	 * Three cases: it's a block beyond the end of file, it's a block in
@@ -152,19 +173,29 @@ lfs_balloc(struct vnode *vp, off_t start
 	if (bpp)
 		*bpp = NULL;
 
-	/* Check for block beyond end of file and fragment extension needed. */
+	/* Last block number in file */
 	lastblock = lfs_lblkno(fs, ip->i_size);
+
 	if (lastblock < ULFS_NDADDR && lastblock < lbn) {
+		/*
+		 * The file is small enough to have fragments, and we're
+		 * allocating past EOF.
+		 *
+		 * If the last block was a fragment we need to rewrite it
+		 * as a full block.
+		 */
 		osize = lfs_blksize(fs, ip, lastblock);
 		if (osize < lfs_sb_getbsize(fs) && osize > 0) {
 			if ((error = lfs_fragextend(vp, osize, lfs_sb_getbsize(fs),
 		lastblock,
 		(bpp ?  : NULL), cred)))
 return (error);
+			/* Update the file size with what we just did (only) */
 			ip->i_size = (lastblock + 1) * lfs_sb_getbsize(fs);
 			lfs_dino_setsize(fs, ip->i_din, ip->i_size);
 			uvm_vnp_setsize(vp, ip->i_size);
 			ip->i_flag |= IN_CHANGE | IN_UPDATE;
+			/* if we got a buffer for this, write it out now */
 			if (bpp)
 (void) VOP_BWRITE(bp->b_vp, bp);
 		}
@@ -192,12 +223,24 @@ lfs_balloc(struct vnode *vp, off_t start
 if (flags & B_CLRBUF)
 	clrbuf(bp);
 			}
+
+			/*
+			 * Update the effective block count (this count
+			 * includes blocks that don't have an on-disk
+			 * presence or location yet)
+			 */
 			ip->i_lfs_effnblks += frags;
+
+			/* account for the space we're taking */
 			mutex_enter(_lock);
 			lfs_s

CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 02:31:03 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_balloc.c

Log Message:
comments


To generate a diff of this commit:
cvs rdiff -u -r1.89 -r1.90 src/sys/ufs/lfs/lfs_balloc.c

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



CVS commit: src

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sun Aug  7 01:59:43 UTC 2016

Modified Files:
src/share/man/man4: pppoe.4
src/sys/modules/if_pppoe: Makefile
src/sys/net: if_pppoe.c

Log Message:
For modular configurations, always build with PPPOE_TERM_UNKNOWN_SESSIONS
defined, and provide a sysctl variable for enabling/disabling the option.

Update man page accordingly.


To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/share/man/man4/pppoe.4
cvs rdiff -u -r1.1 -r1.2 src/sys/modules/if_pppoe/Makefile
cvs rdiff -u -r1.112 -r1.113 src/sys/net/if_pppoe.c

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/pppoe.4
diff -u src/share/man/man4/pppoe.4:1.36 src/share/man/man4/pppoe.4:1.37
--- src/share/man/man4/pppoe.4:1.36	Thu Mar  1 09:08:19 2012
+++ src/share/man/man4/pppoe.4	Sun Aug  7 01:59:43 2016
@@ -1,4 +1,4 @@
-.\"	$NetBSD: pppoe.4,v 1.36 2012/03/01 09:08:19 wiz Exp $
+.\"	$NetBSD: pppoe.4,v 1.37 2016/08/07 01:59:43 pgoyette Exp $
 .\"
 .\" Copyright (c) 2002 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 February 24, 2012
+.Dd August 7, 2016
 .Dt PPPOE 4
 .Os
 .Sh NAME
@@ -263,6 +263,10 @@ To do this, add the following to your ke
 .Pp
 .Dl options PPPOE_TERM_UNKNOWN_SESSIONS
 .Pp
+and set the value of
+.Xr sysctl 7
+variable net.pppoe.term_unknown to true.
+.Pp
 Note that this will break all userland
 .Nm PPPoE
 implementations using the same Ethernet interface!

Index: src/sys/modules/if_pppoe/Makefile
diff -u src/sys/modules/if_pppoe/Makefile:1.1 src/sys/modules/if_pppoe/Makefile:1.2
--- src/sys/modules/if_pppoe/Makefile:1.1	Sat Aug  6 23:46:30 2016
+++ src/sys/modules/if_pppoe/Makefile	Sun Aug  7 01:59:43 2016
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2016/08/06 23:46:30 pgoyette Exp $
+# $NetBSD: Makefile,v 1.2 2016/08/07 01:59:43 pgoyette Exp $
 
 .include "../Makefile.inc"
 
@@ -9,7 +9,6 @@ IOCONF=		pppoe.ioconf
 SRCS=		if_pppoe.c
 
 CPPFLAGS+=	-DPPPOE_SERVER
-#CPPFLAGS+=	-DPPPOE_TERM_UNKNOWN_SESSIONS	# This should not be
-		# enabled by default
+CPPFLAGS+=	-DPPPOE_TERM_UNKNOWN_SESSIONS
 
 .include 

Index: src/sys/net/if_pppoe.c
diff -u src/sys/net/if_pppoe.c:1.112 src/sys/net/if_pppoe.c:1.113
--- src/sys/net/if_pppoe.c:1.112	Sat Aug  6 23:46:30 2016
+++ src/sys/net/if_pppoe.c	Sun Aug  7 01:59:43 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: if_pppoe.c,v 1.112 2016/08/06 23:46:30 pgoyette Exp $ */
+/* $NetBSD: if_pppoe.c,v 1.113 2016/08/07 01:59:43 pgoyette Exp $ */
 
 /*-
  * Copyright (c) 2002, 2008 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v 1.112 2016/08/06 23:46:30 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v 1.113 2016/08/07 01:59:43 pgoyette Exp $");
 
 #ifdef _KERNEL_OPT
 #include "pppoe.h"
@@ -51,6 +51,7 @@ __KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -204,6 +205,16 @@ static LIST_HEAD(pppoe_softc_head, pppoe
 static int	pppoe_clone_create(struct if_clone *, int);
 static int	pppoe_clone_destroy(struct ifnet *);
 
+#ifdef PPPOE_TERM_UNKNOWN_SESSIONS
+static bool	pppoe_term_unknown = false;
+#endif
+
+#ifdef _MODULE
+static struct sysctllog	*pppoe_sysctl_clog;
+#endif
+
+SYSCTL_SETUP_PROTO(sysctl_net_pppoe_setup);
+
 static struct if_clone pppoe_cloner =
 IF_CLONE_INITIALIZER("pppoe", pppoe_clone_create, pppoe_clone_destroy);
 
@@ -831,9 +842,11 @@ pppoe_data_input(struct mbuf *m)
 	sc = pppoe_find_softc_by_session(session, rcvif);
 	if (sc == NULL) {
 #ifdef PPPOE_TERM_UNKNOWN_SESSIONS
-		printf("pppoe: input for unknown session 0x%x, sending PADT\n",
-		session);
-		pppoe_send_padt(rcvif, session, shost);
+		if (pppoe_term_unknown) {
+			printf("pppoe: input for unknown session 0x%x, "
+			"sending PADT\n", session);
+			pppoe_send_padt(rcvif, session, shost);
+		}
 #endif
 		m_put_rcvif_psref(rcvif, );
 		goto drop;
@@ -1672,6 +1685,11 @@ if_pppoe_modcmd(modcmd_t cmd, void *arg)
 #endif  
 		/* Init the cloner etc. */
 		pppoeinit();
+
+#ifdef _MODULE
+		/* Create our sysctl subtree */
+		sysctl_net_pppoe_setup(_sysctl_clog);
+#endif
 		break;
 
 case MODULE_CMD_FINI:
@@ -1692,7 +1710,10 @@ if_pppoe_modcmd(modcmd_t cmd, void *arg)
 			"%d\n", __func__, pppoe_cd.cd_name, error);
 			break;
 		}
+		/* Remove our sysctl sub-tree */
+		sysctl_teardown(_sysctl_clog);
 #endif
+
 		break;
 	case MODULE_CMD_STAT:
 	case MODULE_CMD_AUTOUNLOAD:
@@ -1702,3 +1723,26 @@ if_pppoe_modcmd(modcmd_t cmd, void *arg)
 	return error;
 }
 
+SYSCTL_SETUP(sysctl_net_pppoe_setup, "sysctl net.pppoe subtree setup")
+{
+	const struct sysctlnode *node = NULL;
+
+	sysctl_createv(clog, 0, NULL, ,
+	CTLFLAG_PERMANENT,
+	CTLTYPE_NODE, "pppoe",
+	

CVS commit: src

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sun Aug  7 01:59:43 UTC 2016

Modified Files:
src/share/man/man4: pppoe.4
src/sys/modules/if_pppoe: Makefile
src/sys/net: if_pppoe.c

Log Message:
For modular configurations, always build with PPPOE_TERM_UNKNOWN_SESSIONS
defined, and provide a sysctl variable for enabling/disabling the option.

Update man page accordingly.


To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/share/man/man4/pppoe.4
cvs rdiff -u -r1.1 -r1.2 src/sys/modules/if_pppoe/Makefile
cvs rdiff -u -r1.112 -r1.113 src/sys/net/if_pppoe.c

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



CVS commit: src/sys/ufs/ext2fs

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 01:47:11 UTC 2016

Modified Files:
src/sys/ufs/ext2fs: ext2fs_dir.h

Log Message:
If using constants from dirent.h it ought to be included.
Hopefully fixes i386 build.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/ufs/ext2fs/ext2fs_dir.h

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



CVS commit: src/sys/ufs/ext2fs

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 01:47:11 UTC 2016

Modified Files:
src/sys/ufs/ext2fs: ext2fs_dir.h

Log Message:
If using constants from dirent.h it ought to be included.
Hopefully fixes i386 build.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/ufs/ext2fs/ext2fs_dir.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/ufs/ext2fs/ext2fs_dir.h
diff -u src/sys/ufs/ext2fs/ext2fs_dir.h:1.21 src/sys/ufs/ext2fs/ext2fs_dir.h:1.22
--- src/sys/ufs/ext2fs/ext2fs_dir.h:1.21	Sat Aug  6 21:39:48 2016
+++ src/sys/ufs/ext2fs/ext2fs_dir.h	Sun Aug  7 01:47:11 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ext2fs_dir.h,v 1.21 2016/08/06 21:39:48 jdolecek Exp $	*/
+/*	$NetBSD: ext2fs_dir.h,v 1.22 2016/08/07 01:47:11 kre Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1989, 1993
@@ -67,6 +67,7 @@
 #ifndef _UFS_EXT2FS_EXT2FS_DIR_H_
 #define	_UFS_EXT2FS_EXT2FS_DIR_H_
 
+#include 
 #include 
 
 /*



CVS commit: src/sys/arch

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 01:02:00 UTC 2016

Modified Files:
src/sys/arch/amd64/include: vmparam.h
src/sys/arch/i386/include: vmparam.h

Log Message:
Remove unused .


To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/sys/arch/amd64/include/vmparam.h
cvs rdiff -u -r1.81 -r1.82 src/sys/arch/i386/include/vmparam.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/amd64/include/vmparam.h
diff -u src/sys/arch/amd64/include/vmparam.h:1.36 src/sys/arch/amd64/include/vmparam.h:1.37
--- src/sys/arch/amd64/include/vmparam.h:1.36	Thu Jul 24 13:42:28 2014
+++ src/sys/arch/amd64/include/vmparam.h	Sun Aug  7 01:01:59 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmparam.h,v 1.36 2014/07/24 13:42:28 riastradh Exp $	*/
+/*	$NetBSD: vmparam.h,v 1.37 2016/08/07 01:01:59 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -39,7 +39,6 @@
 
 #ifdef __x86_64__
 
-#include 
 #include 
 #ifdef _KERNEL_OPT
 #include "opt_xen.h"

Index: src/sys/arch/i386/include/vmparam.h
diff -u src/sys/arch/i386/include/vmparam.h:1.81 src/sys/arch/i386/include/vmparam.h:1.82
--- src/sys/arch/i386/include/vmparam.h:1.81	Thu Jul 24 13:42:28 2014
+++ src/sys/arch/i386/include/vmparam.h	Sun Aug  7 01:02:00 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmparam.h,v 1.81 2014/07/24 13:42:28 riastradh Exp $	*/
+/*	$NetBSD: vmparam.h,v 1.82 2016/08/07 01:02:00 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -37,7 +37,6 @@
 #ifndef _I386_VMPARAM_H_
 #define _I386_VMPARAM_H_
 
-#include 
 #include 
 
 /*



CVS commit: src/sys/arch

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 01:02:00 UTC 2016

Modified Files:
src/sys/arch/amd64/include: vmparam.h
src/sys/arch/i386/include: vmparam.h

Log Message:
Remove unused .


To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/sys/arch/amd64/include/vmparam.h
cvs rdiff -u -r1.81 -r1.82 src/sys/arch/i386/include/vmparam.h

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



CVS commit: src/doc

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 00:56:02 UTC 2016

Modified Files:
src/doc: 3RDPARTY CHANGES

Log Message:
Note import of tzdata2016f


To generate a diff of this commit:
cvs rdiff -u -r1.1349 -r1.1350 src/doc/3RDPARTY
cvs rdiff -u -r1.2178 -r1.2179 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

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 00:56:02 UTC 2016

Modified Files:
src/doc: 3RDPARTY CHANGES

Log Message:
Note import of tzdata2016f


To generate a diff of this commit:
cvs rdiff -u -r1.1349 -r1.1350 src/doc/3RDPARTY
cvs rdiff -u -r1.2178 -r1.2179 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/3RDPARTY
diff -u src/doc/3RDPARTY:1.1349 src/doc/3RDPARTY:1.1350
--- src/doc/3RDPARTY:1.1349	Tue Aug  2 13:45:46 2016
+++ src/doc/3RDPARTY	Sun Aug  7 00:56:02 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: 3RDPARTY,v 1.1349 2016/08/02 13:45:46 christos Exp $
+#	$NetBSD: 3RDPARTY,v 1.1350 2016/08/07 00:56:02 kre Exp $
 #
 # This file contains a list of the software that has been integrated into
 # NetBSD where we are not the primary maintainer.
@@ -1384,8 +1384,8 @@ Notes:
 Added changes from a5 -> a12 manually.
 
 Package:	tz
-Version:	tzcode2016b / tzdata2016d
-Current Vers:	tzcode2016b / tzdata2016d
+Version:	tzcode2016b / tzdata2016f
+Current Vers:	tzcode2016f / tzdata2016f
 Maintainer:	Paul Eggert 
 Archive Site:	ftp://ftp.iana.org/tz/releases/
 Archive Site:	ftp://munnari.oz.au/pub/oldtz/

Index: src/doc/CHANGES
diff -u src/doc/CHANGES:1.2178 src/doc/CHANGES:1.2179
--- src/doc/CHANGES:1.2178	Tue Aug  2 13:45:46 2016
+++ src/doc/CHANGES	Sun Aug  7 00:56:02 2016
@@ -1,4 +1,4 @@
-# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2178 $>
+# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2179 $>
 #
 #
 # [Note: This file does not mention every change made to the NetBSD source tree.
@@ -337,3 +337,4 @@ Changes from NetBSD 7.0 to NetBSD 8.0:
 		CAT34TS04. [msaitoh 20160726]
 	sdtemp(4): Add JEDEC TSE2004av support. [msaitoh 20160728]
 	OpenSSH: Imported 7.3. [christos 20160802]
+	zoneinfo: Import tzdata2016f. [kre 20160807]



CVS commit: src/external/public-domain/tz/dist

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 00:49:54 UTC 2016

Modified Files:
src/external/public-domain/tz/dist: TZDATA_VERSION

Log Message:
Merge tzdata2016f


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/external/public-domain/tz/dist/TZDATA_VERSION

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

Modified files:

Index: src/external/public-domain/tz/dist/TZDATA_VERSION
diff -u src/external/public-domain/tz/dist/TZDATA_VERSION:1.1 src/external/public-domain/tz/dist/TZDATA_VERSION:1.2
--- src/external/public-domain/tz/dist/TZDATA_VERSION:1.1	Thu Jun 16 15:17:56 2016
+++ src/external/public-domain/tz/dist/TZDATA_VERSION	Sun Aug  7 00:49:54 2016
@@ -1 +1 @@
-tzdata-2016d
+tzdata-2016f



CVS commit: src/external/public-domain/tz/dist

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 00:49:54 UTC 2016

Modified Files:
src/external/public-domain/tz/dist: TZDATA_VERSION

Log Message:
Merge tzdata2016f


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/external/public-domain/tz/dist/TZDATA_VERSION

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



CVS import: src/external/public-domain/tz/dist

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 00:49:18 UTC 2016

Update of /cvsroot/src/external/public-domain/tz/dist
In directory ivanova.netbsd.org:/tmp/cvs-serv612

Log Message:
Import tzdata2016f from ftp://ftp.iana.org/tz/releases/tzdata2016f.tar.gz

Summary of changes in tzdata2016f (2016-07-05 16:26:51 +0200):
  * The Egyptian government changed its mind on short notice, and
Africa/Cairo will not introduce DST starting 2016-07-07 after all.
  * Asia/Novosibirsk switches from +06 to +07 on 2016-07-24 at 02:00.
  * Asia/Novokuznetsk and Asia/Novosibirsk now use numeric time zone
abbreviations instead of invented ones.
  * Europe/Minsk's 1992-03-29 spring-forward transition was at 02:00 not 00:00.

Summary of changes in tzdata2016e (2016-06-14 08:46:16 -0700):
  * Africa/Cairo observes DST in 2016 from July 7 to the end of October.
(change obsoleted by 2016f)
  * Locations while uninhabited now use '-00', not 'zzz', as a
placeholder time zone abbreviation.
  * Asia/Baku's 1992-09-27 transition from +04 (DST) to +04 (non-DST) was
at 03:00, not 23:00 the previous day.
  * zic now outputs a dummy transition at time 2**31 - 1 in zones
whose POSIX-style TZ strings contain a '<'.
  * Changes affecting documentation and commentary.

Status:

Vendor Tag: TZDATA
Release Tags:   TZDATA2016F

U src/external/public-domain/tz/dist/CONTRIBUTING
U src/external/public-domain/tz/dist/LICENSE
U src/external/public-domain/tz/dist/Makefile
U src/external/public-domain/tz/dist/NEWS
U src/external/public-domain/tz/dist/README
U src/external/public-domain/tz/dist/Theory
U src/external/public-domain/tz/dist/africa
U src/external/public-domain/tz/dist/antarctica
U src/external/public-domain/tz/dist/asia
U src/external/public-domain/tz/dist/australasia
U src/external/public-domain/tz/dist/europe
U src/external/public-domain/tz/dist/northamerica
U src/external/public-domain/tz/dist/southamerica
U src/external/public-domain/tz/dist/pacificnew
U src/external/public-domain/tz/dist/etcetera
U src/external/public-domain/tz/dist/backward
U src/external/public-domain/tz/dist/systemv
U src/external/public-domain/tz/dist/factory
U src/external/public-domain/tz/dist/backzone
U src/external/public-domain/tz/dist/iso3166.tab
U src/external/public-domain/tz/dist/leapseconds
U src/external/public-domain/tz/dist/zone1970.tab
U src/external/public-domain/tz/dist/zone.tab
U src/external/public-domain/tz/dist/leap-seconds.list
U src/external/public-domain/tz/dist/yearistype.sh
U src/external/public-domain/tz/dist/checklinks.awk
U src/external/public-domain/tz/dist/checktab.awk
U src/external/public-domain/tz/dist/leapseconds.awk
U src/external/public-domain/tz/dist/zoneinfo2tdf.pl

No conflicts created by this import



CVS import: src/external/public-domain/tz/dist

2016-08-06 Thread Robert Elz
Module Name:src
Committed By:   kre
Date:   Sun Aug  7 00:49:18 UTC 2016

Update of /cvsroot/src/external/public-domain/tz/dist
In directory ivanova.netbsd.org:/tmp/cvs-serv612

Log Message:
Import tzdata2016f from ftp://ftp.iana.org/tz/releases/tzdata2016f.tar.gz

Summary of changes in tzdata2016f (2016-07-05 16:26:51 +0200):
  * The Egyptian government changed its mind on short notice, and
Africa/Cairo will not introduce DST starting 2016-07-07 after all.
  * Asia/Novosibirsk switches from +06 to +07 on 2016-07-24 at 02:00.
  * Asia/Novokuznetsk and Asia/Novosibirsk now use numeric time zone
abbreviations instead of invented ones.
  * Europe/Minsk's 1992-03-29 spring-forward transition was at 02:00 not 00:00.

Summary of changes in tzdata2016e (2016-06-14 08:46:16 -0700):
  * Africa/Cairo observes DST in 2016 from July 7 to the end of October.
(change obsoleted by 2016f)
  * Locations while uninhabited now use '-00', not 'zzz', as a
placeholder time zone abbreviation.
  * Asia/Baku's 1992-09-27 transition from +04 (DST) to +04 (non-DST) was
at 03:00, not 23:00 the previous day.
  * zic now outputs a dummy transition at time 2**31 - 1 in zones
whose POSIX-style TZ strings contain a '<'.
  * Changes affecting documentation and commentary.

Status:

Vendor Tag: TZDATA
Release Tags:   TZDATA2016F

U src/external/public-domain/tz/dist/CONTRIBUTING
U src/external/public-domain/tz/dist/LICENSE
U src/external/public-domain/tz/dist/Makefile
U src/external/public-domain/tz/dist/NEWS
U src/external/public-domain/tz/dist/README
U src/external/public-domain/tz/dist/Theory
U src/external/public-domain/tz/dist/africa
U src/external/public-domain/tz/dist/antarctica
U src/external/public-domain/tz/dist/asia
U src/external/public-domain/tz/dist/australasia
U src/external/public-domain/tz/dist/europe
U src/external/public-domain/tz/dist/northamerica
U src/external/public-domain/tz/dist/southamerica
U src/external/public-domain/tz/dist/pacificnew
U src/external/public-domain/tz/dist/etcetera
U src/external/public-domain/tz/dist/backward
U src/external/public-domain/tz/dist/systemv
U src/external/public-domain/tz/dist/factory
U src/external/public-domain/tz/dist/backzone
U src/external/public-domain/tz/dist/iso3166.tab
U src/external/public-domain/tz/dist/leapseconds
U src/external/public-domain/tz/dist/zone1970.tab
U src/external/public-domain/tz/dist/zone.tab
U src/external/public-domain/tz/dist/leap-seconds.list
U src/external/public-domain/tz/dist/yearistype.sh
U src/external/public-domain/tz/dist/checklinks.awk
U src/external/public-domain/tz/dist/checktab.awk
U src/external/public-domain/tz/dist/leapseconds.awk
U src/external/public-domain/tz/dist/zoneinfo2tdf.pl

No conflicts created by this import



CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 00:25:22 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_balloc.c

Log Message:
use static properly


To generate a diff of this commit:
cvs rdiff -u -r1.88 -r1.89 src/sys/ufs/lfs/lfs_balloc.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/ufs/lfs/lfs_balloc.c
diff -u src/sys/ufs/lfs/lfs_balloc.c:1.88 src/sys/ufs/lfs/lfs_balloc.c:1.89
--- src/sys/ufs/lfs/lfs_balloc.c:1.88	Sat Oct 10 22:33:31 2015
+++ src/sys/ufs/lfs/lfs_balloc.c	Sun Aug  7 00:25:22 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: lfs_balloc.c,v 1.88 2015/10/10 22:33:31 dholland Exp $	*/
+/*	$NetBSD: lfs_balloc.c,v 1.89 2016/08/07 00:25:22 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@@ -60,7 +60,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: lfs_balloc.c,v 1.88 2015/10/10 22:33:31 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: lfs_balloc.c,v 1.89 2016/08/07 00:25:22 dholland Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_quota.h"
@@ -91,7 +91,8 @@ __KERNEL_RCSID(0, "$NetBSD: lfs_balloc.c
 
 #include 
 
-int lfs_fragextend(struct vnode *, int, int, daddr_t, struct buf **, kauth_cred_t);
+static int lfs_fragextend(struct vnode *, int, int, daddr_t, struct buf **,
+			  kauth_cred_t);
 
 u_int64_t locked_fakequeue_count;
 
@@ -365,9 +366,9 @@ lfs_balloc(struct vnode *vp, off_t start
 }
 
 /* VOP_BWRITE 1 time */
-int
-lfs_fragextend(struct vnode *vp, int osize, int nsize, daddr_t lbn, struct buf **bpp,
-kauth_cred_t cred)
+static int
+lfs_fragextend(struct vnode *vp, int osize, int nsize, daddr_t lbn,
+struct buf **bpp, kauth_cred_t cred)
 {
 	struct inode *ip;
 	struct lfs *fs;



CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 00:25:22 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_balloc.c

Log Message:
use static properly


To generate a diff of this commit:
cvs rdiff -u -r1.88 -r1.89 src/sys/ufs/lfs/lfs_balloc.c

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



CVS commit: src/sys/ufs/lfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sun Aug  7 00:12:48 UTC 2016

Modified Files:
src/sys/ufs/lfs: lfs_alloc.c

Log Message:
Comments


To generate a diff of this commit:
cvs rdiff -u -r1.131 -r1.132 src/sys/ufs/lfs/lfs_alloc.c

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



CVS commit: src

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 23:46:30 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi
src/sys/modules: Makefile
src/sys/net: if_pppoe.c
Added Files:
src/sys/modules/if_pppoe: Makefile pppoe.ioconf

Log Message:
Modularize the pppoe driver


To generate a diff of this commit:
cvs rdiff -u -r1.91 -r1.92 src/distrib/sets/lists/modules/mi
cvs rdiff -u -r1.173 -r1.174 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_pppoe/Makefile \
src/sys/modules/if_pppoe/pppoe.ioconf
cvs rdiff -u -r1.111 -r1.112 src/sys/net/if_pppoe.c

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



CVS commit: src

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 23:46:30 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi
src/sys/modules: Makefile
src/sys/net: if_pppoe.c
Added Files:
src/sys/modules/if_pppoe: Makefile pppoe.ioconf

Log Message:
Modularize the pppoe driver


To generate a diff of this commit:
cvs rdiff -u -r1.91 -r1.92 src/distrib/sets/lists/modules/mi
cvs rdiff -u -r1.173 -r1.174 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_pppoe/Makefile \
src/sys/modules/if_pppoe/pppoe.ioconf
cvs rdiff -u -r1.111 -r1.112 src/sys/net/if_pppoe.c

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/modules/mi
diff -u src/distrib/sets/lists/modules/mi:1.91 src/distrib/sets/lists/modules/mi:1.92
--- src/distrib/sets/lists/modules/mi:1.91	Sat Aug  6 22:03:45 2016
+++ src/distrib/sets/lists/modules/mi	Sat Aug  6 23:46:30 2016
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.91 2016/08/06 22:03:45 pgoyette Exp $
+# $NetBSD: mi,v 1.92 2016/08/06 23:46:30 pgoyette Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -128,6 +128,8 @@
 ./@MODULEDIR@/if_npflog/if_npflog.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/if_pppbase-kernel-modules	kmod
 ./@MODULEDIR@/if_ppp/if_ppp.kmod		base-kernel-modules	kmod
+./@MODULEDIR@/if_pppoebase-kernel-modules	kmod
+./@MODULEDIR@/if_pppoe/if_pppoe.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/if_slbase-kernel-modules	kmod
 ./@MODULEDIR@/if_sl/if_sl.kmod			base-kernel-modules	kmod
 ./@MODULEDIR@/if_smscbase-kernel-modules	kmod

Index: src/sys/modules/Makefile
diff -u src/sys/modules/Makefile:1.173 src/sys/modules/Makefile:1.174
--- src/sys/modules/Makefile:1.173	Sat Aug  6 22:03:45 2016
+++ src/sys/modules/Makefile	Sat Aug  6 23:46:30 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.173 2016/08/06 22:03:45 pgoyette Exp $
+#	$NetBSD: Makefile,v 1.174 2016/08/06 23:46:30 pgoyette Exp $
 
 .include 
 
@@ -49,6 +49,7 @@ SUBDIR+=	if_axe
 SUBDIR+=	if_axen
 SUBDIR+=	if_npflog
 SUBDIR+=	if_ppp
+SUBDIR+=	if_pppoe
 SUBDIR+=	if_sl
 SUBDIR+=	if_smsc
 SUBDIR+=	if_strip

Index: src/sys/net/if_pppoe.c
diff -u src/sys/net/if_pppoe.c:1.111 src/sys/net/if_pppoe.c:1.112
--- src/sys/net/if_pppoe.c:1.111	Thu Jul  7 06:55:43 2016
+++ src/sys/net/if_pppoe.c	Sat Aug  6 23:46:30 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: if_pppoe.c,v 1.111 2016/07/07 06:55:43 msaitoh Exp $ */
+/* $NetBSD: if_pppoe.c,v 1.112 2016/08/06 23:46:30 pgoyette Exp $ */
 
 /*-
  * Copyright (c) 2002, 2008 The NetBSD Foundation, Inc.
@@ -30,11 +30,10 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v 1.111 2016/07/07 06:55:43 msaitoh Exp $");
-
-#include "pppoe.h"
+__KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v 1.112 2016/08/06 23:46:30 pgoyette Exp $");
 
 #ifdef _KERNEL_OPT
+#include "pppoe.h"
 #include "opt_pppoe.h"
 #endif
 
@@ -50,6 +49,8 @@ __KERNEL_RCSID(0, "$NetBSD: if_pppoe.c,v
 #include 
 #include 
 #include 
+#include 
+#include 
 
 #include 
 #include 
@@ -210,6 +211,17 @@ static struct if_clone pppoe_cloner =
 void
 pppoeattach(int count)
 {
+
+	/*
+	 * Nothing to do here - all initialization happens as part
+	 * of module init.
+	 */
+}
+
+static void
+pppoeinit(void)
+{
+
 	LIST_INIT(_softc_list);
 	if_clone_attach(_cloner);
 
@@ -218,6 +230,16 @@ pppoeattach(int count)
 }
 
 static int
+pppoedetach(void)
+{
+
+	softint_disestablish(pppoe_softintr);
+	if_clone_detach(_cloner);
+
+	return 0;
+}
+
+static int
 pppoe_clone_create(struct if_clone *ifc, int unit)
 {
 	struct pppoe_softc *sc;
@@ -1622,3 +1644,61 @@ pppoedisc_input(struct ifnet *ifp, struc
 	pppoe_enqueue(, m);
 	return;
 }
+
+/*
+ * Module glue
+ */
+MODULE(MODULE_CLASS_DRIVER, if_pppoe, "sppp_subr");
+
+#ifdef _MODULE  
+CFDRIVER_DECL(pppoe, DV_IFNET, NULL);
+#endif
+ 
+static int
+if_pppoe_modcmd(modcmd_t cmd, void *arg)
+{
+	int error = 0;
+
+	switch (cmd) {
+	case MODULE_CMD_INIT:
+#ifdef _MODULE
+		error = config_cfdriver_attach(_cd);
+		if (error) {
+			aprint_error("%s: unable to register cfdriver for"
+			"%s, error %d\n", __func__, pppoe_cd.cd_name,
+			error);
+			break;
+		}
+#endif  
+		/* Init the cloner etc. */
+		pppoeinit();
+		break;
+
+case MODULE_CMD_FINI:
+		/*
+		 * Make sure it's ok to detach - no units left, and
+		 * line discipline is removed
+		 */
+		if (!LIST_EMPTY(_softc_list)) {
+			error = EBUSY;
+			break;
+		}
+		if ((error = pppoedetach()) != 0)
+			break;
+#ifdef _MODULE
+		/* Remove device from autoconf database */
+		if ((error = config_cfdriver_detach(_cd)) != 0) {
+			aprint_error("%s: failed to detach %s cfdriver, error "
+			"%d\n", __func__, pppoe_cd.cd_name, error);
+			break;
+		}
+#endif
+		break;
+	case MODULE_CMD_STAT:
+	case MODULE_CMD_AUTOUNLOAD:
+	default:
+		error = ENOTTY;
+	}
+	return error;
+}
+

Added files:

Index: src/sys/modules/if_pppoe/Makefile
diff -u /dev/null 

CVS commit: src/sys/net

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 22:54:34 UTC 2016

Modified Files:
src/sys/net: if_ppp.c

Log Message:
Destroy the mutex when detaching ppp.  Otherwise on a re-attach (ie,
module reload) we can end up with a panic "lock already initialized"


To generate a diff of this commit:
cvs rdiff -u -r1.155 -r1.156 src/sys/net/if_ppp.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/net/if_ppp.c
diff -u src/sys/net/if_ppp.c:1.155 src/sys/net/if_ppp.c:1.156
--- src/sys/net/if_ppp.c:1.155	Sat Aug  6 12:48:23 2016
+++ src/sys/net/if_ppp.c	Sat Aug  6 22:54:34 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_ppp.c,v 1.155 2016/08/06 12:48:23 christos Exp $	*/
+/*	$NetBSD: if_ppp.c,v 1.156 2016/08/06 22:54:34 pgoyette Exp $	*/
 /*	Id: if_ppp.c,v 1.6 1997/03/04 03:33:00 paulus Exp 	*/
 
 /*
@@ -102,7 +102,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_ppp.c,v 1.155 2016/08/06 12:48:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_ppp.c,v 1.156 2016/08/06 22:54:34 pgoyette Exp $");
 
 #ifdef _KERNEL_OPT
 #include "ppp.h"
@@ -263,6 +263,8 @@ pppdetach(void)
 	if (error == 0)
 		error = ttyldisc_detach(_disc);
 
+	mutex_destroy(_list_lock);
+
 	return error;
 }
 



CVS commit: src/sys/net

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 22:54:34 UTC 2016

Modified Files:
src/sys/net: if_ppp.c

Log Message:
Destroy the mutex when detaching ppp.  Otherwise on a re-attach (ie,
module reload) we can end up with a panic "lock already initialized"


To generate a diff of this commit:
cvs rdiff -u -r1.155 -r1.156 src/sys/net/if_ppp.c

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



CVS commit: src/sys/net

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 22:38:18 UTC 2016

Modified Files:
src/sys/net: bsd-comp.c ppp-deflate.c

Log Message:
Catch up with the renaming of module ppp --> if_ppp and avoid warning
messages at boot (or module load) time.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/net/bsd-comp.c
cvs rdiff -u -r1.22 -r1.23 src/sys/net/ppp-deflate.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/net/bsd-comp.c
diff -u src/sys/net/bsd-comp.c:1.21 src/sys/net/bsd-comp.c:1.22
--- src/sys/net/bsd-comp.c:1.21	Sat Aug  6 02:35:06 2016
+++ src/sys/net/bsd-comp.c	Sat Aug  6 22:38:18 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: bsd-comp.c,v 1.21 2016/08/06 02:35:06 pgoyette Exp $	*/
+/*	$NetBSD: bsd-comp.c,v 1.22 2016/08/06 22:38:18 pgoyette Exp $	*/
 /*	Id: bsd-comp.c,v 1.6 1996/08/28 06:31:58 paulus Exp 	*/
 
 /* Because this code is derived from the 4.3BSD compress source:
@@ -41,7 +41,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: bsd-comp.c,v 1.21 2016/08/06 02:35:06 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bsd-comp.c,v 1.22 2016/08/06 22:38:18 pgoyette Exp $");
 
 #include 
 #include 
@@ -1090,7 +1090,7 @@ bsd_decompress(void *state, struct mbuf 
 #endif /* DEBUG */
 }
 
-MODULE(MODULE_CLASS_MISC, ppp_bsdcomp, "ppp");
+MODULE(MODULE_CLASS_MISC, ppp_bsdcomp, "if_ppp");
 
 static int
 ppp_bsdcomp_modcmd(modcmd_t cmd, void *arg)

Index: src/sys/net/ppp-deflate.c
diff -u src/sys/net/ppp-deflate.c:1.22 src/sys/net/ppp-deflate.c:1.23
--- src/sys/net/ppp-deflate.c:1.22	Sat Aug  6 02:35:06 2016
+++ src/sys/net/ppp-deflate.c	Sat Aug  6 22:38:18 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ppp-deflate.c,v 1.22 2016/08/06 02:35:06 pgoyette Exp $	*/
+/*	$NetBSD: ppp-deflate.c,v 1.23 2016/08/06 22:38:18 pgoyette Exp $	*/
 /*	Id: ppp-deflate.c,v 1.5 1997/03/04 03:33:28 paulus Exp 	*/
 
 /*
@@ -39,7 +39,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ppp-deflate.c,v 1.22 2016/08/06 02:35:06 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ppp-deflate.c,v 1.23 2016/08/06 22:38:18 pgoyette Exp $");
 
 #include 
 #include 
@@ -664,7 +664,7 @@ z_incomp(void *arg, struct mbuf *mi)
 state->stats.unc_packets++;
 }
 
-MODULE(MODULE_CLASS_MISC, ppp_deflate, "zlib,ppp");
+MODULE(MODULE_CLASS_MISC, ppp_deflate, "zlib,if_ppp");
 
 static int
 ppp_deflate_modcmd(modcmd_t cmd, void *arg)



CVS commit: src/sys/net

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 22:38:18 UTC 2016

Modified Files:
src/sys/net: bsd-comp.c ppp-deflate.c

Log Message:
Catch up with the renaming of module ppp --> if_ppp and avoid warning
messages at boot (or module load) time.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/net/bsd-comp.c
cvs rdiff -u -r1.22 -r1.23 src/sys/net/ppp-deflate.c

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



CVS commit: src

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 22:03:45 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi
src/sys/modules: Makefile
src/sys/net: if_spppsubr.c
Added Files:
src/sys/modules/sppp_subr: Makefile

Log Message:
Modularize the sppp_subr stuff so it can be shared by pppoe and lmc
drivers as they get modularized.


To generate a diff of this commit:
cvs rdiff -u -r1.90 -r1.91 src/distrib/sets/lists/modules/mi
cvs rdiff -u -r1.172 -r1.173 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/sppp_subr/Makefile
cvs rdiff -u -r1.146 -r1.147 src/sys/net/if_spppsubr.c

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



CVS commit: src

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 22:03:45 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi
src/sys/modules: Makefile
src/sys/net: if_spppsubr.c
Added Files:
src/sys/modules/sppp_subr: Makefile

Log Message:
Modularize the sppp_subr stuff so it can be shared by pppoe and lmc
drivers as they get modularized.


To generate a diff of this commit:
cvs rdiff -u -r1.90 -r1.91 src/distrib/sets/lists/modules/mi
cvs rdiff -u -r1.172 -r1.173 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/sppp_subr/Makefile
cvs rdiff -u -r1.146 -r1.147 src/sys/net/if_spppsubr.c

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/modules/mi
diff -u src/distrib/sets/lists/modules/mi:1.90 src/distrib/sets/lists/modules/mi:1.91
--- src/distrib/sets/lists/modules/mi:1.90	Sat Aug  6 12:50:37 2016
+++ src/distrib/sets/lists/modules/mi	Sat Aug  6 22:03:45 2016
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.90 2016/08/06 12:50:37 christos Exp $
+# $NetBSD: mi,v 1.91 2016/08/06 22:03:45 pgoyette Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -244,6 +244,8 @@
 ./@MODULEDIR@/solaris/solaris.kmod		base-kernel-modules kmod,solaris
 ./@MODULEDIR@/spdmembase-kernel-modules	kmod
 ./@MODULEDIR@/spdmem/spdmem.kmod		base-kernel-modules	kmod
+./@MODULEDIR@/sppp_subrbase-kernel-modules	kmod
+./@MODULEDIR@/sppp_subr/sppp_subr.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/suserbase-kernel-modules	kmod
 ./@MODULEDIR@/suser/suser.kmod			base-kernel-modules	kmod
 ./@MODULEDIR@/swcryptobase-kernel-modules	kmod

Index: src/sys/modules/Makefile
diff -u src/sys/modules/Makefile:1.172 src/sys/modules/Makefile:1.173
--- src/sys/modules/Makefile:1.172	Sat Aug  6 12:44:03 2016
+++ src/sys/modules/Makefile	Sat Aug  6 22:03:45 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.172 2016/08/06 12:44:03 christos Exp $
+#	$NetBSD: Makefile,v 1.173 2016/08/06 22:03:45 pgoyette Exp $
 
 .include 
 
@@ -99,6 +99,7 @@ SUBDIR+=	skipjack
 SUBDIR+=	slcompress
 SUBDIR+=	smbfs
 SUBDIR+=	spdmem
+SUBDIR+=	sppp_subr
 SUBDIR+=	sysmon
 SUBDIR+=	sysmon_envsys
 SUBDIR+=	sysmon_power

Index: src/sys/net/if_spppsubr.c
diff -u src/sys/net/if_spppsubr.c:1.146 src/sys/net/if_spppsubr.c:1.147
--- src/sys/net/if_spppsubr.c:1.146	Thu Jul  7 09:32:02 2016
+++ src/sys/net/if_spppsubr.c	Sat Aug  6 22:03:45 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_spppsubr.c,v 1.146 2016/07/07 09:32:02 ozaki-r Exp $	 */
+/*	$NetBSD: if_spppsubr.c,v 1.147 2016/08/06 22:03:45 pgoyette Exp $	 */
 
 /*
  * Synchronous PPP/Cisco link level subroutines.
@@ -41,7 +41,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_spppsubr.c,v 1.146 2016/07/07 09:32:02 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_spppsubr.c,v 1.147 2016/08/06 22:03:45 pgoyette Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_inet.h"
@@ -64,6 +64,7 @@ __KERNEL_RCSID(0, "$NetBSD: if_spppsubr.
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -5592,3 +5593,23 @@ sppp_null(struct sppp *unused)
  * hilit-auto-highlight-maxout: 12
  * End:
  */
+
+/*
+ * Module glue
+ */
+MODULE(MODULE_CLASS_MISC, sppp_subr, NULL);
+ 
+static int
+sppp_subr_modcmd(modcmd_t cmd, void *arg)
+{
+switch (cmd) {
+case MODULE_CMD_INIT:
+case MODULE_CMD_FINI:
+return 0;
+case MODULE_CMD_STAT:
+case MODULE_CMD_AUTOUNLOAD:
+default:
+return ENOTTY;
+}
+}
+

Added files:

Index: src/sys/modules/sppp_subr/Makefile
diff -u /dev/null src/sys/modules/sppp_subr/Makefile:1.1
--- /dev/null	Sat Aug  6 22:03:45 2016
+++ src/sys/modules/sppp_subr/Makefile	Sat Aug  6 22:03:45 2016
@@ -0,0 +1,14 @@
+# $NetBSD: Makefile,v 1.1 2016/08/06 22:03:45 pgoyette Exp $
+
+.include "../Makefile.inc"
+
+.PATH:  ${S}/net
+
+KMOD=		sppp_subr
+SRCS=		if_spppsubr.c
+
+CPPFLAGS+=	-DINET
+CPPFLAGS+=	-DINET6
+#CPPFLAGS+=	-DIPV6CP_MYIFID_DYN	# Will not build if this is enabled!
+
+.include 



CVS commit: src/sys/arch/x86/pci

2016-08-06 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Sat Aug  6 21:57:04 UTC 2016

Modified Files:
src/sys/arch/x86/pci: ichlpcib.c

Log Message:
Disable gpio(4) attachment to ichlpcib(4) by default.

The GPIO lines on an ICH are usually connected to opaque platform-
defined functionality, and may be manipulated by the ACPI DSDT or other
mechanisms behind our backs.  In one instance, it was found this
in combiation with gpio_resume() sabotaged repeated suspend/resume cycles.

GPIO functionality can be enabled by setting ichlpcib_gpio_disable to 0,
for instance with `gdb -write`.


To generate a diff of this commit:
cvs rdiff -u -r1.50 -r1.51 src/sys/arch/x86/pci/ichlpcib.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/x86/pci/ichlpcib.c
diff -u src/sys/arch/x86/pci/ichlpcib.c:1.50 src/sys/arch/x86/pci/ichlpcib.c:1.51
--- src/sys/arch/x86/pci/ichlpcib.c:1.50	Sun May 17 04:59:43 2015
+++ src/sys/arch/x86/pci/ichlpcib.c	Sat Aug  6 21:57:04 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ichlpcib.c,v 1.50 2015/05/17 04:59:43 msaitoh Exp $	*/
+/*	$NetBSD: ichlpcib.c,v 1.51 2016/08/06 21:57:04 jakllsch Exp $	*/
 
 /*-
  * Copyright (c) 2004 The NetBSD Foundation, Inc.
@@ -40,7 +40,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ichlpcib.c,v 1.50 2015/05/17 04:59:43 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ichlpcib.c,v 1.51 2016/08/06 21:57:04 jakllsch Exp $");
 
 #include 
 #include 
@@ -277,6 +277,14 @@ static struct lpcib_device {
 };
 
 /*
+ * Allow user to enable GPIO functionality if they really need it.  The
+ * vast majority of systems with an ICH should not expose GPIO to the
+ * kernel or user.  In at least one instance the gpio_resume() handler
+ * on ICH GPIO was found to sabotage S3 suspend/resume.
+ */
+int	ichlpcib_gpio_disable = 1;
+
+/*
  * Autoconf callbacks.
  */
 static int
@@ -888,6 +896,9 @@ lpcib_gpio_configure(device_t self)
 	int pin, shift, base_reg, cntl_reg, reg;
 	int rv;
 
+	if (ichlpcib_gpio_disable != 0)
+		return;
+
 	/* this implies ICH >= 6, and thus different mapreg */
 	if (sc->sc_has_rcba) {
 		base_reg = LPCIB_PCI_GPIO_BASE_ICH6;



CVS commit: src/sys/arch/x86/pci

2016-08-06 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Sat Aug  6 21:57:04 UTC 2016

Modified Files:
src/sys/arch/x86/pci: ichlpcib.c

Log Message:
Disable gpio(4) attachment to ichlpcib(4) by default.

The GPIO lines on an ICH are usually connected to opaque platform-
defined functionality, and may be manipulated by the ACPI DSDT or other
mechanisms behind our backs.  In one instance, it was found this
in combiation with gpio_resume() sabotaged repeated suspend/resume cycles.

GPIO functionality can be enabled by setting ichlpcib_gpio_disable to 0,
for instance with `gdb -write`.


To generate a diff of this commit:
cvs rdiff -u -r1.50 -r1.51 src/sys/arch/x86/pci/ichlpcib.c

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



CVS commit: src/sys/ufs/ext2fs

2016-08-06 Thread Jaromir Dolecek
Module Name:src
Committed By:   jdolecek
Date:   Sat Aug  6 21:39:48 UTC 2016

Modified Files:
src/sys/ufs/ext2fs: ext2fs_dir.h ext2fs_lookup.c ext2fs_rename.c

Log Message:
actually pass the d_type from the on-disk directory entry to the lookup results


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/ufs/ext2fs/ext2fs_dir.h
cvs rdiff -u -r1.80 -r1.81 src/sys/ufs/ext2fs/ext2fs_lookup.c
cvs rdiff -u -r1.8 -r1.9 src/sys/ufs/ext2fs/ext2fs_rename.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/ufs/ext2fs/ext2fs_dir.h
diff -u src/sys/ufs/ext2fs/ext2fs_dir.h:1.20 src/sys/ufs/ext2fs/ext2fs_dir.h:1.21
--- src/sys/ufs/ext2fs/ext2fs_dir.h:1.20	Fri Jun 24 17:21:30 2016
+++ src/sys/ufs/ext2fs/ext2fs_dir.h	Sat Aug  6 21:39:48 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ext2fs_dir.h,v 1.20 2016/06/24 17:21:30 christos Exp $	*/
+/*	$NetBSD: ext2fs_dir.h,v 1.21 2016/08/06 21:39:48 jdolecek Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1989, 1993
@@ -167,6 +167,30 @@ inot2ext2dt(uint16_t type)
 	}
 }
 
+static __inline uint8_t ext2dt2dt(uint8_t) __unused;
+static __inline uint8_t
+ext2dt2dt(uint8_t type)
+{
+	switch (type) {
+	case EXT2_FT_REG_FILE:
+		return DT_FIFO;
+	case EXT2_FT_DIR:
+		return DT_DIR;
+	case EXT2_FT_CHRDEV:
+		return DT_CHR;
+	case EXT2_FT_BLKDEV:
+		return DT_BLK;
+	case EXT2_FT_FIFO:
+		return DT_FIFO;
+	case EXT2_FT_SOCK:
+		return DT_SOCK;
+	case EXT2_FT_SYMLINK:
+		return DT_LNK;
+	default:
+		return DT_UNKNOWN;
+	}
+}
+
 /*
  * The EXT2FS_DIRSIZ macro gives the minimum record length which will hold
  * the directory entryfor a name len "len" (without the terminating null byte).

Index: src/sys/ufs/ext2fs/ext2fs_lookup.c
diff -u src/sys/ufs/ext2fs/ext2fs_lookup.c:1.80 src/sys/ufs/ext2fs/ext2fs_lookup.c:1.81
--- src/sys/ufs/ext2fs/ext2fs_lookup.c:1.80	Fri Jun 24 17:21:30 2016
+++ src/sys/ufs/ext2fs/ext2fs_lookup.c	Sat Aug  6 21:39:48 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ext2fs_lookup.c,v 1.80 2016/06/24 17:21:30 christos Exp $	*/
+/*	$NetBSD: ext2fs_lookup.c,v 1.81 2016/08/06 21:39:48 jdolecek Exp $	*/
 
 /*
  * Modified for NetBSD 1.2E
@@ -48,7 +48,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ext2fs_lookup.c,v 1.80 2016/06/24 17:21:30 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ext2fs_lookup.c,v 1.81 2016/08/06 21:39:48 jdolecek Exp $");
 
 #include 
 #include 
@@ -99,7 +99,8 @@ ext2fs_dirconv2ffs(struct ext2fs_direct 
 	ffsdir->d_fileno = fs2h32(e2dir->e2d_ino);
 	ffsdir->d_namlen = e2dir->e2d_namlen;
 
-	ffsdir->d_type = DT_UNKNOWN;		/* don't know more here */
+	ffsdir->d_type = ext2dt2dt(e2dir->e2d_type);
+
 #ifdef DIAGNOSTIC
 #if MAXNAMLEN < E2FS_MAXNAMLEN
 	/*

Index: src/sys/ufs/ext2fs/ext2fs_rename.c
diff -u src/sys/ufs/ext2fs/ext2fs_rename.c:1.8 src/sys/ufs/ext2fs/ext2fs_rename.c:1.9
--- src/sys/ufs/ext2fs/ext2fs_rename.c:1.8	Fri Mar 27 17:27:56 2015
+++ src/sys/ufs/ext2fs/ext2fs_rename.c	Sat Aug  6 21:39:48 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ext2fs_rename.c,v 1.8 2015/03/27 17:27:56 riastradh Exp $	*/
+/*	$NetBSD: ext2fs_rename.c,v 1.9 2016/08/06 21:39:48 jdolecek Exp $	*/
 
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ext2fs_rename.c,v 1.8 2015/03/27 17:27:56 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ext2fs_rename.c,v 1.9 2016/08/06 21:39:48 jdolecek Exp $");
 
 #include 
 #include 
@@ -44,6 +44,7 @@ __KERNEL_RCSID(0, "$NetBSD: ext2fs_renam
 #include 
 #include 
 #include 
+#include 
 
 #include 
 



CVS commit: src/sys/ufs/ext2fs

2016-08-06 Thread Jaromir Dolecek
Module Name:src
Committed By:   jdolecek
Date:   Sat Aug  6 21:39:48 UTC 2016

Modified Files:
src/sys/ufs/ext2fs: ext2fs_dir.h ext2fs_lookup.c ext2fs_rename.c

Log Message:
actually pass the d_type from the on-disk directory entry to the lookup results


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/ufs/ext2fs/ext2fs_dir.h
cvs rdiff -u -r1.80 -r1.81 src/sys/ufs/ext2fs/ext2fs_lookup.c
cvs rdiff -u -r1.8 -r1.9 src/sys/ufs/ext2fs/ext2fs_rename.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/ia64/include

2016-08-06 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Sat Aug  6 21:13:30 UTC 2016

Modified Files:
src/sys/arch/ia64/include: vmparam.h

Log Message:
Remove unused include of sys/tree.h


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/ia64/include/vmparam.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/ia64/include/vmparam.h
diff -u src/sys/arch/ia64/include/vmparam.h:1.8 src/sys/arch/ia64/include/vmparam.h:1.9
--- src/sys/arch/ia64/include/vmparam.h:1.8	Fri Aug  5 17:04:16 2016
+++ src/sys/arch/ia64/include/vmparam.h	Sat Aug  6 21:13:30 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmparam.h,v 1.8 2016/08/05 17:04:16 scole Exp $	*/
+/*	$NetBSD: vmparam.h,v 1.9 2016/08/06 21:13:30 martin Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -37,8 +37,6 @@
 #ifndef _VMPARAM_H_
 #define _VMPARAM_H_
 
-#include 
-
 #define	USRSTACK	VM_MAX_ADDRESS /* XXX: Revisit vm address space. */
 
 /*



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

2016-08-06 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Sat Aug  6 21:13:30 UTC 2016

Modified Files:
src/sys/arch/ia64/include: vmparam.h

Log Message:
Remove unused include of sys/tree.h


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/ia64/include/vmparam.h

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



CVS commit: src/sys/ufs/chfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sat Aug  6 20:42:29 UTC 2016

Modified Files:
src/sys/ufs/chfs: ebh.h

Log Message:
typo in comment


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/ufs/chfs/ebh.h

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



CVS commit: src/sys/ufs/chfs

2016-08-06 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Sat Aug  6 20:42:29 UTC 2016

Modified Files:
src/sys/ufs/chfs: ebh.h

Log Message:
typo in comment


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/ufs/chfs/ebh.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/ufs/chfs/ebh.h
diff -u src/sys/ufs/chfs/ebh.h:1.3 src/sys/ufs/chfs/ebh.h:1.4
--- src/sys/ufs/chfs/ebh.h:1.3	Fri Oct 19 12:44:39 2012
+++ src/sys/ufs/chfs/ebh.h	Sat Aug  6 20:42:29 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ebh.h,v 1.3 2012/10/19 12:44:39 ttoth Exp $	*/
+/*	$NetBSD: ebh.h,v 1.4 2016/08/06 20:42:29 dholland Exp $	*/
 
 /*-
  * Copyright (c) 2010 Department of Software Engineering,
@@ -105,7 +105,7 @@ enum {
 struct chfs_ebh;
 
 /**
- * struct chfs_ltree_entry - an netry in the lock tree
+ * struct chfs_ltree_entry - an entry in the lock tree
  * @rb: RB-node of the tree
  * @lnr: logical eraseblock number
  * @users: counts the tasks that are using or want to use the eraseblock



CVS commit: src/distrib/sets/lists/debug

2016-08-06 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Sat Aug  6 20:08:00 UTC 2016

Modified Files:
src/distrib/sets/lists/debug: shl.mi
Added Files:
src/distrib/sets/lists/debug: md.ia64

Log Message:
Fix debug sets for ia64


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/distrib/sets/lists/debug/md.ia64
cvs rdiff -u -r1.139 -r1.140 src/distrib/sets/lists/debug/shl.mi

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



CVS commit: src/distrib/sets/lists/debug

2016-08-06 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Sat Aug  6 20:08:00 UTC 2016

Modified Files:
src/distrib/sets/lists/debug: shl.mi
Added Files:
src/distrib/sets/lists/debug: md.ia64

Log Message:
Fix debug sets for ia64


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/distrib/sets/lists/debug/md.ia64
cvs rdiff -u -r1.139 -r1.140 src/distrib/sets/lists/debug/shl.mi

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/debug/shl.mi
diff -u src/distrib/sets/lists/debug/shl.mi:1.139 src/distrib/sets/lists/debug/shl.mi:1.140
--- src/distrib/sets/lists/debug/shl.mi:1.139	Tue Aug  2 14:54:03 2016
+++ src/distrib/sets/lists/debug/shl.mi	Sat Aug  6 20:08:00 2016
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.139 2016/08/02 14:54:03 jakllsch Exp $
+# $NetBSD: shl.mi,v 1.140 2016/08/06 20:08:00 martin Exp $
 ./usr/libdata/debug/lib		base-sys-usr	debug,dynamicroot,compatdir
 ./usr/libdata/debug/lib/libblacklist.so.0.0.debug		comp-sys-debug	debug,dynamicroot
 ./usr/libdata/debug/lib/libc.so.12.203.debug			comp-sys-debug	debug,dynamicroot
@@ -286,7 +286,7 @@
 ./usr/libdata/debug/usr/lib/npf/libext_log.so.0.0.debug		comp-obsolete	debug,compatfile,npf,obsolete
 ./usr/libdata/debug/usr/lib/npf/libext_normalise.so.0.0.debug	comp-obsolete	debug,compatfile,npf,obsolete
 ./usr/libdata/debug/usr/lib/npf/libext_rndblock.so.0.0.debug	comp-obsolete	debug,compatfile,npf,obsolete
-./usr/libdata/debug/usr/libexec/ld.elf_so.debug			comp-sys-debug	debug
+./usr/libdata/debug/usr/libexec/ld.elf_so.debug			comp-sys-debug	debug,dynamicroot
 ./usr/libdata/debug/usr/libexec/liblto_plugin.so.0.0.debug	comp-sys-debug	debug,gcc
 ./usr/libdata/debug/usr/tests/lib/csu/h_initfini3_dso.so.1.debug	tests-lib-debug		debug,compattestfile,atf
 ./usr/libdata/debug/usr/tests/lib/csu/libh_initfini3_dso.so.1.debug	tests-obsolete		debug,compattestfile,atf,obsolete

Added files:

Index: src/distrib/sets/lists/debug/md.ia64
diff -u /dev/null src/distrib/sets/lists/debug/md.ia64:1.1
--- /dev/null	Sat Aug  6 20:08:00 2016
+++ src/distrib/sets/lists/debug/md.ia64	Sat Aug  6 20:08:00 2016
@@ -0,0 +1,8 @@
+# $NetBSD: md.ia64,v 1.1 2016/08/06 20:08:00 martin Exp $
+#
+# XXX add skiload for now
+#
+# XXX loader.sym probaby not necessary
+#
+./usr/libdata/debug/usr/mdec/loader.sym.debug	comp-sys-debug		debug
+./usr/libdata/debug/usr/mdec/skiload.debug	comp-sys-debug		debug



CVS commit: src/sys/netinet6

2016-08-06 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Sat Aug  6 20:00:14 UTC 2016

Modified Files:
src/sys/netinet6: nd6.c

Log Message:
Set RTF_CONNECTED instead of setting only RTF_CONNECTED.


To generate a diff of this commit:
cvs rdiff -u -r1.205 -r1.206 src/sys/netinet6/nd6.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/netinet6/nd6.c
diff -u src/sys/netinet6/nd6.c:1.205 src/sys/netinet6/nd6.c:1.206
--- src/sys/netinet6/nd6.c:1.205	Mon Aug  1 03:15:31 2016
+++ src/sys/netinet6/nd6.c	Sat Aug  6 20:00:14 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: nd6.c,v 1.205 2016/08/01 03:15:31 ozaki-r Exp $	*/
+/*	$NetBSD: nd6.c,v 1.206 2016/08/06 20:00:14 roy Exp $	*/
 /*	$KAME: nd6.c,v 1.279 2002/06/08 11:16:51 itojun Exp $	*/
 
 /*
@@ -31,7 +31,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: nd6.c,v 1.205 2016/08/01 03:15:31 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: nd6.c,v 1.206 2016/08/06 20:00:14 roy Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_net_mpsafe.h"
@@ -2433,7 +2433,7 @@ nd6_add_ifa_lle(struct in6_ifaddr *ia)
 	if (nd6_need_cache(ifp) == 0)
 		return 0;
 	ia->ia_ifa.ifa_rtrequest = nd6_rtrequest;
-	ia->ia_ifa.ifa_flags = RTF_CONNECTED;
+	ia->ia_ifa.ifa_flags |= RTF_CONNECTED;
 
 	IF_AFDATA_WLOCK(ifp);
 	ln = lla_create(LLTABLE6(ifp), LLE_IFADDR | LLE_EXCLUSIVE,



CVS commit: src/sys/netinet6

2016-08-06 Thread Roy Marples
Module Name:src
Committed By:   roy
Date:   Sat Aug  6 20:00:14 UTC 2016

Modified Files:
src/sys/netinet6: nd6.c

Log Message:
Set RTF_CONNECTED instead of setting only RTF_CONNECTED.


To generate a diff of this commit:
cvs rdiff -u -r1.205 -r1.206 src/sys/netinet6/nd6.c

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



CVS commit: src/sys

2016-08-06 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Sat Aug  6 15:13:14 UTC 2016

Modified Files:
src/sys/compat/linux32/common: linux32_exec_elf32.c
src/sys/compat/netbsd32: netbsd32_exec_aout.c netbsd32_exec_elf32.c
src/sys/kern: kern_exec.c
src/sys/sys: exec.h
src/sys/uvm: uvm_map.c

Log Message:
The way the kernel tries to prevent a userland process from allocating page
zero is hugely flawed. It is easy to demonstrate that one can trick UVM
into chosing a NULL hint after the user_va0_disable check from uvm_map.
Such a bypass allows kernel NULL pointer dereferences to be exploitable on
architectures with a shared userland<->kernel VA, like amd64.

Fix this by increasing the limit of the vm space made available for
userland processes. This way, UVM will never chose a NULL hint, since it
would be outside of the vm space.

The user_va0_disable sysctl still controls this feature.


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/compat/linux32/common/linux32_exec_elf32.c
cvs rdiff -u -r1.29 -r1.30 src/sys/compat/netbsd32/netbsd32_exec_aout.c
cvs rdiff -u -r1.39 -r1.40 src/sys/compat/netbsd32/netbsd32_exec_elf32.c
cvs rdiff -u -r1.435 -r1.436 src/sys/kern/kern_exec.c
cvs rdiff -u -r1.150 -r1.151 src/sys/sys/exec.h
cvs rdiff -u -r1.340 -r1.341 src/sys/uvm/uvm_map.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/compat/linux32/common/linux32_exec_elf32.c
diff -u src/sys/compat/linux32/common/linux32_exec_elf32.c:1.18 src/sys/compat/linux32/common/linux32_exec_elf32.c:1.19
--- src/sys/compat/linux32/common/linux32_exec_elf32.c:1.18	Fri Mar 20 20:36:27 2015
+++ src/sys/compat/linux32/common/linux32_exec_elf32.c	Sat Aug  6 15:13:13 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux32_exec_elf32.c,v 1.18 2015/03/20 20:36:27 maxv Exp $ */
+/*	$NetBSD: linux32_exec_elf32.c,v 1.19 2016/08/06 15:13:13 maxv Exp $ */
 
 /*- 
  * Copyright (c) 1995, 1998, 2000, 2001,2006 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: linux32_exec_elf32.c,v 1.18 2015/03/20 20:36:27 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux32_exec_elf32.c,v 1.19 2016/08/06 15:13:13 maxv Exp $");
 
 #define	ELFSIZE		32
 
@@ -93,7 +93,7 @@ ELFNAME2(linux32,probe)(struct lwp *l, s
 #endif
 
 	epp->ep_flags |= EXEC_32 | EXEC_FORCEAUX;
-	epp->ep_vm_minaddr = VM_MIN_ADDRESS;
+	epp->ep_vm_minaddr = exec_vm_minaddr(VM_MIN_ADDRESS);
 	epp->ep_vm_maxaddr = USRSTACK32;
 
 	return 0;

Index: src/sys/compat/netbsd32/netbsd32_exec_aout.c
diff -u src/sys/compat/netbsd32/netbsd32_exec_aout.c:1.29 src/sys/compat/netbsd32/netbsd32_exec_aout.c:1.30
--- src/sys/compat/netbsd32/netbsd32_exec_aout.c:1.29	Fri Dec  5 22:21:47 2014
+++ src/sys/compat/netbsd32/netbsd32_exec_aout.c	Sat Aug  6 15:13:13 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: netbsd32_exec_aout.c,v 1.29 2014/12/05 22:21:47 christos Exp $	*/
+/*	$NetBSD: netbsd32_exec_aout.c,v 1.30 2016/08/06 15:13:13 maxv Exp $	*/
 /*	from: NetBSD: exec_aout.c,v 1.15 1996/09/26 23:34:46 cgd Exp */
 
 /*
@@ -57,7 +57,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_exec_aout.c,v 1.29 2014/12/05 22:21:47 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_exec_aout.c,v 1.30 2016/08/06 15:13:13 maxv Exp $");
 
 #include 
 #include 
@@ -164,7 +164,7 @@ netbsd32_exec_aout_prep_zmagic(struct lw
 	epp->ep_daddr = epp->ep_taddr + execp->a_text;
 	epp->ep_dsize = execp->a_data + execp->a_bss;
 	epp->ep_entry = execp->a_entry;
-	epp->ep_vm_minaddr = VM_MIN_ADDRESS;
+	epp->ep_vm_minaddr = exec_vm_minaddr(VM_MIN_ADDRESS);
 	epp->ep_vm_maxaddr = VM_MAXUSER_ADDRESS32;
 
 	error = vn_marktext(epp->ep_vp);
@@ -205,7 +205,7 @@ netbsd32_exec_aout_prep_nmagic(struct lw
 	epp->ep_daddr = roundup(epp->ep_taddr + execp->a_text, AOUT_LDPGSZ);
 	epp->ep_dsize = execp->a_data + execp->a_bss;
 	epp->ep_entry = execp->a_entry;
-	epp->ep_vm_minaddr = VM_MIN_ADDRESS;
+	epp->ep_vm_minaddr = exec_vm_minaddr(VM_MIN_ADDRESS);
 	epp->ep_vm_maxaddr = VM_MAXUSER_ADDRESS32;
 
 	/* set up command for text segment */
@@ -244,7 +244,7 @@ netbsd32_exec_aout_prep_omagic(struct lw
 	epp->ep_daddr = epp->ep_taddr + execp->a_text;
 	epp->ep_dsize = execp->a_data + execp->a_bss;
 	epp->ep_entry = execp->a_entry;
-	epp->ep_vm_minaddr = VM_MIN_ADDRESS;
+	epp->ep_vm_minaddr = exec_vm_minaddr(VM_MIN_ADDRESS);
 	epp->ep_vm_maxaddr = VM_MAXUSER_ADDRESS32;
 
 	/* set up command for text and data segments */
@@ -294,7 +294,7 @@ netbsd32_exec_aout_prep_oldzmagic(struct
 	epp->ep_daddr = epp->ep_taddr + execp->a_text;
 	epp->ep_dsize = execp->a_data + execp->a_bss;
 	epp->ep_entry = execp->a_entry;
-	epp->ep_vm_minaddr = VM_MIN_ADDRESS;
+	epp->ep_vm_minaddr = exec_vm_minaddr(VM_MIN_ADDRESS);
 	epp->ep_vm_maxaddr = VM_MAXUSER_ADDRESS32;
 
 	error = vn_marktext(epp->ep_vp);
@@ -342,7 +342,7 @@ netbsd32_exec_aout_prep_oldnmagic(struct
 	epp->ep_daddr = 

CVS commit: src/sys

2016-08-06 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Sat Aug  6 15:13:14 UTC 2016

Modified Files:
src/sys/compat/linux32/common: linux32_exec_elf32.c
src/sys/compat/netbsd32: netbsd32_exec_aout.c netbsd32_exec_elf32.c
src/sys/kern: kern_exec.c
src/sys/sys: exec.h
src/sys/uvm: uvm_map.c

Log Message:
The way the kernel tries to prevent a userland process from allocating page
zero is hugely flawed. It is easy to demonstrate that one can trick UVM
into chosing a NULL hint after the user_va0_disable check from uvm_map.
Such a bypass allows kernel NULL pointer dereferences to be exploitable on
architectures with a shared userland<->kernel VA, like amd64.

Fix this by increasing the limit of the vm space made available for
userland processes. This way, UVM will never chose a NULL hint, since it
would be outside of the vm space.

The user_va0_disable sysctl still controls this feature.


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/compat/linux32/common/linux32_exec_elf32.c
cvs rdiff -u -r1.29 -r1.30 src/sys/compat/netbsd32/netbsd32_exec_aout.c
cvs rdiff -u -r1.39 -r1.40 src/sys/compat/netbsd32/netbsd32_exec_elf32.c
cvs rdiff -u -r1.435 -r1.436 src/sys/kern/kern_exec.c
cvs rdiff -u -r1.150 -r1.151 src/sys/sys/exec.h
cvs rdiff -u -r1.340 -r1.341 src/sys/uvm/uvm_map.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/i386/acpi

2016-08-06 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Sat Aug  6 14:54:25 UTC 2016

Modified Files:
src/sys/arch/i386/acpi: acpi_wakeup_low.S

Log Message:
Use the stack to save %edx.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/i386/acpi/acpi_wakeup_low.S

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



CVS commit: src/sys/arch/i386/acpi

2016-08-06 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Sat Aug  6 14:54:25 UTC 2016

Modified Files:
src/sys/arch/i386/acpi: acpi_wakeup_low.S

Log Message:
Use the stack to save %edx.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/i386/acpi/acpi_wakeup_low.S

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/i386/acpi/acpi_wakeup_low.S
diff -u src/sys/arch/i386/acpi/acpi_wakeup_low.S:1.7 src/sys/arch/i386/acpi/acpi_wakeup_low.S:1.8
--- src/sys/arch/i386/acpi/acpi_wakeup_low.S:1.7	Sun Jul 24 14:09:22 2016
+++ src/sys/arch/i386/acpi/acpi_wakeup_low.S	Sat Aug  6 14:54:25 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_wakeup_low.S,v 1.7 2016/07/24 14:09:22 maxv Exp $	*/
+/*	$NetBSD: acpi_wakeup_low.S,v 1.8 2016/08/06 14:54:25 maxv Exp $	*/
 
 /*-
  * Copyright (c) 2007 Joerg Sonnenberger 
@@ -29,7 +29,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: acpi_wakeup_low.S,v 1.7 2016/07/24 14:09:22 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: acpi_wakeup_low.S,v 1.8 2016/08/06 14:54:25 maxv Exp $");
 
 #include "assym.h"
 #include 
@@ -105,8 +105,9 @@ acpi_md_sleep_prepare:
 	movl	%esp,ACPI_SUSPEND_REG+(4*4)(%edx)
 
 	movl	$MSR_EFER,%ecx
-	rdmsr
-	movl	CPUVAR(SELF),%edx
+	pushl	%edx
+	rdmsr	/* overwrites %edx */
+	popl	%edx
 	movl	%eax,ACPI_SUSPEND_EFER(%edx)
 
 	movl	%cr0,%eax



CVS commit: src/distrib/atari/floppies/install

2016-08-06 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sat Aug  6 14:51:01 UTC 2016

Modified Files:
src/distrib/atari/floppies/install: Makefile

Log Message:
Workaround unexpected/undocumented behaviors of makefs(8).


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/distrib/atari/floppies/install/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/atari/floppies/install/Makefile
diff -u src/distrib/atari/floppies/install/Makefile:1.5 src/distrib/atari/floppies/install/Makefile:1.6
--- src/distrib/atari/floppies/install/Makefile:1.5	Tue Apr 28 15:13:45 2015
+++ src/distrib/atari/floppies/install/Makefile	Sat Aug  6 14:51:01 2016
@@ -1,8 +1,9 @@
-#	$NetBSD: Makefile,v 1.5 2015/04/28 15:13:45 christos Exp $
+#	$NetBSD: Makefile,v 1.6 2016/08/06 14:51:01 tsutsui Exp $
 
 IMAGE=		sysinst.fs
 IMAGESIZE?=	1440k
 MAKEDEVTARGETS=	floppy
 USE_SYSINST=	yes
+IMGMAKEFSOPTIONS= -o bsize=4096,fsize=512,density=4096
 
 .include "../common/Makefile.images"



CVS commit: src/distrib/atari/floppies/install

2016-08-06 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sat Aug  6 14:51:01 UTC 2016

Modified Files:
src/distrib/atari/floppies/install: Makefile

Log Message:
Workaround unexpected/undocumented behaviors of makefs(8).


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/distrib/atari/floppies/install/Makefile

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



CVS commit: src/distrib/sets/lists/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 12:50:38 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi

Log Message:
sets for slip and strip


To generate a diff of this commit:
cvs rdiff -u -r1.89 -r1.90 src/distrib/sets/lists/modules/mi

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



CVS commit: src/distrib/sets/lists/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 12:50:38 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi

Log Message:
sets for slip and strip


To generate a diff of this commit:
cvs rdiff -u -r1.89 -r1.90 src/distrib/sets/lists/modules/mi

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/modules/mi
diff -u src/distrib/sets/lists/modules/mi:1.89 src/distrib/sets/lists/modules/mi:1.90
--- src/distrib/sets/lists/modules/mi:1.89	Sat Aug  6 02:04:48 2016
+++ src/distrib/sets/lists/modules/mi	Sat Aug  6 08:50:37 2016
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.89 2016/08/06 06:04:48 christos Exp $
+# $NetBSD: mi,v 1.90 2016/08/06 12:50:37 christos Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -128,8 +128,12 @@
 ./@MODULEDIR@/if_npflog/if_npflog.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/if_pppbase-kernel-modules	kmod
 ./@MODULEDIR@/if_ppp/if_ppp.kmod		base-kernel-modules	kmod
+./@MODULEDIR@/if_slbase-kernel-modules	kmod
+./@MODULEDIR@/if_sl/if_sl.kmod			base-kernel-modules	kmod
 ./@MODULEDIR@/if_smscbase-kernel-modules	kmod
 ./@MODULEDIR@/if_smsc/if_smsc.kmod		base-kernel-modules	kmod
+./@MODULEDIR@/if_stripbase-kernel-modules	kmod
+./@MODULEDIR@/if_strip/if_strip.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/iicbase-kernel-modules	kmod
 ./@MODULEDIR@/iic/iic.kmod			base-kernel-modules	kmod
 ./@MODULEDIR@/iplbase-kernel-modules	kmod



CVS commit: src/sys/net

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 12:48:23 UTC 2016

Modified Files:
src/sys/net: if_ppp.c if_sl.c if_strip.c

Log Message:
make strip and slip modular, and cosmetic for ppp.


To generate a diff of this commit:
cvs rdiff -u -r1.154 -r1.155 src/sys/net/if_ppp.c
cvs rdiff -u -r1.124 -r1.125 src/sys/net/if_sl.c
cvs rdiff -u -r1.104 -r1.105 src/sys/net/if_strip.c

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



CVS commit: src/sys/net

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 12:48:23 UTC 2016

Modified Files:
src/sys/net: if_ppp.c if_sl.c if_strip.c

Log Message:
make strip and slip modular, and cosmetic for ppp.


To generate a diff of this commit:
cvs rdiff -u -r1.154 -r1.155 src/sys/net/if_ppp.c
cvs rdiff -u -r1.124 -r1.125 src/sys/net/if_sl.c
cvs rdiff -u -r1.104 -r1.105 src/sys/net/if_strip.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/net/if_ppp.c
diff -u src/sys/net/if_ppp.c:1.154 src/sys/net/if_ppp.c:1.155
--- src/sys/net/if_ppp.c:1.154	Sat Aug  6 08:42:40 2016
+++ src/sys/net/if_ppp.c	Sat Aug  6 08:48:23 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_ppp.c,v 1.154 2016/08/06 12:42:40 pgoyette Exp $	*/
+/*	$NetBSD: if_ppp.c,v 1.155 2016/08/06 12:48:23 christos Exp $	*/
 /*	Id: if_ppp.c,v 1.6 1997/03/04 03:33:00 paulus Exp 	*/
 
 /*
@@ -102,7 +102,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_ppp.c,v 1.154 2016/08/06 12:42:40 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_ppp.c,v 1.155 2016/08/06 12:48:23 christos Exp $");
 
 #ifdef _KERNEL_OPT
 #include "ppp.h"
@@ -245,7 +245,7 @@ pppinit(void)
 {
 
 	if (ttyldisc_attach(_disc) != 0)
-		panic("pppattach");
+		panic("%s", __func__);
 
 	mutex_init(_list_lock, MUTEX_DEFAULT, IPL_NONE);
 	LIST_INIT(_softc_list);
@@ -255,12 +255,14 @@ pppinit(void)
 static int
 pppdetach(void)
 {
-	int error;
+	int error = 0;
 
 	if (!LIST_EMPTY(_softc_list))
 		error = EBUSY;
+
 	if (error == 0)
 		error = ttyldisc_detach(_disc);
+
 	return error;
 }
 

Index: src/sys/net/if_sl.c
diff -u src/sys/net/if_sl.c:1.124 src/sys/net/if_sl.c:1.125
--- src/sys/net/if_sl.c:1.124	Fri Jun 10 09:27:16 2016
+++ src/sys/net/if_sl.c	Sat Aug  6 08:48:23 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_sl.c,v 1.124 2016/06/10 13:27:16 ozaki-r Exp $	*/
+/*	$NetBSD: if_sl.c,v 1.125 2016/08/06 12:48:23 christos Exp $	*/
 
 /*
  * Copyright (c) 1987, 1989, 1992, 1993
@@ -60,7 +60,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_sl.c,v 1.124 2016/06/10 13:27:16 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_sl.c,v 1.125 2016/08/06 12:48:23 christos Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -85,6 +85,8 @@ __KERNEL_RCSID(0, "$NetBSD: if_sl.c,v 1.
 #endif
 #include 
 #include 
+#include 
+#include 
 
 #include 
 #include 
@@ -190,7 +192,7 @@ struct if_clone sl_cloner =
 
 static void	slintr(void *);
 
-static int	slinit(struct sl_softc *);
+static int	slcreate(struct sl_softc *);
 static struct mbuf *sl_btom(struct sl_softc *, int);
 
 static int	slclose(struct tty *, int);
@@ -219,13 +221,37 @@ void
 slattach(int n __unused)
 {
 
+	/*
+	 * Nothing to do here, initialization is handled by the
+	 * module initialization code in slinit() below).
+	 */
+}
+
+static void
+slinit(void)
+{
+
 	if (ttyldisc_attach(_disc) != 0)
-		panic("slattach");
+		panic("%s", __func__);
 	LIST_INIT(_softc_list);
 	if_clone_attach(_cloner);
 }
 
 static int
+sldetach(void)
+{
+	int error = 0;
+
+	if (!LIST_EMPTY(_softc_list))
+		error = EBUSY;
+
+	if (error == 0)
+		error = ttyldisc_detach(_disc);
+
+	return error;
+}
+
+static int
 sl_clone_create(struct if_clone *ifc, int unit)
 {
 	struct sl_softc *sc;
@@ -267,7 +293,7 @@ sl_clone_destroy(struct ifnet *ifp)
 }
 
 static int
-slinit(struct sl_softc *sc)
+slcreate(struct sl_softc *sc)
 {
 
 	if (sc->sc_mbuf == NULL) {
@@ -312,7 +338,7 @@ slopen(dev_t dev, struct tty *tp)
 			slintr, sc);
 			if (sc->sc_si == NULL)
 return ENOMEM;
-			if (slinit(sc) == 0) {
+			if (slcreate(sc) == 0) {
 softint_disestablish(sc->sc_si);
 return ENOBUFS;
 			}
@@ -1036,3 +1062,64 @@ slioctl(struct ifnet *ifp, u_long cmd, v
 	splx(s);
 	return error;
 }
+
+
+/*
+ * Module infrastructure
+ */
+
+MODULE(MODULE_CLASS_DRIVER, if_sl, "slcompress");
+
+#ifdef _MODULE
+CFDRIVER_DECL(sl, DV_IFNET, NULL);
+#endif
+
+static int
+if_sl_modcmd(modcmd_t cmd, void *arg)
+{
+	int error = 0;
+
+	switch (cmd) {
+	case MODULE_CMD_INIT:
+#ifdef _MODULE
+		error = config_cfdriver_attach(_cd);
+		if (error) {
+			aprint_error("%s: unable to register cfdriver for"
+			"%s, error %d\n", __func__, sl_cd.cd_name, error);
+			break;
+		}
+
+#endif
+		/* Init the unit list and line discipline stuff */
+		slinit();
+		break;
+
+	case MODULE_CMD_FINI:
+		/*
+		 * Make sure it's ok to detach - no units left, and
+		 * line discipline is removed
+		 */
+		error = sldetach();
+		if (error != 0)
+			break;
+#ifdef _MODULE
+		/* Remove device from autoconf database */
+		error = config_cfdriver_detach(_cd);
+		if (error) {
+			aprint_error("%s: failed to detach %s cfdriver, "
+			"error %d\n", __func__, sl_cd.cd_name, error);
+			break;
+		}
+#endif
+		break;
+
+	case MODULE_CMD_STAT:
+		error = ENOTTY;
+		break;
+	default:
+		error = ENOTTY;
+		break;
+	}
+
+	return error;
+}

Index: src/sys/net/if_strip.c
diff -u src/sys/net/if_strip.c:1.104 src/sys/net/if_strip.c:1.105

CVS commit: src/sys/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 12:44:03 UTC 2016

Modified Files:
src/sys/modules: Makefile
Added Files:
src/sys/modules/if_sl: Makefile sl.ioconf
src/sys/modules/if_strip: Makefile strip.ioconf

Log Message:
Add modules for strip and slip


To generate a diff of this commit:
cvs rdiff -u -r1.171 -r1.172 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_sl/Makefile \
src/sys/modules/if_sl/sl.ioconf
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_strip/Makefile \
src/sys/modules/if_strip/strip.ioconf

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

Modified files:

Index: src/sys/modules/Makefile
diff -u src/sys/modules/Makefile:1.171 src/sys/modules/Makefile:1.172
--- src/sys/modules/Makefile:1.171	Sat Aug  6 02:06:54 2016
+++ src/sys/modules/Makefile	Sat Aug  6 08:44:03 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.171 2016/08/06 06:06:54 christos Exp $
+#	$NetBSD: Makefile,v 1.172 2016/08/06 12:44:03 christos Exp $
 
 .include 
 
@@ -49,7 +49,9 @@ SUBDIR+=	if_axe
 SUBDIR+=	if_axen
 SUBDIR+=	if_npflog
 SUBDIR+=	if_ppp
+SUBDIR+=	if_sl
 SUBDIR+=	if_smsc
+SUBDIR+=	if_strip
 SUBDIR+=	iic
 SUBDIR+=	ipl
 SUBDIR+=	kernfs

Added files:

Index: src/sys/modules/if_sl/Makefile
diff -u /dev/null src/sys/modules/if_sl/Makefile:1.1
--- /dev/null	Sat Aug  6 08:44:03 2016
+++ src/sys/modules/if_sl/Makefile	Sat Aug  6 08:44:03 2016
@@ -0,0 +1,13 @@
+# $NetBSD: Makefile,v 1.1 2016/08/06 12:44:03 christos Exp $
+
+.include "../Makefile.inc"
+
+.PATH:  ${S}/net
+
+KMOD=		if_sl
+IOCONF=		sl.ioconf
+SRCS=		if_sl.c
+
+CPPFLAGS+=	-DINET
+
+.include 
Index: src/sys/modules/if_sl/sl.ioconf
diff -u /dev/null src/sys/modules/if_sl/sl.ioconf:1.1
--- /dev/null	Sat Aug  6 08:44:03 2016
+++ src/sys/modules/if_sl/sl.ioconf	Sat Aug  6 08:44:03 2016
@@ -0,0 +1,7 @@
+#	$NetBSD: sl.ioconf,v 1.1 2016/08/06 12:44:03 christos Exp $
+
+ioconf		sl
+
+include		"conf/files"
+
+pseudo-device   sl

Index: src/sys/modules/if_strip/Makefile
diff -u /dev/null src/sys/modules/if_strip/Makefile:1.1
--- /dev/null	Sat Aug  6 08:44:03 2016
+++ src/sys/modules/if_strip/Makefile	Sat Aug  6 08:44:03 2016
@@ -0,0 +1,13 @@
+# $NetBSD: Makefile,v 1.1 2016/08/06 12:44:03 christos Exp $
+
+.include "../Makefile.inc"
+
+.PATH:  ${S}/net
+
+KMOD=		if_strip
+IOCONF=		strip.ioconf
+SRCS=		if_strip.c
+
+CPPFLAGS+=	-DINET
+
+.include 
Index: src/sys/modules/if_strip/strip.ioconf
diff -u /dev/null src/sys/modules/if_strip/strip.ioconf:1.1
--- /dev/null	Sat Aug  6 08:44:03 2016
+++ src/sys/modules/if_strip/strip.ioconf	Sat Aug  6 08:44:03 2016
@@ -0,0 +1,7 @@
+#	$NetBSD: strip.ioconf,v 1.1 2016/08/06 12:44:03 christos Exp $
+
+ioconf		strip
+
+include		"conf/files"
+
+pseudo-device   strip



CVS commit: src/sys/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 12:44:03 UTC 2016

Modified Files:
src/sys/modules: Makefile
Added Files:
src/sys/modules/if_sl: Makefile sl.ioconf
src/sys/modules/if_strip: Makefile strip.ioconf

Log Message:
Add modules for strip and slip


To generate a diff of this commit:
cvs rdiff -u -r1.171 -r1.172 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_sl/Makefile \
src/sys/modules/if_sl/sl.ioconf
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_strip/Makefile \
src/sys/modules/if_strip/strip.ioconf

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



CVS commit: src/sys/net

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 12:42:41 UTC 2016

Modified Files:
src/sys/net: if_ppp.c

Log Message:
Change the internal name of the module to match its external (file
system) name.  Otherwise "bad things" can happen, such as modload(8)
being able to load a second copy!


To generate a diff of this commit:
cvs rdiff -u -r1.153 -r1.154 src/sys/net/if_ppp.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/net/if_ppp.c
diff -u src/sys/net/if_ppp.c:1.153 src/sys/net/if_ppp.c:1.154
--- src/sys/net/if_ppp.c:1.153	Sat Aug  6 02:35:06 2016
+++ src/sys/net/if_ppp.c	Sat Aug  6 12:42:40 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_ppp.c,v 1.153 2016/08/06 02:35:06 pgoyette Exp $	*/
+/*	$NetBSD: if_ppp.c,v 1.154 2016/08/06 12:42:40 pgoyette Exp $	*/
 /*	Id: if_ppp.c,v 1.6 1997/03/04 03:33:00 paulus Exp 	*/
 
 /*
@@ -102,7 +102,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_ppp.c,v 1.153 2016/08/06 02:35:06 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_ppp.c,v 1.154 2016/08/06 12:42:40 pgoyette Exp $");
 
 #ifdef _KERNEL_OPT
 #include "ppp.h"
@@ -1947,14 +1947,14 @@ ppp_unregister_compressor(struct compres
 #define PPP_DEP
 #endif
 
-MODULE(MODULE_CLASS_DRIVER, ppp, PPP_DEP "slcompress");
+MODULE(MODULE_CLASS_DRIVER, if_ppp, PPP_DEP "slcompress");
 
 #ifdef _MODULE
 CFDRIVER_DECL(ppp, DV_IFNET, NULL);
 #endif
 
 static int
-ppp_modcmd(modcmd_t cmd, void *arg)
+if_ppp_modcmd(modcmd_t cmd, void *arg)
 {
 	int error = 0;
 



CVS commit: src/sys/net

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 12:42:41 UTC 2016

Modified Files:
src/sys/net: if_ppp.c

Log Message:
Change the internal name of the module to match its external (file
system) name.  Otherwise "bad things" can happen, such as modload(8)
being able to load a second copy!


To generate a diff of this commit:
cvs rdiff -u -r1.153 -r1.154 src/sys/net/if_ppp.c

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



CVS commit: [pgoyette-localcount] src/sys/arch/x86/x86

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 10:45:22 UTC 2016

Modified Files:
src/sys/arch/x86/x86 [pgoyette-localcount]: pmap.c

Log Message:
Resolve $NetBSD$ conflict


To generate a diff of this commit:
cvs rdiff -u -r1.211.2.2 -r1.211.2.3 src/sys/arch/x86/x86/pmap.c

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



CVS commit: [pgoyette-localcount] src/sys/arch/x86/x86

2016-08-06 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sat Aug  6 10:45:22 UTC 2016

Modified Files:
src/sys/arch/x86/x86 [pgoyette-localcount]: pmap.c

Log Message:
Resolve $NetBSD$ conflict


To generate a diff of this commit:
cvs rdiff -u -r1.211.2.2 -r1.211.2.3 src/sys/arch/x86/x86/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/x86/x86/pmap.c
diff -u src/sys/arch/x86/x86/pmap.c:1.211.2.2 src/sys/arch/x86/x86/pmap.c:1.211.2.3
--- src/sys/arch/x86/x86/pmap.c:1.211.2.2	Sat Aug  6 00:19:06 2016
+++ src/sys/arch/x86/x86/pmap.c	Sat Aug  6 10:45:22 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.211.2.2 2016/08/06 00:19:06 pgoyette Exp $	*/
+/*	$NetBSD: pmap.c,v 1.211.2.3 2016/08/06 10:45:22 pgoyette Exp $	*/
 
 /*-
  * Copyright (c) 2008, 2010, 2016 The NetBSD Foundation, Inc.
@@ -171,11 +171,7 @@
  */
 
 #include 
-<<< pmap.c
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.211.2.2 2016/08/06 00:19:06 pgoyette Exp $");
-===
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.211.2.2 2016/08/06 00:19:06 pgoyette Exp $");
->>> 1.218
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.211.2.3 2016/08/06 10:45:22 pgoyette Exp $");
 
 #include "opt_user_ldt.h"
 #include "opt_lockdebug.h"



Re: CVS commit: src

2016-08-06 Thread Paul Goyette
This is all somewhat related to Christos's introduction of the MODULAR 
config yesterday, in an effort to reduce kernel footprint and get the 
number of "things" down below dtrace's limits.  :)


I'm not intending to make any changes to GENERIC...


On Sat, 6 Aug 2016, Robert Elz wrote:


   Date:Sat, 06 Aug 2016 16:26:24 +1000
   From:matthew green 
   Message-ID:  <27309.1470464...@splode.eterna.com.au>

 | > For now, this is still included as a built-in module in GENERIC kernels.
 |
 | i don't understand this "for now".

It may be because I read list messages in bizarre orders, but I had
already seen Christos later commits to fix things so autoloading ppp would
actually work, so when I read Paul's message I interpreted it more as

Kernel support for ppp being autoloaded is now there, but
you can't actually use it yet

Which is (probably) now no longer true - no idea, I don't use modules at all.

kre




+--+--++
| Paul Goyette | PGP Key fingerprint: | E-mail addresses:  |
| (Retired)| FA29 0E3B 35AF E8AE 6651 | paul at whooppee.com   |
| Kernel Developer | 0786 F758 55DE 53BA 7731 | pgoyette at netbsd.org |
+--+--++


Re: CVS commit: src

2016-08-06 Thread Robert Elz
Date:Sat, 06 Aug 2016 16:26:24 +1000
From:matthew green 
Message-ID:  <27309.1470464...@splode.eterna.com.au>

  | > For now, this is still included as a built-in module in GENERIC kernels.
  | 
  | i don't understand this "for now".

It may be because I read list messages in bizarre orders, but I had
already seen Christos later commits to fix things so autoloading ppp would
actually work, so when I read Paul's message I interpreted it more as

Kernel support for ppp being autoloaded is now there, but
you can't actually use it yet

Which is (probably) now no longer true - no idea, I don't use modules at all.

kre



CVS commit: src/sys/ufs/ext2fs

2016-08-06 Thread Jaromir Dolecek
Module Name:src
Committed By:   jdolecek
Date:   Sat Aug  6 09:29:28 UTC 2016

Modified Files:
src/sys/ufs/ext2fs: ext2fs_dinode.h

Log Message:
some more inode flags


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/sys/ufs/ext2fs/ext2fs_dinode.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/ufs/ext2fs/ext2fs_dinode.h
diff -u src/sys/ufs/ext2fs/ext2fs_dinode.h:1.34 src/sys/ufs/ext2fs/ext2fs_dinode.h:1.35
--- src/sys/ufs/ext2fs/ext2fs_dinode.h:1.34	Thu Aug  4 17:50:51 2016
+++ src/sys/ufs/ext2fs/ext2fs_dinode.h	Sat Aug  6 09:29:28 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ext2fs_dinode.h,v 1.34 2016/08/04 17:50:51 jdolecek Exp $	*/
+/*	$NetBSD: ext2fs_dinode.h,v 1.35 2016/08/06 09:29:28 jdolecek Exp $	*/
 
 /*
  * Copyright (c) 1982, 1989, 1993
@@ -199,7 +199,10 @@ struct ext2fs_dinode {
 #define EXT2_TOPDIR		0x0002 /* Top of directory hierarchies*/
 #define EXT2_HUGE_FILE		0x0004 /* Set to each huge file */
 #define EXT2_EXTENTS		0x0008 /* Inode uses extents */
+#define EXT2_EA_INODE		0x0020 /* Inode used for large EA */
 #define EXT2_EOFBLOCKS		0x0040 /* Blocks allocated beyond EOF */
+#define EXT2_INLINE_DATA	0x1000 /* Inode has inline data */
+#define EXT2_PROJINHERIT	0x2000 /* Children inherit project ID */
 
 /* Size of on-disk inode. */
 #define EXT2_REV0_DINODE_SIZE	128



CVS commit: src/sys/ufs/ext2fs

2016-08-06 Thread Jaromir Dolecek
Module Name:src
Committed By:   jdolecek
Date:   Sat Aug  6 09:29:28 UTC 2016

Modified Files:
src/sys/ufs/ext2fs: ext2fs_dinode.h

Log Message:
some more inode flags


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/sys/ufs/ext2fs/ext2fs_dinode.h

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



re: CVS commit: src

2016-08-06 Thread Paul Goyette

Yup - bad wording on my part.  Ignore the "for now" comment completely.


On Sat, 6 Aug 2016, matthew green wrote:


For now, this is still included as a built-in module in GENERIC kernels.


i don't understand this "for now".

GENERIC should continue to include all drivers.


.mrg.



+--+--++
| Paul Goyette | PGP Key fingerprint: | E-mail addresses:  |
| (Retired)| FA29 0E3B 35AF E8AE 6651 | paul at whooppee.com   |
| Kernel Developer | 0786 F758 55DE 53BA 7731 | pgoyette at netbsd.org |
+--+--++


re: CVS commit: src

2016-08-06 Thread matthew green
> For now, this is still included as a built-in module in GENERIC kernels.

i don't understand this "for now".

GENERIC should continue to include all drivers.


.mrg.


CVS commit: src/sys/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 06:06:54 UTC 2016

Modified Files:
src/sys/modules: Makefile
Added Files:
src/sys/modules/if_ppp: Makefile ppp.ioconf
Removed Files:
src/sys/modules/ppp: Makefile ppp.ioconf

Log Message:
rename the ppp module so that it autoloads.


To generate a diff of this commit:
cvs rdiff -u -r1.170 -r1.171 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_ppp/Makefile \
src/sys/modules/if_ppp/ppp.ioconf
cvs rdiff -u -r1.1 -r0 src/sys/modules/ppp/Makefile \
src/sys/modules/ppp/ppp.ioconf

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

Modified files:

Index: src/sys/modules/Makefile
diff -u src/sys/modules/Makefile:1.170 src/sys/modules/Makefile:1.171
--- src/sys/modules/Makefile:1.170	Fri Aug  5 22:35:05 2016
+++ src/sys/modules/Makefile	Sat Aug  6 02:06:54 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.170 2016/08/06 02:35:05 pgoyette Exp $
+#	$NetBSD: Makefile,v 1.171 2016/08/06 06:06:54 christos Exp $
 
 .include 
 
@@ -48,6 +48,7 @@ SUBDIR+=	i2c_bitbang
 SUBDIR+=	if_axe
 SUBDIR+=	if_axen
 SUBDIR+=	if_npflog
+SUBDIR+=	if_ppp
 SUBDIR+=	if_smsc
 SUBDIR+=	iic
 SUBDIR+=	ipl
@@ -79,7 +80,6 @@ SUBDIR+=	opencrypto
 SUBDIR+=	overlay
 SUBDIR+=	pciverbose
 SUBDIR+=	pf
-SUBDIR+=	ppp
 SUBDIR+=	ppp_bsdcomp
 SUBDIR+=	ppp_deflate
 SUBDIR+=	procfs

Added files:

Index: src/sys/modules/if_ppp/Makefile
diff -u /dev/null src/sys/modules/if_ppp/Makefile:1.1
--- /dev/null	Sat Aug  6 02:06:54 2016
+++ src/sys/modules/if_ppp/Makefile	Sat Aug  6 02:06:54 2016
@@ -0,0 +1,16 @@
+# $NetBSD: Makefile,v 1.1 2016/08/06 06:06:54 christos Exp $
+
+.include "../Makefile.inc"
+
+.PATH:  ${S}/net
+
+KMOD=		if_ppp
+IOCONF=		ppp.ioconf
+SRCS=		if_ppp.c ppp_tty.c
+
+CPPFLAGS+=	-DINET
+CPPFLAGS+=	-DPPP_FILTER
+CPPFLAGS+=	-DPPP_DEFLATE
+CPPFLAGS+=	-DPPP_BSDCOMP
+
+.include 
Index: src/sys/modules/if_ppp/ppp.ioconf
diff -u /dev/null src/sys/modules/if_ppp/ppp.ioconf:1.1
--- /dev/null	Sat Aug  6 02:06:54 2016
+++ src/sys/modules/if_ppp/ppp.ioconf	Sat Aug  6 02:06:54 2016
@@ -0,0 +1,7 @@
+#	$NetBSD: ppp.ioconf,v 1.1 2016/08/06 06:06:54 christos Exp $
+
+ioconf		ppp
+
+include		"conf/files"
+
+pseudo-device   ppp



CVS commit: src/sys/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 06:06:54 UTC 2016

Modified Files:
src/sys/modules: Makefile
Added Files:
src/sys/modules/if_ppp: Makefile ppp.ioconf
Removed Files:
src/sys/modules/ppp: Makefile ppp.ioconf

Log Message:
rename the ppp module so that it autoloads.


To generate a diff of this commit:
cvs rdiff -u -r1.170 -r1.171 src/sys/modules/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/modules/if_ppp/Makefile \
src/sys/modules/if_ppp/ppp.ioconf
cvs rdiff -u -r1.1 -r0 src/sys/modules/ppp/Makefile \
src/sys/modules/ppp/ppp.ioconf

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



CVS commit: src/distrib/sets/lists/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 06:04:48 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi

Log Message:
rename the ppp module so that it autoloads.


To generate a diff of this commit:
cvs rdiff -u -r1.88 -r1.89 src/distrib/sets/lists/modules/mi

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



CVS commit: src/distrib/sets/lists/modules

2016-08-06 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Aug  6 06:04:48 UTC 2016

Modified Files:
src/distrib/sets/lists/modules: mi

Log Message:
rename the ppp module so that it autoloads.


To generate a diff of this commit:
cvs rdiff -u -r1.88 -r1.89 src/distrib/sets/lists/modules/mi

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/modules/mi
diff -u src/distrib/sets/lists/modules/mi:1.88 src/distrib/sets/lists/modules/mi:1.89
--- src/distrib/sets/lists/modules/mi:1.88	Fri Aug  5 22:35:05 2016
+++ src/distrib/sets/lists/modules/mi	Sat Aug  6 02:04:48 2016
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.88 2016/08/06 02:35:05 pgoyette Exp $
+# $NetBSD: mi,v 1.89 2016/08/06 06:04:48 christos Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -126,6 +126,8 @@
 ./@MODULEDIR@/if_axen/if_axen.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/if_npflogbase-kernel-modules	kmod
 ./@MODULEDIR@/if_npflog/if_npflog.kmod		base-kernel-modules	kmod
+./@MODULEDIR@/if_pppbase-kernel-modules	kmod
+./@MODULEDIR@/if_ppp/if_ppp.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/if_smscbase-kernel-modules	kmod
 ./@MODULEDIR@/if_smsc/if_smsc.kmod		base-kernel-modules	kmod
 ./@MODULEDIR@/iicbase-kernel-modules	kmod
@@ -198,8 +200,6 @@
 ./@MODULEDIR@/pf/pf.kmod			base-kernel-modules	kmod
 ./@MODULEDIR@/portalbase-obsolete		obsolete
 ./@MODULEDIR@/portal/portal.kmod		base-obsolete		obsolete
-./@MODULEDIR@/pppbase-kernel-modules	kmod
-./@MODULEDIR@/ppp/ppp.kmod			base-kernel-modules	kmod
 ./@MODULEDIR@/ppp_bsdcomp			base-kernel-modules	kmod
 ./@MODULEDIR@/ppp_bsdcomp/ppp_bsdcomp.kmod	base-kernel-modules	kmod
 ./@MODULEDIR@/ppp_deflate			base-kernel-modules	kmod