CVS commit: src/sys/dev/i2c

2016-08-02 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Wed Aug  3 03:35:24 UTC 2016

Modified Files:
src/sys/dev/i2c: sdtemp.c sdtemp_reg.h

Log Message:
IDT's TSE2002GB2 has the same ID as TS3000GB2, so remove TSE2002GB2.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/sys/dev/i2c/sdtemp.c
cvs rdiff -u -r1.10 -r1.11 src/sys/dev/i2c/sdtemp_reg.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/dev/i2c/sdtemp.c
diff -u src/sys/dev/i2c/sdtemp.c:1.31 src/sys/dev/i2c/sdtemp.c:1.32
--- src/sys/dev/i2c/sdtemp.c:1.31	Thu Jul 28 09:11:13 2016
+++ src/sys/dev/i2c/sdtemp.c	Wed Aug  3 03:35:24 2016
@@ -1,4 +1,4 @@
-/*  $NetBSD: sdtemp.c,v 1.31 2016/07/28 09:11:13 msaitoh Exp $*/
+/*  $NetBSD: sdtemp.c,v 1.32 2016/08/03 03:35:24 msaitoh Exp $*/
 
 /*
  * Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: sdtemp.c,v 1.31 2016/07/28 09:11:13 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sdtemp.c,v 1.32 2016/08/03 03:35:24 msaitoh Exp $");
 
 #include 
 #include 
@@ -147,8 +147,6 @@ sdtemp_dev_table[] = {
 	"Catalyst CAT34TS02C" },
 { CAT_MANUFACTURER_ID,  CAT_34TS04_DEVICE_ID,CAT_34TS04_MASK,	  NULL,
 	"Catalyst CAT34TS04" },
-{ IDT_MANUFACTURER_ID,  IDT_TSE2002GB2_DEVICE_ID,IDT_TSE2002GB2_MASK, CIDT,
-	"Integrated Device Technology TSE2002GB2" },
 { IDT_MANUFACTURER_ID,  IDT_TSE2004GB2_DEVICE_ID,IDT_TSE2004GB2_MASK, NULL,
 	"Integrated Device Technology TSE2004GB2" },
 { IDT_MANUFACTURER_ID,  IDT_TS3000B3_DEVICE_ID,  IDT_TS3000B3_MASK,	  CIDT,

Index: src/sys/dev/i2c/sdtemp_reg.h
diff -u src/sys/dev/i2c/sdtemp_reg.h:1.10 src/sys/dev/i2c/sdtemp_reg.h:1.11
--- src/sys/dev/i2c/sdtemp_reg.h:1.10	Thu Jul 28 09:11:13 2016
+++ src/sys/dev/i2c/sdtemp_reg.h	Wed Aug  3 03:35:24 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: sdtemp_reg.h,v 1.10 2016/07/28 09:11:13 msaitoh Exp $	*/
+/*	$NetBSD: sdtemp_reg.h,v 1.11 2016/08/03 03:35:24 msaitoh Exp $	*/
 
 /*
  * Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -159,12 +159,10 @@
 #define	IDT_TS3000B3_MASK		0x
 #define	IDT_TS3000GB0_DEVICE_ID		0x2913
 #define	IDT_TS3000GB0_MASK		0x
-#define	IDT_TS3000GB2_DEVICE_ID		0x2912
+#define	IDT_TS3000GB2_DEVICE_ID		0x2912	/* Also matched TSE2002GB2 */
 #define	IDT_TS3000GB2_MASK		0x
 #define	IDT_TS3001GB2_DEVICE_ID		0x3001
 #define	IDT_TS3001GB2_MASK		0x
-#define	IDT_TSE2002GB2_DEVICE_ID	0x2912
-#define	IDT_TSE2002GB2_MASK		0x
 #define	IDT_TSE2004GB2_DEVICE_ID	0x2214
 #define	IDT_TSE2004GB2_MASK		0x
 



CVS commit: src/usr.bin/systat

2016-08-02 Thread Sean Cole
Module Name:src
Committed By:   scole
Date:   Tue Aug  2 17:53:46 UTC 2016

Modified Files:
src/usr.bin/systat: convtbl.c convtbl.h ifcmds.c ifstat.c

Log Message:
Add $NetBSD$ tag for new files


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/usr.bin/systat/convtbl.c \
src/usr.bin/systat/convtbl.h src/usr.bin/systat/ifcmds.c \
src/usr.bin/systat/ifstat.c

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

Modified files:

Index: src/usr.bin/systat/convtbl.c
diff -u src/usr.bin/systat/convtbl.c:1.1 src/usr.bin/systat/convtbl.c:1.2
--- src/usr.bin/systat/convtbl.c:1.1	Tue Aug  2 15:56:09 2016
+++ src/usr.bin/systat/convtbl.c	Tue Aug  2 17:53:46 2016
@@ -1,3 +1,5 @@
+/*	$NetBSD: convtbl.c,v 1.2 2016/08/02 17:53:46 scole Exp $	*/
+
 /*
  * Copyright (c) 2003, Trent Nelson, .
  * All rights reserved.
@@ -30,7 +32,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: convtbl.c,v 1.1 2016/08/02 15:56:09 scole Exp $");
+__RCSID("$NetBSD: convtbl.c,v 1.2 2016/08/02 17:53:46 scole Exp $");
 #endif /* not lint */
 
 #include 
Index: src/usr.bin/systat/convtbl.h
diff -u src/usr.bin/systat/convtbl.h:1.1 src/usr.bin/systat/convtbl.h:1.2
--- src/usr.bin/systat/convtbl.h:1.1	Tue Aug  2 15:56:09 2016
+++ src/usr.bin/systat/convtbl.h	Tue Aug  2 17:53:46 2016
@@ -1,3 +1,5 @@
+/*	$NetBSD: convtbl.h,v 1.2 2016/08/02 17:53:46 scole Exp $	*/
+
 /*
  * Copyright (c) 2003, Trent Nelson, .
  * All rights reserved.
Index: src/usr.bin/systat/ifcmds.c
diff -u src/usr.bin/systat/ifcmds.c:1.1 src/usr.bin/systat/ifcmds.c:1.2
--- src/usr.bin/systat/ifcmds.c:1.1	Tue Aug  2 15:56:09 2016
+++ src/usr.bin/systat/ifcmds.c	Tue Aug  2 17:53:46 2016
@@ -1,3 +1,5 @@
+/*	$NetBSD: ifcmds.c,v 1.2 2016/08/02 17:53:46 scole Exp $	*/
+
 /*
  * Copyright (c) 2003, Trent Nelson, .
  * All rights reserved.
@@ -30,7 +32,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: ifcmds.c,v 1.1 2016/08/02 15:56:09 scole Exp $");
+__RCSID("$NetBSD: ifcmds.c,v 1.2 2016/08/02 17:53:46 scole Exp $");
 #endif /* not lint */
 
 #include 
Index: src/usr.bin/systat/ifstat.c
diff -u src/usr.bin/systat/ifstat.c:1.1 src/usr.bin/systat/ifstat.c:1.2
--- src/usr.bin/systat/ifstat.c:1.1	Tue Aug  2 15:56:09 2016
+++ src/usr.bin/systat/ifstat.c	Tue Aug  2 17:53:46 2016
@@ -1,3 +1,5 @@
+/*	$NetBSD: ifstat.c,v 1.2 2016/08/02 17:53:46 scole Exp $	*/
+
 /*
  * Copyright (c) 2003, Trent Nelson, .
  * All rights reserved.
@@ -30,7 +32,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: ifstat.c,v 1.1 2016/08/02 15:56:09 scole Exp $");
+__RCSID("$NetBSD: ifstat.c,v 1.2 2016/08/02 17:53:46 scole Exp $");
 #endif /* not lint */
 
 #include 



CVS commit: src/sys/ufs/ext2fs

2016-08-02 Thread Jaromir Dolecek
Module Name:src
Committed By:   jdolecek
Date:   Tue Aug  2 17:36:02 UTC 2016

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

Log Message:
adjust the comments for on-disk ext2fs inode to indicate which of the ext* was 
it implemented for linux kernel; makes it a bit easier to locate

split e2di_linux_reserved3 with e2di_extra_isize and e2di_checksum_high, tag as 
ext4


To generate a diff of this commit:
cvs rdiff -u -r1.26 -r1.27 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.26 src/sys/ufs/ext2fs/ext2fs_dinode.h:1.27
--- src/sys/ufs/ext2fs/ext2fs_dinode.h:1.26	Tue Jan 22 09:39:15 2013
+++ src/sys/ufs/ext2fs/ext2fs_dinode.h	Tue Aug  2 17:36:02 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ext2fs_dinode.h,v 1.26 2013/01/22 09:39:15 dholland Exp $	*/
+/*	$NetBSD: ext2fs_dinode.h,v 1.27 2016/08/02 17:36:02 jdolecek Exp $	*/
 
 /*
  * Copyright (c) 1982, 1989, 1993
@@ -118,14 +118,15 @@ struct ext2fs_dinode {
 	uint32_t	e2di_blocks[EXT2FS_NDADDR+EXT2FS_NIADDR];
 	/* 40: disk blocks */
 	uint32_t	e2di_gen;	/* 100: generation number */
-	uint32_t	e2di_facl;	/* 104: file ACL (not implemented) */
-	uint32_t	e2di_dacl;	/* 108: dir ACL (not implemented) */
-	uint32_t	e2di_faddr;	/* 112: fragment address */
-	uint16_t	e2di_nblock_high; /* 116: Blocks count bits 47:32 */
-	uint16_t	e2di_facl_high; /* 118: file ACL bits 47:32 */
-	uint16_t	e2di_uid_high;	/* 120: Owner UID top 16 bits */
-	uint16_t	e2di_gid_high;	/* 122: Owner GID top 16 bits */
-	uint32_t	e2di_linux_reserved3; /* 124 */
+	uint32_t	e2di_facl;	/* 104: file ACL (not implemented) (ext3) */
+	uint32_t	e2di_dacl;	/* 108: dir ACL (not implemented) (ext3) */
+	uint32_t	e2di_obso_faddr;/* 112: obsolete fragment address (ext2) */
+	uint16_t	e2di_nblock_high; /* 116: Blocks count bits 47:32 (ext4) */
+	uint16_t	e2di_facl_high; /* 118: file ACL bits 47:32 (ext4) */
+	uint16_t	e2di_uid_high;	/* 120: Owner UID top 16 bits (ext4) */
+	uint16_t	e2di_gid_high;	/* 122: Owner GID top 16 bits (ext4) */
+	uint16_t	e2di_extra_isize; /* 124: inode extra size (over 128) actually used (ext4) */
+	uint16_t	e2di_checksum_high; /* 126: crc (not implemented) (ext4) */
 };
 
 



CVS commit: src/sys/ufs/ext2fs

2016-08-02 Thread Jaromir Dolecek
Module Name:src
Committed By:   jdolecek
Date:   Tue Aug  2 17:24:24 UTC 2016

Modified Files:
src/sys/ufs/ext2fs: ext2fs_bswap.c

Log Message:
do not bswap fragment address, support in ext* for them was never actually 
implemented in linux kernels


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/sys/ufs/ext2fs/ext2fs_bswap.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_bswap.c
diff -u src/sys/ufs/ext2fs/ext2fs_bswap.c:1.19 src/sys/ufs/ext2fs/ext2fs_bswap.c:1.20
--- src/sys/ufs/ext2fs/ext2fs_bswap.c:1.19	Tue Jan 22 09:39:15 2013
+++ src/sys/ufs/ext2fs/ext2fs_bswap.c	Tue Aug  2 17:24:24 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: ext2fs_bswap.c,v 1.19 2013/01/22 09:39:15 dholland Exp $	*/
+/*	$NetBSD: ext2fs_bswap.c,v 1.20 2016/08/02 17:24:24 jdolecek Exp $	*/
 
 /*
  * Copyright (c) 1997 Manuel Bouyer.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ext2fs_bswap.c,v 1.19 2013/01/22 09:39:15 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ext2fs_bswap.c,v 1.20 2016/08/02 17:24:24 jdolecek Exp $");
 
 #include 
 #include 
@@ -113,7 +113,6 @@ void e2fs_i_bswap(struct ext2fs_dinode *
 	new->e2di_gen		=	bswap32(old->e2di_gen);
 	new->e2di_facl		=	bswap32(old->e2di_facl);
 	new->e2di_dacl		=	bswap32(old->e2di_dacl);
-	new->e2di_faddr		=	bswap32(old->e2di_faddr);
 	new->e2di_nblock_high	=	bswap16(old->e2di_nblock_high);
 	new->e2di_facl_high	=	bswap16(old->e2di_facl_high);
 	new->e2di_uid_high	=	bswap16(old->e2di_uid_high);



CVS commit: src/usr.bin/systat

2016-08-02 Thread Sean Cole
Module Name:src
Committed By:   scole
Date:   Tue Aug  2 15:56:09 UTC 2016

Modified Files:
src/usr.bin/systat: Makefile cmds.c cmdtab.c extern.h systat.1
Added Files:
src/usr.bin/systat: convtbl.c convtbl.h ifcmds.c ifstat.c

Log Message:
PR bin/51204

Add ifstat command to systat.

Imported from FreeBSD


To generate a diff of this commit:
cvs rdiff -u -r1.38 -r1.39 src/usr.bin/systat/Makefile
cvs rdiff -u -r1.28 -r1.29 src/usr.bin/systat/cmds.c
cvs rdiff -u -r1.24 -r1.25 src/usr.bin/systat/cmdtab.c
cvs rdiff -u -r0 -r1.1 src/usr.bin/systat/convtbl.c \
src/usr.bin/systat/convtbl.h src/usr.bin/systat/ifcmds.c \
src/usr.bin/systat/ifstat.c
cvs rdiff -u -r1.44 -r1.45 src/usr.bin/systat/extern.h \
src/usr.bin/systat/systat.1

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

Modified files:

Index: src/usr.bin/systat/Makefile
diff -u src/usr.bin/systat/Makefile:1.38 src/usr.bin/systat/Makefile:1.39
--- src/usr.bin/systat/Makefile:1.38	Sat Jan 23 21:22:50 2016
+++ src/usr.bin/systat/Makefile	Tue Aug  2 15:56:09 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.38 2016/01/23 21:22:50 christos Exp $
+#	$NetBSD: Makefile,v 1.39 2016/08/02 15:56:09 scole Exp $
 #	@(#)Makefile	8.1 (Berkeley) 6/6/93
 
 .include 
@@ -11,10 +11,10 @@ PROG=	systat
 CPPFLAGS+=-I${NETBSDSRCDIR}/usr.bin/vmstat -DSUPPORT_UTMP -DSUPPORT_UTMPX \
 	-I${NETBSDSRCDIR}/usr.bin/who -D_KMEMUSER
 CWARNFLAGS+=-Wno-format-y2k
-SRCS=	bufcache.c cmds.c cmdtab.c disks.c df.c drvstats.c fetch.c \
-	globalcmds.c icmp.c iostat.c ip.c keyboard.c main.c mbufs.c \
-	netcmds.c netstat.c pigs.c ps.c swap.c tcp.c vmstat.c utmpentry.c \
-	syscall.c
+SRCS=	bufcache.c cmds.c cmdtab.c convtbl.c disks.c df.c drvstats.c \
+	fetch.c globalcmds.c icmp.c ifcmds.c ifstat.c iostat.c ip.c \
+	keyboard.c main.c mbufs.c netcmds.c netstat.c pigs.c ps.c swap.c \
+	tcp.c vmstat.c utmpentry.c syscall.c
 DPADD=	${LIBCURSES} ${LIBTERMINFO} ${LIBM} ${LIBKVM}
 LDADD=	-lutil -lcurses -lterminfo -lm -lkvm
 BINGRP=	kmem

Index: src/usr.bin/systat/cmds.c
diff -u src/usr.bin/systat/cmds.c:1.28 src/usr.bin/systat/cmds.c:1.29
--- src/usr.bin/systat/cmds.c:1.28	Thu Nov  4 07:18:47 2004
+++ src/usr.bin/systat/cmds.c	Tue Aug  2 15:56:09 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: cmds.c,v 1.28 2004/11/04 07:18:47 dsl Exp $	*/
+/*	$NetBSD: cmds.c,v 1.29 2016/08/02 15:56:09 scole Exp $	*/
 
 /*-
  * Copyright (c) 1980, 1992, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)cmds.c	8.2 (Berkeley) 4/29/95";
 #endif
-__RCSID("$NetBSD: cmds.c,v 1.28 2004/11/04 07:18:47 dsl Exp $");
+__RCSID("$NetBSD: cmds.c,v 1.29 2016/08/02 15:56:09 scole Exp $");
 #endif /* not lint */
 
 #include 
@@ -152,3 +152,15 @@ status(void)
 {
 	error("Showing %s, refresh every %d seconds.", curmode->c_name, naptime);
 }
+
+int
+prefix(const char *s1, const char *s2)
+{
+
+	while (*s1 == *s2) {
+		if (*s1 == '\0')
+			return (1);
+		s1++, s2++;
+	}
+	return (*s1 == '\0');
+}

Index: src/usr.bin/systat/cmdtab.c
diff -u src/usr.bin/systat/cmdtab.c:1.24 src/usr.bin/systat/cmdtab.c:1.25
--- src/usr.bin/systat/cmdtab.c:1.24	Fri Jan  6 14:08:08 2012
+++ src/usr.bin/systat/cmdtab.c	Tue Aug  2 15:56:09 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: cmdtab.c,v 1.24 2012/01/06 14:08:08 drochner Exp $	*/
+/*	$NetBSD: cmdtab.c,v 1.25 2016/08/02 15:56:09 scole Exp $	*/
 
 /*-
  * Copyright (c) 1980, 1992, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)cmdtab.c	8.1 (Berkeley) 6/6/93";
 #endif
-__RCSID("$NetBSD: cmdtab.c,v 1.24 2012/01/06 14:08:08 drochner Exp $");
+__RCSID("$NetBSD: cmdtab.c,v 1.25 2016/08/02 15:56:09 scole Exp $");
 #endif /* not lint */
 
 #include "systat.h"
@@ -69,6 +69,13 @@ struct command	icmp_commands[] = {
 	{ .c_name = NULL }
 };
 
+struct command ifstat_commands[] = {
+	{ "scale",	ifstat_scale,	"modify scale of display"},
+	{ "pps",	ifstat_pps, 	"toggle packets per second display"},
+	{ "match",	ifstat_match,   "display matching interfaces"},
+	{ .c_name = NULL }
+};
+
 struct command	iostat_commands[] = {
 	{ "bars",	iostat_bars,	"show io stats as a bar graph"},
 	{ "numbers",	iostat_numbers,	"show io stats numerically"},
@@ -159,6 +166,9 @@ struct mode modes[] = {
 	{ "df", showdf,  	fetchdf,	labeldf,
 	  initdf,	opendf,		closedf,	df_commands,
 	  CF_LOADAV },
+	{ "ifstat",	showifstat,	fetchifstat,	labelifstat,
+	  initifstat,	openifstat,	closeifstat,	ifstat_commands,
+	  CF_LOADAV },
 	{ "inet.icmp",	showicmp,	fetchicmp,	labelicmp,
 	  initicmp,	openicmp,	closeicmp,	icmp_commands,
 	  CF_LOADAV },

Index: src/usr.bin/systat/extern.h
diff -u src/usr.bin/systat/extern.h:1.44 src/usr.bin/systat/extern.h:1.45
--- src/usr.bin/systat/extern.h:1.44	Sun Aug 23 18:33:15 2015
+++ src/usr.bin/systat/extern.h	Tue Aug  2 15:56:09 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: extern.h,v 1.44 2015/08/23 18:33:15 mrg Exp $	*/
+/*	$NetBSD: extern.h,v 1.45 2016/08/02 15:56:09 scole Exp $	*/
 
 /*-
  * Copyright (c) 1991, 1993
@@ 

CVS commit: src/distrib/sets/lists

2016-08-02 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Tue Aug  2 14:54:03 UTC 2016

Modified Files:
src/distrib/sets/lists/base: shl.mi
src/distrib/sets/lists/debug: shl.mi

Log Message:
libssh.so.27 -> libssh.so.28


To generate a diff of this commit:
cvs rdiff -u -r1.778 -r1.779 src/distrib/sets/lists/base/shl.mi
cvs rdiff -u -r1.138 -r1.139 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/base/shl.mi
diff -u src/distrib/sets/lists/base/shl.mi:1.778 src/distrib/sets/lists/base/shl.mi:1.779
--- src/distrib/sets/lists/base/shl.mi:1.778	Sat Jul  2 15:40:51 2016
+++ src/distrib/sets/lists/base/shl.mi	Tue Aug  2 14:54:03 2016
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.778 2016/07/02 15:40:51 christos Exp $
+# $NetBSD: shl.mi,v 1.779 2016/08/02 14:54:03 jakllsch Exp $
 #
 # Note:	Don't delete entries from here - mark them as "obsolete" instead,
 #	unless otherwise stated below.
@@ -769,8 +769,8 @@
 ./usr/lib/libsqlite3.so.1.2			base-sys-shlib		compatfile
 ./usr/lib/libss.sobase-obsolete		obsolete
 ./usr/lib/libssh.sobase-secsh-shlib	compatfile,crypto
-./usr/lib/libssh.so.27base-secsh-shlib	compatfile,crypto
-./usr/lib/libssh.so.27.0			base-secsh-shlib	compatfile,crypto
+./usr/lib/libssh.so.28base-secsh-shlib	compatfile,crypto
+./usr/lib/libssh.so.28.0			base-secsh-shlib	compatfile,crypto
 ./usr/lib/libssl.sobase-crypto-shlib	compatfile,crypto
 ./usr/lib/libssl.so.11base-crypto-shlib	compatfile,crypto
 ./usr/lib/libssl.so.11.0			base-crypto-shlib	compatfile,crypto

Index: src/distrib/sets/lists/debug/shl.mi
diff -u src/distrib/sets/lists/debug/shl.mi:1.138 src/distrib/sets/lists/debug/shl.mi:1.139
--- src/distrib/sets/lists/debug/shl.mi:1.138	Sat Jul  2 15:40:51 2016
+++ src/distrib/sets/lists/debug/shl.mi	Tue Aug  2 14:54:03 2016
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.138 2016/07/02 15:40:51 christos Exp $
+# $NetBSD: shl.mi,v 1.139 2016/08/02 14:54:03 jakllsch 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
@@ -260,7 +260,7 @@
 ./usr/libdata/debug/usr/lib/libskey.so.2.0.debug		comp-sys-debug	debug,compatfile,skey
 ./usr/libdata/debug/usr/lib/libsl.so.5.0.debug			comp-krb5-debug	debug,compatfile,kerberos
 ./usr/libdata/debug/usr/lib/libsqlite3.so.1.2.debug		comp-sys-debug	debug,compatfile
-./usr/libdata/debug/usr/lib/libssh.so.27.0.debug		comp-secsh-debug	debug,compatfile,crypto
+./usr/libdata/debug/usr/lib/libssh.so.28.0.debug		comp-secsh-debug	debug,compatfile,crypto
 ./usr/libdata/debug/usr/lib/libssl.so.11.0.debug		comp-crypto-debug	debug,compatfile,crypto
 ./usr/libdata/debug/usr/lib/libstdc++.so.7.3.debug		comp-sys-debug	debug,compatfile,gcc=48,cxx,libstdcxx
 ./usr/libdata/debug/usr/lib/libstdc++.so.7.4.debug		comp-sys-debug	debug,compatfile,gcc=53,cxx,libstdcxx



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

2016-08-02 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Aug  2 14:21:53 UTC 2016

Modified Files:
src/sys/arch/xen/x86: x86_xpmap.c

Log Message:
Map the kernel text, rodata and data+bss independently on Xen, with
respectively RX, R and RW.


To generate a diff of this commit:
cvs rdiff -u -r1.56 -r1.57 src/sys/arch/xen/x86/x86_xpmap.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/xen/x86/x86_xpmap.c
diff -u src/sys/arch/xen/x86/x86_xpmap.c:1.56 src/sys/arch/xen/x86/x86_xpmap.c:1.57
--- src/sys/arch/xen/x86/x86_xpmap.c:1.56	Tue Aug  2 13:29:35 2016
+++ src/sys/arch/xen/x86/x86_xpmap.c	Tue Aug  2 14:21:53 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: x86_xpmap.c,v 1.56 2016/08/02 13:29:35 maxv Exp $	*/
+/*	$NetBSD: x86_xpmap.c,v 1.57 2016/08/02 14:21:53 maxv Exp $	*/
 
 /*
  * Copyright (c) 2006 Mathieu Ropert 
@@ -69,7 +69,7 @@
 
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.56 2016/08/02 13:29:35 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.57 2016/08/02 14:21:53 maxv Exp $");
 
 #include "opt_xen.h"
 #include "opt_ddb.h"
@@ -730,15 +730,24 @@ xen_bootstrap_tables(vaddr_t old_pgd, va
 	pd_entry_t *pdtpe, *pde, *pte;
 	pd_entry_t *bt_pgd;
 	paddr_t addr;
-	vaddr_t page, avail, text_end, map_end;
+	vaddr_t page, avail, map_end;
 	int i;
+	extern char __rodata_start;
 	extern char __data_start;
+	extern char __kernel_end;
 	extern char *early_zerop; /* from pmap.c */
+	pt_entry_t pg_nx;
+	u_int descs[4];
 
 	__PRINTK(("xen_bootstrap_tables(%#" PRIxVADDR ", %#" PRIxVADDR ","
 	" %d, %d)\n",
 	old_pgd, new_pgd, old_count, new_count));
-	text_end = ((vaddr_t)&__data_start) & ~PAGE_MASK;
+
+	/*
+	 * Set the NX/XD bit, if available. descs[3] = %edx.
+	 */
+	x86_cpuid(0x8001, descs);
+	pg_nx = (descs[3] & CPUID_NOX) ? PG_NX : 0;
 
 	/*
 	 * size of R/W area after kernel text:
@@ -776,8 +785,7 @@ xen_bootstrap_tables(vaddr_t old_pgd, va
 	}
 #endif /* DOM0OPS */
 
-	__PRINTK(("xen_bootstrap_tables text_end 0x%lx map_end 0x%lx\n",
-	text_end, map_end));
+	__PRINTK(("xen_bootstrap_tables map_end 0x%lx\n", map_end));
 	__PRINTK(("console %#lx ", xen_start_info.console_mfn));
 	__PRINTK(("xenstore %#" PRIx32 "\n", xen_start_info.store_mfn));
 
@@ -907,10 +915,19 @@ xen_bootstrap_tables(vaddr_t old_pgd, va
 IOM_BEGIN + (page - (vaddr_t)atdevbase);
 			}
 #endif
+
 			pte[pl1_pi(page)] |= PG_k | PG_V;
-			if (page < text_end) {
-/* map kernel text RO */
+			if (page < (vaddr_t)&__rodata_start) {
+/* Map kernel text RX. */
 pte[pl1_pi(page)] |= PG_RO;
+			} else if (page >= (vaddr_t)&__rodata_start &&
+			page < (vaddr_t)&__data_start) {
+/* Map the kernel rodata R. */
+pte[pl1_pi(page)] |= PG_RO | pg_nx;
+			} else if (page >= (vaddr_t)&__data_start &&
+			page < (vaddr_t)&__kernel_end) {
+/* Map the kernel data+bss RW. */
+pte[pl1_pi(page)] |= PG_RW | pg_nx;
 			} else if (page >= old_pgd &&
 			page < old_pgd + (old_count * PAGE_SIZE)) {
 /* map old page tables RO */



CVS commit: src/sys/arch

2016-08-02 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Aug  2 14:03:34 UTC 2016

Modified Files:
src/sys/arch/amd64/conf: kern.ldscript.Xen
src/sys/arch/i386/conf: kern.ldscript.Xen

Log Message:
Align the segments properly, and split text+rodata in two separate segments
on Xen.


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/amd64/conf/kern.ldscript.Xen
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/i386/conf/kern.ldscript.Xen

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/conf/kern.ldscript.Xen
diff -u src/sys/arch/amd64/conf/kern.ldscript.Xen:1.12 src/sys/arch/amd64/conf/kern.ldscript.Xen:1.13
--- src/sys/arch/amd64/conf/kern.ldscript.Xen:1.12	Fri May 13 05:45:13 2016
+++ src/sys/arch/amd64/conf/kern.ldscript.Xen	Tue Aug  2 14:03:34 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: kern.ldscript.Xen,v 1.12 2016/05/13 05:45:13 maxv Exp $	*/
+/*	$NetBSD: kern.ldscript.Xen,v 1.13 2016/08/02 14:03:34 maxv Exp $	*/
 
 #include "assym.h"
 
@@ -7,24 +7,26 @@ __PAGE_SIZE = 0x1000 ;
 ENTRY(_start)
 SECTIONS
 {
-	/* Read-only sections, merged into text segment: */
 	.text :
 	{
 		*(.text)
 		*(.text.*)
 		*(.stub)
-		*(.rodata)
 	}
 	_etext = . ;
 	PROVIDE (etext = .) ;
 
-	/*
-	 * Adjust the address for the data segment.  We want to adjust up to
-	 * the same address within the page on the next page up.
-	 */
-	. = ALIGN(0x10) + (. & (0x10 - 1));
+	. = ALIGN(__PAGE_SIZE);
 
 	__rodata_start = . ;
+	.rodata :
+	{
+		*(.rodata)
+		*(.rodata.*)
+	}
+
+	. = ALIGN(__PAGE_SIZE);
+
 	__data_start = . ;
 	.data :
 	{
@@ -53,7 +55,12 @@ SECTIONS
 		*(COMMON)
 		. = ALIGN(64 / 8);
 	}
-	. = ALIGN(64 / 8);
+
+	. = ALIGN(__PAGE_SIZE);
+
+	/* End of the kernel image */
+	__kernel_end = . ;
+
 	_end = . ;
 	PROVIDE (end = .) ;
 	.note.netbsd.ident :

Index: src/sys/arch/i386/conf/kern.ldscript.Xen
diff -u src/sys/arch/i386/conf/kern.ldscript.Xen:1.12 src/sys/arch/i386/conf/kern.ldscript.Xen:1.13
--- src/sys/arch/i386/conf/kern.ldscript.Xen:1.12	Fri May 13 05:45:13 2016
+++ src/sys/arch/i386/conf/kern.ldscript.Xen	Tue Aug  2 14:03:34 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: kern.ldscript.Xen,v 1.12 2016/05/13 05:45:13 maxv Exp $	*/
+/*	$NetBSD: kern.ldscript.Xen,v 1.13 2016/08/02 14:03:34 maxv Exp $	*/
 
 #include "assym.h"
 
@@ -6,7 +6,6 @@ __PAGE_SIZE = 0x1000 ;
 
 SECTIONS
 {
-	/* Read-only sections, merged into text segment: */
 	.text :
 	{
 		*(.text)
@@ -16,19 +15,17 @@ SECTIONS
 	_etext = . ;
 	PROVIDE (etext = .) ;
 
+	. = ALIGN(__PAGE_SIZE);
+
+	__rodata_start = . ;
 	.rodata :
 	{
 		*(.rodata)
 		*(.rodata.*)
 	}
 
-	/*
-	 * Adjust the address for the data segment.  We want to adjust up to
-	 * the same address within the page on the next page up.
-	 */
-	. = ALIGN(0x1000) + (. & (0x1000 - 1));
+	. = ALIGN(__PAGE_SIZE);
 
-	__rodata_start = . ;
 	__data_start = . ;
 	.data :
 	{
@@ -46,8 +43,8 @@ SECTIONS
 		*(.data.read_mostly)
 	}
 	. = ALIGN(COHERENCY_UNIT);
-	_edata = . ;
 
+	_edata = . ;
 	PROVIDE (edata = .) ;
 	__bss_start = . ;
 	.bss :
@@ -57,7 +54,12 @@ SECTIONS
 		*(COMMON)
 		. = ALIGN(32 / 8);
 	}
-	. = ALIGN(32 / 8);
+
+	. = ALIGN(__PAGE_SIZE);
+
+	/* End of the kernel image */
+	__kernel_end = . ;
+
 	_end = . ;
 	PROVIDE (end = .) ;
 	.note.netbsd.ident :



CVS commit: src/crypto/external/bsd/openssh/dist

2016-08-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Aug  2 13:53:45 UTC 2016

Modified Files:
src/crypto/external/bsd/openssh/dist: canohost.c

Log Message:
remove unused code


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/crypto/external/bsd/openssh/dist/canohost.c

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

Modified files:

Index: src/crypto/external/bsd/openssh/dist/canohost.c
diff -u src/crypto/external/bsd/openssh/dist/canohost.c:1.9 src/crypto/external/bsd/openssh/dist/canohost.c:1.10
--- src/crypto/external/bsd/openssh/dist/canohost.c:1.9	Tue Aug  2 09:45:12 2016
+++ src/crypto/external/bsd/openssh/dist/canohost.c	Tue Aug  2 09:53:44 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: canohost.c,v 1.9 2016/08/02 13:45:12 christos Exp $	*/
+/*	$NetBSD: canohost.c,v 1.10 2016/08/02 13:53:44 christos Exp $	*/
 /* $OpenBSD: canohost.c,v 1.73 2016/03/07 19:02:43 djm Exp $ */
 /*
  * Author: Tatu Ylonen 
@@ -14,7 +14,7 @@
  */
 
 #include "includes.h"
-__RCSID("$NetBSD: canohost.c,v 1.9 2016/08/02 13:45:12 christos Exp $");
+__RCSID("$NetBSD: canohost.c,v 1.10 2016/08/02 13:53:44 christos Exp $");
 #include 
 #include 
 #include 
@@ -36,173 +36,6 @@ __RCSID("$NetBSD: canohost.c,v 1.9 2016/
 #include "canohost.h"
 #include "misc.h"
 
-#if removeme
-static void check_ip_options(int, char *);
-static char *canonical_host_ip = NULL;
-static int cached_port = -1;
-
-/*
- * Return the canonical name of the host at the other end of the socket. The
- * caller should free the returned string.
- */
-
-static char *
-get_remote_hostname(int sock, int use_dns)
-{
-	struct sockaddr_storage from;
-	socklen_t fromlen;
-	struct addrinfo hints, *ai, *aitop;
-	char name[NI_MAXHOST], ntop[NI_MAXHOST], ntop2[NI_MAXHOST];
-
-	/* Get IP address of client. */
-	fromlen = sizeof(from);
-	memset(, 0, sizeof(from));
-	if (getpeername(sock, (struct sockaddr *), ) < 0) {
-		debug("getpeername failed: %.100s", strerror(errno));
-		cleanup_exit(255);
-	}
-
-	if (getnameinfo((struct sockaddr *), fromlen, ntop, sizeof(ntop),
-	NULL, 0, NI_NUMERICHOST) != 0)
-		fatal("get_remote_hostname: getnameinfo NI_NUMERICHOST failed");
-
-	if (from.ss_family == AF_INET)
-		check_ip_options(sock, ntop);
-
-	if (!use_dns)
-		return xstrdup(ntop);
-
-	debug3("Trying to reverse map address %.100s.", ntop);
-	/* Map the IP address to a host name. */
-	if (getnameinfo((struct sockaddr *), fromlen, name, sizeof(name),
-	NULL, 0, NI_NAMEREQD) != 0) {
-		/* Host name not found.  Use ip address. */
-		return xstrdup(ntop);
-	}
-
-	/*
-	 * if reverse lookup result looks like a numeric hostname,
-	 * someone is trying to trick us by PTR record like following:
-	 *	1.1.1.10.in-addr.arpa.	IN PTR	2.3.4.5
-	 */
-	memset(, 0, sizeof(hints));
-	hints.ai_socktype = SOCK_DGRAM;	/*dummy*/
-	hints.ai_flags = AI_NUMERICHOST;
-	if (getaddrinfo(name, NULL, , ) == 0) {
-		logit("Nasty PTR record \"%s\" is set up for %s, ignoring",
-		name, ntop);
-		freeaddrinfo(ai);
-		return xstrdup(ntop);
-	}
-
-	/* Names are stores in lowercase. */
-	lowercase(name);
-
-	/*
-	 * Map it back to an IP address and check that the given
-	 * address actually is an address of this host.  This is
-	 * necessary because anyone with access to a name server can
-	 * define arbitrary names for an IP address. Mapping from
-	 * name to IP address can be trusted better (but can still be
-	 * fooled if the intruder has access to the name server of
-	 * the domain).
-	 */
-	memset(, 0, sizeof(hints));
-	hints.ai_family = from.ss_family;
-	hints.ai_socktype = SOCK_STREAM;
-	if (getaddrinfo(name, NULL, , ) != 0) {
-		logit("reverse mapping checking getaddrinfo for %.700s "
-		"[%s] failed - POSSIBLE BREAK-IN ATTEMPT!", name, ntop);
-		return xstrdup(ntop);
-	}
-	/* Look for the address from the list of addresses. */
-	for (ai = aitop; ai; ai = ai->ai_next) {
-		if (getnameinfo(ai->ai_addr, ai->ai_addrlen, ntop2,
-		sizeof(ntop2), NULL, 0, NI_NUMERICHOST) == 0 &&
-		(strcmp(ntop, ntop2) == 0))
-break;
-	}
-	freeaddrinfo(aitop);
-	/* If we reached the end of the list, the address was not there. */
-	if (!ai) {
-		/* Address not found for the host name. */
-		logit("Address %.100s maps to %.600s, but this does not "
-		"map back to the address - POSSIBLE BREAK-IN ATTEMPT!",
-		ntop, name);
-		return xstrdup(ntop);
-	}
-	return xstrdup(name);
-}
-
-/*
- * If IP options are supported, make sure there are none (log and
- * disconnect them if any are found).  Basically we are worried about
- * source routing; it can be used to pretend you are somebody
- * (ip-address) you are not. That itself may be "almost acceptable"
- * under certain circumstances, but rhosts autentication is useless
- * if source routing is accepted. Notice also that if we just dropped
- * source routing here, the other side could use IP spoofing to do
- * rest of the interaction and could still 

CVS commit: src/doc

2016-08-02 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Aug  2 13:45:46 UTC 2016

Modified Files:
src/doc: 3RDPARTY CHANGES

Log Message:
new openssh


To generate a diff of this commit:
cvs rdiff -u -r1.1348 -r1.1349 src/doc/3RDPARTY
cvs rdiff -u -r1.2177 -r1.2178 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.1348 src/doc/3RDPARTY:1.1349
--- src/doc/3RDPARTY:1.1348	Mon Aug  1 11:01:49 2016
+++ src/doc/3RDPARTY	Tue Aug  2 09:45:46 2016
@@ -1,4 +1,4 @@
-#	$NetBSD: 3RDPARTY,v 1.1348 2016/08/01 15:01:49 wiz Exp $
+#	$NetBSD: 3RDPARTY,v 1.1349 2016/08/02 13:45:46 christos Exp $
 #
 # This file contains a list of the software that has been integrated into
 # NetBSD where we are not the primary maintainer.
@@ -1003,7 +1003,7 @@ Notes:
 Patch applied after OpenSSH import.
 
 Package:	OpenSSH
-Version:	7.2
+Version:	7.3
 Current Vers:	7.3 / portable 7.3p1
 Maintainer:	OpenSSH
 Archive Site:	http://www.openssh.com/ftp.html

Index: src/doc/CHANGES
diff -u src/doc/CHANGES:1.2177 src/doc/CHANGES:1.2178
--- src/doc/CHANGES:1.2177	Thu Jul 28 05:13:06 2016
+++ src/doc/CHANGES	Tue Aug  2 09:45:46 2016
@@ -1,4 +1,4 @@
-# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2177 $>
+# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.2178 $>
 #
 #
 # [Note: This file does not mention every change made to the NetBSD source tree.
@@ -336,3 +336,4 @@ Changes from NetBSD 7.0 to NetBSD 8.0:
 		TS3000GB[02], TS3001GB2, TSE200[24]GB2 and On Semiconductor
 		CAT34TS04. [msaitoh 20160726]
 	sdtemp(4): Add JEDEC TSE2004av support. [msaitoh 20160728]
+	OpenSSH: Imported 7.3. [christos 20160802]



CVS import: src/crypto/external/bsd/openssh/dist

2016-08-02 Thread Christos Zoulas
tOnForwardFailure and hostname
   canonicalisation are enabled. bz#2562

 * sshd(8): Remove fallback from moduli to obsolete "primes" file
   that was deprecated in 2001. bz#2559.

 * sshd_config(5): Correct description of UseDNS: it affects ssh
   hostname processing for authorized_keys, not known_hosts; bz#2554

 * ssh(1): Fix authentication using lone certificate keys in an agent
   without corresponding private keys on the filesystem. bz#2550

 * sshd(8): Send ClientAliveInterval pings when a time-based
   RekeyLimit is set; previously keepalive packets were not being
   sent. bz#2252

Portability
---

 * ssh(1), sshd(8): Fix compilation by automatically disabling ciphers
   not supported by OpenSSL. bz#2466

 * misc: Fix compilation failures on some versions of AIX's compiler
   related to the definition of the VA_COPY macro. bz#2589

 * sshd(8): Whitelist more architectures to enable the seccomp-bpf
   sandbox. bz#2590

 * ssh-agent(1), sftp-server(8): Disable process tracing on Solaris
   using setpflags(__PROC_PROTECT, ...). bz#2584

 * sshd(8): On Solaris, don't call Solaris setproject() with
   UsePAM=yes it's PAM's responsibility. bz#2425

Checksums:
==

 - SHA1 (openssh-7.3.tar.gz) = b1641e5265d9ec68a9a19decc3a7edd1203cbd33
 - SHA256 (openssh-7.3.tar.gz) = vS0X35qrX9OOPBkyDMYhOje/DBwHBVEV7nv5rkzw4vM=

 - SHA1 (openssh-7.3p1.tar.gz) = bfade84283fcba885e2084343ab19a08c7d123a5
 - SHA256 (openssh-7.3p1.tar.gz) = P/uYmm3KppWUw7VQ1IVaWi4XGMzd5/XjY4e0JCIPvsw=

Please note that the SHA256 signatures are base64 encoded and not
hexadecimal (which is the default for most checksum tools). The PGP
key used to sign the releases is available as RELEASE_KEY.asc from
the mirror sites.

Reporting Bugs:
===

- Please read http://www.openssh.com/report.html
  Security bugs should be reported directly to open...@openssh.com

OpenSSH is brought to you by Markus Friedl, Niels Provos, Theo de
Raadt, Kevin Steves, Damien Miller, Darren Tucker, Jason McIntyre,
Tim Rice and Ben Lindstrom.

Status:

Vendor Tag: OPENSSH
Release Tags:   v73-20160802

C src/crypto/external/bsd/openssh/dist/PROTOCOL.agent
U src/crypto/external/bsd/openssh/dist/hostfile.c
U src/crypto/external/bsd/openssh/dist/LICENCE
U src/crypto/external/bsd/openssh/dist/OVERVIEW
C src/crypto/external/bsd/openssh/dist/PROTOCOL
U src/crypto/external/bsd/openssh/dist/PROTOCOL.chacha20poly1305
C src/crypto/external/bsd/openssh/dist/PROTOCOL.certkeys
U src/crypto/external/bsd/openssh/dist/auth-bsdauth.c
U src/crypto/external/bsd/openssh/dist/PROTOCOL.key
U src/crypto/external/bsd/openssh/dist/PROTOCOL.krl
U src/crypto/external/bsd/openssh/dist/PROTOCOL.mux
U src/crypto/external/bsd/openssh/dist/README
U src/crypto/external/bsd/openssh/dist/addrmatch.c
U src/crypto/external/bsd/openssh/dist/atomicio.c
U src/crypto/external/bsd/openssh/dist/atomicio.h
C src/crypto/external/bsd/openssh/dist/canohost.c
U src/crypto/external/bsd/openssh/dist/auth-chall.c
C src/crypto/external/bsd/openssh/dist/auth-krb5.c
C src/crypto/external/bsd/openssh/dist/auth-options.c
U src/crypto/external/bsd/openssh/dist/auth-options.h
U src/crypto/external/bsd/openssh/dist/hmac.c
C src/crypto/external/bsd/openssh/dist/auth-passwd.c
C src/crypto/external/bsd/openssh/dist/auth-rh-rsa.c
C src/crypto/external/bsd/openssh/dist/auth-rhosts.c
U src/crypto/external/bsd/openssh/dist/auth-rsa.c
C src/crypto/external/bsd/openssh/dist/auth.c
C src/crypto/external/bsd/openssh/dist/auth.h
U src/crypto/external/bsd/openssh/dist/auth1.c
C src/crypto/external/bsd/openssh/dist/auth2-chall.c
U src/crypto/external/bsd/openssh/dist/auth2-gss.c
C src/crypto/external/bsd/openssh/dist/auth2-hostbased.c
U src/crypto/external/bsd/openssh/dist/auth2-kbdint.c
U src/crypto/external/bsd/openssh/dist/auth2-none.c
U src/crypto/external/bsd/openssh/dist/auth2-passwd.c
U src/crypto/external/bsd/openssh/dist/auth2-pubkey.c
C src/crypto/external/bsd/openssh/dist/auth2.c
U src/crypto/external/bsd/openssh/dist/authfd.c
U src/crypto/external/bsd/openssh/dist/authfd.h
C src/crypto/external/bsd/openssh/dist/authfile.c
U src/crypto/external/bsd/openssh/dist/authfile.h
U src/crypto/external/bsd/openssh/dist/bitmap.c
U src/crypto/external/bsd/openssh/dist/bitmap.h
U src/crypto/external/bsd/openssh/dist/blocks.c
U src/crypto/external/bsd/openssh/dist/bufaux.c
U src/crypto/external/bsd/openssh/dist/bufbn.c
U src/crypto/external/bsd/openssh/dist/bufec.c
U src/crypto/external/bsd/openssh/dist/buffer.c
U src/crypto/external/bsd/openssh/dist/buffer.h
U src/crypto/external/bsd/openssh/dist/cipher-3des1.c
C src/crypto/external/bsd/openssh/dist/canohost.h
U src/crypto/external/bsd/openssh/dist/chacha.c
U src/crypto/external/bsd/openssh/dist/chacha.h
C src/crypto/external/bsd/openssh/dist/channels.c
U src/crypto/external/bsd/openssh/dist/channels.h
U src/crypto/external/bsd/openssh/dist/cipher-chachapoly.c
U src/crypto/external/bsd/openssh/dist/cipher-aesctr.c
U src/crypto/externa

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

2016-08-02 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Aug  2 13:29:35 UTC 2016

Modified Files:
src/sys/arch/xen/x86: x86_xpmap.c

Log Message:
Use PG_RO instead of a magic zero.


To generate a diff of this commit:
cvs rdiff -u -r1.55 -r1.56 src/sys/arch/xen/x86/x86_xpmap.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/xen/x86/x86_xpmap.c
diff -u src/sys/arch/xen/x86/x86_xpmap.c:1.55 src/sys/arch/xen/x86/x86_xpmap.c:1.56
--- src/sys/arch/xen/x86/x86_xpmap.c:1.55	Tue Aug  2 13:25:56 2016
+++ src/sys/arch/xen/x86/x86_xpmap.c	Tue Aug  2 13:29:35 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: x86_xpmap.c,v 1.55 2016/08/02 13:25:56 maxv Exp $	*/
+/*	$NetBSD: x86_xpmap.c,v 1.56 2016/08/02 13:29:35 maxv Exp $	*/
 
 /*
  * Copyright (c) 2006 Mathieu Ropert 
@@ -69,7 +69,7 @@
 
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.55 2016/08/02 13:25:56 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.56 2016/08/02 13:29:35 maxv Exp $");
 
 #include "opt_xen.h"
 #include "opt_ddb.h"
@@ -910,15 +910,15 @@ xen_bootstrap_tables(vaddr_t old_pgd, va
 			pte[pl1_pi(page)] |= PG_k | PG_V;
 			if (page < text_end) {
 /* map kernel text RO */
-pte[pl1_pi(page)] |= 0;
+pte[pl1_pi(page)] |= PG_RO;
 			} else if (page >= old_pgd &&
 			page < old_pgd + (old_count * PAGE_SIZE)) {
 /* map old page tables RO */
-pte[pl1_pi(page)] |= 0;
+pte[pl1_pi(page)] |= PG_RO;
 			} else if (page >= new_pgd &&
 			page < new_pgd + ((new_count + l2_4_count) * PAGE_SIZE)) {
 /* map new page tables RO */
-pte[pl1_pi(page)] |= 0;
+pte[pl1_pi(page)] |= PG_RO;
 #ifdef i386
 			} else if (page == (vaddr_t)tmpgdt) {
 /*



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

2016-08-02 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Aug  2 13:25:56 UTC 2016

Modified Files:
src/sys/arch/xen/x86: x86_xpmap.c

Log Message:
KNF, and use PAGE_SIZE instead of NBPG.


To generate a diff of this commit:
cvs rdiff -u -r1.54 -r1.55 src/sys/arch/xen/x86/x86_xpmap.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/xen/x86/x86_xpmap.c
diff -u src/sys/arch/xen/x86/x86_xpmap.c:1.54 src/sys/arch/xen/x86/x86_xpmap.c:1.55
--- src/sys/arch/xen/x86/x86_xpmap.c:1.54	Sun May 29 17:06:17 2016
+++ src/sys/arch/xen/x86/x86_xpmap.c	Tue Aug  2 13:25:56 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: x86_xpmap.c,v 1.54 2016/05/29 17:06:17 bouyer Exp $	*/
+/*	$NetBSD: x86_xpmap.c,v 1.55 2016/08/02 13:25:56 maxv Exp $	*/
 
 /*
  * Copyright (c) 2006 Mathieu Ropert 
@@ -69,7 +69,7 @@
 
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.54 2016/05/29 17:06:17 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.55 2016/08/02 13:25:56 maxv Exp $");
 
 #include "opt_xen.h"
 #include "opt_ddb.h"
@@ -571,8 +571,8 @@ xpq_debug_dump(void)
 extern volatile struct xencons_interface *xencons_interface; /* XXX */
 extern struct xenstore_domain_interface *xenstore_interface; /* XXX */
 
-static void xen_bt_set_readonly (vaddr_t);
-static void xen_bootstrap_tables (vaddr_t, vaddr_t, int, int, int);
+static void xen_bt_set_readonly(vaddr_t);
+static void xen_bootstrap_tables(vaddr_t, vaddr_t, int, int, int);
 
 /* How many PDEs ? */
 #if L2_SLOT_KERNBASE > 0
@@ -587,7 +587,7 @@ static void xen_bootstrap_tables (vaddr_
  * we get rid of Xen pagetables
  */
 
-vaddr_t xen_pmap_bootstrap (void);
+vaddr_t xen_pmap_bootstrap(void);
 
 /*
  * Function to get rid of Xen bootstrap tables
@@ -616,7 +616,7 @@ xen_pmap_bootstrap(void)
 
 	xen_init_features();
 
-	memset(xpq_idx_array, 0, sizeof xpq_idx_array);
+	memset(xpq_idx_array, 0, sizeof(xpq_idx_array));
 
 	xpmap_phys_to_machine_mapping =
 	(unsigned long *)xen_start_info.mfn_list;
@@ -639,12 +639,12 @@ xen_pmap_bootstrap(void)
 	 *  - early_zerop
 	 *  - ISA I/O mem (if needed)
 	 */
-	mapsize += UPAGES * NBPG;
+	mapsize += UPAGES * PAGE_SIZE;
 #ifdef __x86_64__
-	mapsize += NBPG;
+	mapsize += PAGE_SIZE;
 #endif
-	mapsize += NBPG;
-	mapsize += NBPG;
+	mapsize += PAGE_SIZE;
+	mapsize += PAGE_SIZE;
 
 #ifdef DOM0OPS
 	if (xendomain_is_dom0()) {
@@ -652,7 +652,7 @@ xen_pmap_bootstrap(void)
 		mapsize += IOM_SIZE;
 	}
 #endif
-	/* at this point mapsize doens't include the table size */
+	/* at this point mapsize doesn't include the table size */
 
 #ifdef __x86_64__
 	count = TABLE_L2_ENTRIES;
@@ -709,7 +709,7 @@ bootstrap_again:
 
 	/* zero out free space after tables */
 	memset((void *)(init_tables + ((count + l2_4_count) * PAGE_SIZE)), 0,
-	(UPAGES + 1) * NBPG);
+	(UPAGES + 1) * PAGE_SIZE);
 
 	/* Finally, flush TLB. */
 	xpq_queue_tlb_flush();
@@ -718,14 +718,14 @@ bootstrap_again:
 }
 
 /*
- * Build a new table and switch to it
- * old_count is # of old tables (including PGD, PDTPE and PDE)
- * new_count is # of new tables (PTE only)
- * we assume areas don't overlap
+ * Build a new table and switch to it.
+ * old_count is # of old tables (including PGD, PDTPE and PDE).
+ * new_count is # of new tables (PTE only).
+ * We assume the areas don't overlap.
  */
 static void
-xen_bootstrap_tables (vaddr_t old_pgd, vaddr_t new_pgd,
-	int old_count, int new_count, int final)
+xen_bootstrap_tables(vaddr_t old_pgd, vaddr_t new_pgd,
+int old_count, int new_count, int final)
 {
 	pd_entry_t *pdtpe, *pde, *pte;
 	pd_entry_t *bt_pgd;
@@ -739,26 +739,28 @@ xen_bootstrap_tables (vaddr_t old_pgd, v
 	" %d, %d)\n",
 	old_pgd, new_pgd, old_count, new_count));
 	text_end = ((vaddr_t)&__data_start) & ~PAGE_MASK;
+
 	/*
 	 * size of R/W area after kernel text:
-	 *  xencons_interface (if present)
-	 *  xenstore_interface (if present)
-	 *  table pages (new_count + l2_4_count entries)
+	 * xencons_interface (if present)
+	 * xenstore_interface (if present)
+	 * table pages (new_count + l2_4_count entries)
 	 * extra mappings (only when final is true):
-	 *  UAREA
-	 *  dummy user PGD (x86_64 only)/gdt page (i386 only)
-	 *  HYPERVISOR_shared_info
-	 *  early_zerop
-	 *  ISA I/O mem (if needed)
+	 * UAREA
+	 * dummy user PGD (x86_64 only)/gdt page (i386 only)
+	 * HYPERVISOR_shared_info
+	 * early_zerop
+	 * ISA I/O mem (if needed)
 	 */
-	map_end = new_pgd + ((new_count + l2_4_count) * NBPG);
+	map_end = new_pgd + ((new_count + l2_4_count) * PAGE_SIZE);
 	if (final) {
-		map_end += (UPAGES + 1) * NBPG;
+		map_end += (UPAGES + 1) * PAGE_SIZE;
 		HYPERVISOR_shared_info = (shared_info_t *)map_end;
-		map_end += NBPG;
+		map_end += PAGE_SIZE;
 		early_zerop = (char *)map_end;
-		map_end += NBPG;
+		map_end += PAGE_SIZE;
 	}
+
 	/*
 	 * we always set atdevbase, as it's used by init386 to find the first
 	 * 

CVS commit: src/sys/kern

2016-08-02 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Tue Aug  2 12:23:08 UTC 2016

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

Log Message:
kobj_machdep() needs a chance to moify the loaded code, so move the code
to protect it read-only a bit later.


To generate a diff of this commit:
cvs rdiff -u -r1.58 -r1.59 src/sys/kern/subr_kobj.c

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

Modified files:

Index: src/sys/kern/subr_kobj.c
diff -u src/sys/kern/subr_kobj.c:1.58 src/sys/kern/subr_kobj.c:1.59
--- src/sys/kern/subr_kobj.c:1.58	Mon Aug  1 15:41:05 2016
+++ src/sys/kern/subr_kobj.c	Tue Aug  2 12:23:08 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: subr_kobj.c,v 1.58 2016/08/01 15:41:05 maxv Exp $	*/
+/*	$NetBSD: subr_kobj.c,v 1.59 2016/08/02 12:23:08 martin Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -63,7 +63,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: subr_kobj.c,v 1.58 2016/08/01 15:41:05 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_kobj.c,v 1.59 2016/08/02 12:23:08 martin Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_modular.h"
@@ -757,15 +757,6 @@ kobj_affix(kobj_t ko, const char *name)
 	/* Jettison unneeded memory post-link. */
 	kobj_jettison(ko);
 
-	/* Change the memory protections, when needed. */
-	uvm_km_protect(module_map, ko->ko_text_address, ko->ko_text_size,
-	VM_PROT_READ|VM_PROT_EXECUTE);
-	if (ko->ko_rodata_address != 0) {
-		uvm_km_protect(module_map, ko->ko_rodata_address,
-		ko->ko_rodata_size, VM_PROT_READ);
-	}
-
-
 	/*
 	 * Notify MD code that a module has been loaded.
 	 *
@@ -797,8 +788,16 @@ kobj_affix(kobj_t ko, const char *name)
 		ko->ko_loaded = true;
 	}
 
-	/* If there was an error, destroy the whole object. */
-	if (error != 0) {
+	if (error == 0) {
+		/* Change the memory protections, when needed. */
+		uvm_km_protect(module_map, ko->ko_text_address,
+		 ko->ko_text_size, VM_PROT_READ|VM_PROT_EXECUTE);
+		if (ko->ko_rodata_address != 0) {
+			uvm_km_protect(module_map, ko->ko_rodata_address,
+			ko->ko_rodata_size, VM_PROT_READ);
+		}
+	} else {
+		/* If there was an error, destroy the whole object. */
 		kobj_unload(ko);
 	}
 



CVS commit: src/external/gpl3/binutils

2016-08-02 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Tue Aug  2 08:05:08 UTC 2016

Modified Files:
src/external/gpl3/binutils/lib/libbfd/arch/alpha: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/arm: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/armeb: bfd_stdint.h bfdver.h
config.h
src/external/gpl3/binutils/lib/libbfd/arch/coldfire: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/earmeb: bfd_stdint.h
bfdver.h config.h
src/external/gpl3/binutils/lib/libbfd/arch/earmhf: bfd_stdint.h
bfdver.h config.h
src/external/gpl3/binutils/lib/libbfd/arch/earmhfeb: bfd_stdint.h
bfdver.h config.h
src/external/gpl3/binutils/lib/libbfd/arch/hppa: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/m68000: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/m68k: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/mips64eb: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/mips64el: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/mipsel: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/powerpc: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/powerpc64: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/sh3eb: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/sh3el: bfd_stdint.h
src/external/gpl3/binutils/lib/libbfd/arch/sparc: bfd_stdint.h
src/external/gpl3/binutils/lib/libiberty/arch/mips64eb: config.h
defs.mk
src/external/gpl3/binutils/lib/libiberty/arch/mipseb: config.h defs.mk
src/external/gpl3/binutils/lib/libiberty/arch/sparc: config.h defs.mk
src/external/gpl3/binutils/lib/libopcodes/arch/armeb: config.h
src/external/gpl3/binutils/lib/libopcodes/arch/earmeb: config.h
src/external/gpl3/binutils/lib/libopcodes/arch/earmhf: config.h
src/external/gpl3/binutils/lib/libopcodes/arch/earmhfeb: config.h
src/external/gpl3/binutils/usr.bin/common/arch/armeb: config.h defs.mk
src/external/gpl3/binutils/usr.bin/common/arch/earmeb: config.h defs.mk
src/external/gpl3/binutils/usr.bin/common/arch/earmhf: config.h defs.mk
src/external/gpl3/binutils/usr.bin/common/arch/earmhfeb: config.h
defs.mk
src/external/gpl3/binutils/usr.bin/gas/arch/armeb: config.h
src/external/gpl3/binutils/usr.bin/gas/arch/earmeb: config.h
src/external/gpl3/binutils/usr.bin/gas/arch/earmhf: config.h
src/external/gpl3/binutils/usr.bin/gas/arch/earmhfeb: config.h
src/external/gpl3/binutils/usr.bin/gprof/arch/armeb: gconfig.h
src/external/gpl3/binutils/usr.bin/gprof/arch/earmeb: gconfig.h
src/external/gpl3/binutils/usr.bin/gprof/arch/earmhf: gconfig.h
src/external/gpl3/binutils/usr.bin/gprof/arch/earmhfeb: gconfig.h
src/external/gpl3/binutils/usr.bin/ld/arch/armeb: config.h
src/external/gpl3/binutils/usr.bin/ld/arch/earmeb: config.h
src/external/gpl3/binutils/usr.bin/ld/arch/earmhf: config.h
src/external/gpl3/binutils/usr.bin/ld/arch/earmhfeb: config.h

Log Message:
regen for binutils 2.26.1 and *.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/gpl3/binutils/lib/libbfd/arch/alpha/bfd_stdint.h
cvs rdiff -u -r1.4 -r1.5 \
src/external/gpl3/binutils/lib/libbfd/arch/arm/bfd_stdint.h
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/binutils/lib/libbfd/arch/armeb/bfd_stdint.h
cvs rdiff -u -r1.8 -r1.9 \
src/external/gpl3/binutils/lib/libbfd/arch/armeb/bfdver.h
cvs rdiff -u -r1.4 -r1.5 \
src/external/gpl3/binutils/lib/libbfd/arch/armeb/config.h
cvs rdiff -u -r1.2 -r1.3 \
src/external/gpl3/binutils/lib/libbfd/arch/coldfire/bfd_stdint.h
cvs rdiff -u -r1.2 -r1.3 \
src/external/gpl3/binutils/lib/libbfd/arch/earmeb/bfd_stdint.h
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/binutils/lib/libbfd/arch/earmeb/bfdver.h
cvs rdiff -u -r1.4 -r1.5 \
src/external/gpl3/binutils/lib/libbfd/arch/earmeb/config.h
cvs rdiff -u -r1.2 -r1.3 \
src/external/gpl3/binutils/lib/libbfd/arch/earmhf/bfd_stdint.h
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/binutils/lib/libbfd/arch/earmhf/bfdver.h
cvs rdiff -u -r1.4 -r1.5 \
src/external/gpl3/binutils/lib/libbfd/arch/earmhf/config.h
cvs rdiff -u -r1.2 -r1.3 \
src/external/gpl3/binutils/lib/libbfd/arch/earmhfeb/bfd_stdint.h
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/binutils/lib/libbfd/arch/earmhfeb/bfdver.h \
src/external/gpl3/binutils/lib/libbfd/arch/earmhfeb/config.h
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/binutils/lib/libbfd/arch/hppa/bfd_stdint.h
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/binutils/lib/libbfd/arch/m68000/bfd_stdint.h
cvs rdiff -u -r1.4 -r1.5 \
src/external/gpl3/binutils/lib/libbfd/arch/m68k/bfd_stdint.h
cvs rdiff -u -r1.6 -r1.7 \