CVS commit: src/doc

2012-07-08 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jul  8 08:22:24 UTC 2012

Modified Files:
src/doc: 3RDPARTY

Log Message:
ACPICA 20120620 is out.


To generate a diff of this commit:
cvs rdiff -u -r1.944 -r1.945 src/doc/3RDPARTY

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.944 src/doc/3RDPARTY:1.945
--- src/doc/3RDPARTY:1.944	Mon Jul  2 06:52:20 2012
+++ src/doc/3RDPARTY	Sun Jul  8 08:22:24 2012
@@ -1,4 +1,4 @@
-#	$NetBSD: 3RDPARTY,v 1.944 2012/07/02 06:52:20 wiz Exp $
+#	$NetBSD: 3RDPARTY,v 1.945 2012/07/08 08:22:24 jruoho Exp $
 #
 # This file contains a list of the software that has been integrated into
 # NetBSD where we are not the primary maintainer.
@@ -26,7 +26,7 @@
 
 Package:	acpica
 Version:	20110623
-Current Vers:	20120215
+Current Vers:	20120620
 Maintainer:	Intel
 Archive Site:	http://www.acpica.org/downloads/unix2_source_code.php
 Home Page:	http://www.acpica.org/



CVS commit: src/lib/libc/hash/murmurhash

2012-07-08 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun Jul  8 11:43:47 UTC 2012

Added Files:
src/lib/libc/hash/murmurhash: Makefile.inc

Log Message:
Add Makefile in libc for murmurhash, missed in previous commit.


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/lib/libc/hash/murmurhash/Makefile.inc

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

Added files:

Index: src/lib/libc/hash/murmurhash/Makefile.inc
diff -u /dev/null src/lib/libc/hash/murmurhash/Makefile.inc:1.1
--- /dev/null	Sun Jul  8 11:43:47 2012
+++ src/lib/libc/hash/murmurhash/Makefile.inc	Sun Jul  8 11:43:47 2012
@@ -0,0 +1,5 @@
+# $NetBSD: Makefile.inc,v 1.1 2012/07/08 11:43:47 rmind Exp $
+
+.PATH: ${.CURDIR}/hash/murmurhash
+
+SRCS+=	murmurhash.c



CVS commit: src/doc

2012-07-08 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun Jul  8 12:07:12 UTC 2012

Modified Files:
src/doc: CHANGES

Log Message:
Mention MurmurHash2.


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

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

Modified files:

Index: src/doc/CHANGES
diff -u src/doc/CHANGES:1.1714 src/doc/CHANGES:1.1715
--- src/doc/CHANGES:1.1714	Mon Jul  2 18:16:46 2012
+++ src/doc/CHANGES	Sun Jul  8 12:07:12 2012
@@ -1,4 +1,4 @@
-# LIST OF CHANGES FROM LAST RELEASE:			$Revision: 1.1714 $
+# LIST OF CHANGES FROM LAST RELEASE:			$Revision: 1.1715 $
 #
 #
 # [Note: This file does not mention every change made to the NetBSD source tree.
@@ -77,3 +77,4 @@ Changes from NetBSD 6.0 to NetBSD 7.0:
 		[christos 20120622]
 	ata(4): added support for sata Port MultiPliers (PMP)
 		[bouyer 20120702]
+	kernel, libc: Add MurmurHash2 function. [rmind 20120708]



CVS commit: src/common/lib/libc/hash/murmurhash

2012-07-08 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun Jul  8 13:42:29 UTC 2012

Modified Files:
src/common/lib/libc/hash/murmurhash: murmurhash.c

Log Message:
Shut up lint.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/common/lib/libc/hash/murmurhash/murmurhash.c

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

Modified files:

Index: src/common/lib/libc/hash/murmurhash/murmurhash.c
diff -u src/common/lib/libc/hash/murmurhash/murmurhash.c:1.1 src/common/lib/libc/hash/murmurhash/murmurhash.c:1.2
--- src/common/lib/libc/hash/murmurhash/murmurhash.c:1.1	Sun Jul  8 01:21:12 2012
+++ src/common/lib/libc/hash/murmurhash/murmurhash.c	Sun Jul  8 13:42:29 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: murmurhash.c,v 1.1 2012/07/08 01:21:12 rmind Exp $	*/
+/*	$NetBSD: murmurhash.c,v 1.2 2012/07/08 13:42:29 rmind Exp $	*/
 
 /*
  * MurmurHash2 -- from the original code:
@@ -16,9 +16,9 @@
 #include sys/hash.h
 
 #if defined(_KERNEL) || defined(_STANDALONE)
-__KERNEL_RCSID(0, $NetBSD: murmurhash.c,v 1.1 2012/07/08 01:21:12 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: murmurhash.c,v 1.2 2012/07/08 13:42:29 rmind Exp $);
 #else
-__RCSID($NetBSD: murmurhash.c,v 1.1 2012/07/08 01:21:12 rmind Exp $);
+__RCSID($NetBSD: murmurhash.c,v 1.2 2012/07/08 13:42:29 rmind Exp $);
 #endif
 
 uint32_t
@@ -33,7 +33,7 @@ murmurhash2(const void *key, size_t len,
 	const int r = 24;
 
 	const uint8_t *data = (const uint8_t *)key;
-	uint32_t h = seed ^ len;
+	uint32_t h = seed ^ (uint32_t)len;
 
 	while (len = sizeof(uint32_t)) {
 		uint32_t k;
@@ -58,8 +58,10 @@ murmurhash2(const void *key, size_t len,
 	switch (len) {
 	case 3:
 		h ^= data[2]  16;
+		/* FALLTHROUGH */
 	case 2:
 		h ^= data[1]  8;
+		/* FALLTHROUGH */
 	case 1:
 		h ^= data[0];
 		h *= m;



CVS commit: src/etc/rc.d

2012-07-08 Thread Hans Rosenfeld
Module Name:src
Committed By:   hans
Date:   Sun Jul  8 14:25:49 UTC 2012

Modified Files:
src/etc/rc.d: random_seed

Log Message:
It's msdos, not msdosfs.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/etc/rc.d/random_seed

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

Modified files:

Index: src/etc/rc.d/random_seed
diff -u src/etc/rc.d/random_seed:1.1 src/etc/rc.d/random_seed:1.2
--- src/etc/rc.d/random_seed:1.1	Wed Nov 23 10:47:48 2011
+++ src/etc/rc.d/random_seed	Sun Jul  8 14:25:49 2012
@@ -1,6 +1,6 @@
 #!/bin/sh
 #
-# $NetBSD: random_seed,v 1.1 2011/11/23 10:47:48 tls Exp $
+# $NetBSD: random_seed,v 1.2 2012/07/08 14:25:49 hans Exp $
 #
 
 # PROVIDE: random_seed
@@ -34,7 +34,7 @@ fs_safe()
 	ext2fs)
 		return 0;
 		;;
-	msdosfs)
+	msdos)
 		return 0;
 		;;
 	v7fs)



CVS commit: src/tests/ipf

2012-07-08 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Sun Jul  8 14:45:05 UTC 2012

Modified Files:
src/tests/ipf: t_nat_exec.sh

Log Message:
Restore the rest of the ipfilter test framework, even if most of these
tests are broken.  The golden output files for these tests need to be
updated.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/tests/ipf/t_nat_exec.sh

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

Modified files:

Index: src/tests/ipf/t_nat_exec.sh
diff -u src/tests/ipf/t_nat_exec.sh:1.7 src/tests/ipf/t_nat_exec.sh:1.8
--- src/tests/ipf/t_nat_exec.sh:1.7	Tue Mar 27 09:27:33 2012
+++ src/tests/ipf/t_nat_exec.sh	Sun Jul  8 14:45:05 2012
@@ -1,4 +1,4 @@
-# $NetBSD: t_nat_exec.sh,v 1.7 2012/03/27 09:27:33 jruoho Exp $
+# $NetBSD: t_nat_exec.sh,v 1.8 2012/07/08 14:45:05 pgoyette Exp $
 #
 # Copyright (c) 2008, 2010 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -33,18 +33,24 @@
 nattest()
 {
 	h_copydata $1
+	infmt=$2
+	outfmt=$3
+	shift
+	shift
+	shift
+	args=$@
 
-	if [ $3 = hex ] ; then
-		format=-xF $2
+	if [ $outfmt = hex ] ; then
+		format=-xF $infmt
 	else
-		format=-F $2
+		format=-F $infmt
 	fi
 
-	format=$4 $5 $format
+	format=$format
 
 	{ while read rule; do
 		atf_check -o save:save -x \
-		echo \$rule\ | ipftest $format -RbN - -i in
+		echo \$rule\ | ipftest $format -RbN - -i in $args
 		cat save out
 		echo --- out
 	done; } reg
@@ -52,40 +58,87 @@ nattest()
 	diff -u exp out || atf_fail results differ
 }
 
-#broken_test_case n1 nattest text text
-#broken_test_case n2 nattest text text
+broken_test_case n1 nattest text text
+broken_test_case n2 nattest text text
 broken_test_case n3 nattest text text
-#broken_test_case n4 nattest text text
-#broken_test_case n5 nattest text text
-#broken_test_case n6 nattest text text
+broken_test_case n4 nattest text text
+broken_test_case n5 nattest text text
+broken_test_case n6 nattest text text
 broken_test_case n7 nattest text text
-broken_test_case n8 nattest hex hex -T fr_update_ipid=0
-broken_test_case n9 nattest hex hex -T fr_update_ipid=0
-broken_test_case n10 nattest hex hex -T fr_update_ipid=0
-#broken_test_case n11 nattest text text
-broken_test_case n12 nattest hex hex -T fr_update_ipid=0
+broken_test_case n8 nattest hex hex -T update_ipid=0
+broken_test_case n9 nattest hex hex -T update_ipid=0
+test_case n10 nattest hex hex -T update_ipid=0 -D
+broken_test_case n11 nattest text text
+broken_test_case n12 nattest hex hex -T update_ipid=0 -v
 broken_test_case n13 nattest text text
 broken_test_case n14 nattest text text
+broken_test_case n15 nattest text text -T update_ipid=0
 test_case n16 nattest hex hex -D
 test_case n17 nattest hex hex -D
+broken_test_case n100 nattest text text
+broken_test_case n101 nattest text text
+broken_test_case n102 nattest text text
+broken_test_case n103 nattest text text
+broken_test_case n104 nattest hex hex -T update_ipid=0
+broken_test_case n105 nattest hex hex -T update_ipid=0
+broken_test_case n106 nattest hex hex -T update_ipid=0
+broken_test_case n200 nattest hex hex -T update_ipid=0
+broken_test_case n201 nattest hex hex -T update_ipid=0
+broken_test_case n202 nattest hex hex -T update_ipid=0
+broken_test_case n1_6 nattest text text -6
+broken_test_case n2_6 nattest text text -6
+broken_test_case n4_6 nattest text text -6
+broken_test_case n5_6 nattest text text -6
+broken_test_case n6_6 nattest text text -6
+broken_test_case n7_6 nattest text text -6
+test_case n8_6 nattest hex hex -6D
+test_case n9_6 nattest hex hex -6D
+broken_test_case n11_6 nattest text text -6
+test_case n12_6 nattest hex hex -D6
+broken_test_case n15_6 nattest text text -6
+broken_test_case n17_6 nattest hex hex -6
 
 atf_init_test_cases()
 {
+	atf_add_test_case n1
+	atf_add_test_case n2
 	atf_add_test_case n3
+	atf_add_test_case n4
+	atf_add_test_case n5
+	atf_add_test_case n6
 	atf_add_test_case n7
 	atf_add_test_case n8
 	atf_add_test_case n9
 	atf_add_test_case n10
+	atf_add_test_case n11
 	atf_add_test_case n12
 	atf_add_test_case n13
 	atf_add_test_case n14
 	atf_add_test_case n16
 	atf_add_test_case n17
+	atf_add_test_case n100
+	atf_add_test_case n101
+	atf_add_test_case n102
+	atf_add_test_case n103
+	atf_add_test_case n104
+	atf_add_test_case n105
+	atf_add_test_case n106
+	atf_add_test_case n200
+	atf_add_test_case n201
+	atf_add_test_case n202
+
+	atf_add_test_case n1_6
+	atf_add_test_case n2_6
+#	atf_add_test_case n3_6
+	atf_add_test_case n4_6
+	atf_add_test_case n5_6
+	atf_add_test_case n6_6
+	atf_add_test_case n7_6
+	atf_add_test_case n8_6
+	atf_add_test_case n9_6
+	atf_add_test_case n11_6
+	atf_add_test_case n12_6
+	atf_add_test_case n15_6
+	atf_add_test_case n17_6
 
-	#atf_add_test_case n1
-	#atf_add_test_case n2
-	#atf_add_test_case n4
-	#atf_add_test_case n5
-	#atf_add_test_case n6
-	#atf_add_test_case n11
 }



CVS commit: src/distrib/sets/lists

2012-07-08 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun Jul  8 18:16:03 UTC 2012

Modified Files:
src/distrib/sets/lists/base: ad.mips64eb ad.mips64el md.amd64
md.sparc64 shl.mi
src/distrib/sets/lists/comp: ad.mips64eb ad.mips64el md.amd64
md.sparc64 shl.mi

Log Message:
Fix the lists.


To generate a diff of this commit:
cvs rdiff -u -r1.92 -r1.93 src/distrib/sets/lists/base/ad.mips64eb
cvs rdiff -u -r1.91 -r1.92 src/distrib/sets/lists/base/ad.mips64el
cvs rdiff -u -r1.167 -r1.168 src/distrib/sets/lists/base/md.amd64
cvs rdiff -u -r1.157 -r1.158 src/distrib/sets/lists/base/md.sparc64
cvs rdiff -u -r1.627 -r1.628 src/distrib/sets/lists/base/shl.mi
cvs rdiff -u -r1.79 -r1.80 src/distrib/sets/lists/comp/ad.mips64eb
cvs rdiff -u -r1.80 -r1.81 src/distrib/sets/lists/comp/ad.mips64el
cvs rdiff -u -r1.166 -r1.167 src/distrib/sets/lists/comp/md.amd64
cvs rdiff -u -r1.148 -r1.149 src/distrib/sets/lists/comp/md.sparc64
cvs rdiff -u -r1.224 -r1.225 src/distrib/sets/lists/comp/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/ad.mips64eb
diff -u src/distrib/sets/lists/base/ad.mips64eb:1.92 src/distrib/sets/lists/base/ad.mips64eb:1.93
--- src/distrib/sets/lists/base/ad.mips64eb:1.92	Tue Jun  5 00:37:46 2012
+++ src/distrib/sets/lists/base/ad.mips64eb	Sun Jul  8 18:16:01 2012
@@ -1,4 +1,4 @@
-# $NetBSD: ad.mips64eb,v 1.92 2012/06/05 00:37:46 christos Exp $
+# $NetBSD: ad.mips64eb,v 1.93 2012/07/08 18:16:01 rmind Exp $
 ./libexec/ld.elf_so-64base-compat-shlib	compat,pic
 ./libexec/ld.elf_so-o32base-sysutil-bin	compat,pic
 ./usr/lib/64	base-compat-lib
@@ -68,7 +68,7 @@
 ./usr/lib/64/libbz2.so.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libbz2.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libc.so.12base-compat-shlib	compat,pic
-./usr/lib/64/libc.so.12.183			base-compat-shlib	compat,pic
+./usr/lib/64/libc.so.12.184			base-compat-shlib	compat,pic
 ./usr/lib/64/libcom_err.so.7			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/64/libcom_err.so.7.0			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/64/libcrypt.so.1			base-compat-shlib	compat,pic
@@ -366,7 +366,7 @@
 ./usr/lib/o32/libbz2.so.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libbz2.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libc.so.12			base-compat-shlib	compat,pic
-./usr/lib/o32/libc.so.12.183			base-compat-shlib	compat,pic
+./usr/lib/o32/libc.so.12.184			base-compat-shlib	compat,pic
 ./usr/lib/o32/libcom_err.so.7			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/o32/libcom_err.so.7.0			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/o32/libcrypt.so.1			base-compat-shlib	compat,pic

Index: src/distrib/sets/lists/base/ad.mips64el
diff -u src/distrib/sets/lists/base/ad.mips64el:1.91 src/distrib/sets/lists/base/ad.mips64el:1.92
--- src/distrib/sets/lists/base/ad.mips64el:1.91	Tue Jun  5 00:37:46 2012
+++ src/distrib/sets/lists/base/ad.mips64el	Sun Jul  8 18:16:01 2012
@@ -1,4 +1,4 @@
-# $NetBSD: ad.mips64el,v 1.91 2012/06/05 00:37:46 christos Exp $
+# $NetBSD: ad.mips64el,v 1.92 2012/07/08 18:16:01 rmind Exp $
 ./libexec/ld.elf_so-64base-compat-shlib	compat,pic
 ./libexec/ld.elf_so-o32base-sysutil-bin	compat,pic
 ./usr/lib/64	base-compat-lib
@@ -66,7 +66,7 @@
 ./usr/lib/64/libbz2.so.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libbz2.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libc.so.12base-compat-shlib	compat,pic
-./usr/lib/64/libc.so.12.183			base-compat-shlib	compat,pic
+./usr/lib/64/libc.so.12.184			base-compat-shlib	compat,pic
 ./usr/lib/64/libcom_err.so.7			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/64/libcom_err.so.7.0			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/64/libcrypt.so.1			base-compat-shlib	compat,pic
@@ -366,7 +366,7 @@
 ./usr/lib/o32/libbz2.so.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libbz2.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libc.so.12			base-compat-shlib	compat,pic
-./usr/lib/o32/libc.so.12.183			base-compat-shlib	compat,pic
+./usr/lib/o32/libc.so.12.184			base-compat-shlib	compat,pic
 ./usr/lib/o32/libcom_err.so.7			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/o32/libcom_err.so.7.0			base-compat-shlib	compat,pic,kerberos
 ./usr/lib/o32/libcrypt.so.1			base-compat-shlib	compat,pic

Index: src/distrib/sets/lists/base/md.amd64
diff -u src/distrib/sets/lists/base/md.amd64:1.167 src/distrib/sets/lists/base/md.amd64:1.168
--- src/distrib/sets/lists/base/md.amd64:1.167	Tue Jun  5 00:37:49 2012
+++ src/distrib/sets/lists/base/md.amd64	Sun Jul  8 18:16:01 2012
@@ -1,4 +1,4 @@
-# $NetBSD: md.amd64,v 1.167 2012/06/05 00:37:49 christos Exp $
+# $NetBSD: md.amd64,v 1.168 2012/07/08 18:16:01 rmind Exp $
 ./dev/lms0	base-obsolete		obsolete
 ./dev/mms0	base-obsolete		obsolete
 ./libexec/ld.elf_so-i386			base-sys-shlib		compat,pic
@@ -69,7 +69,7 @@
 ./usr/lib/i386/libbz2.so.1			

CVS commit: src/sys

2012-07-08 Thread David Laight
Module Name:src
Committed By:   dsl
Date:   Sun Jul  8 20:14:12 UTC 2012

Modified Files:
src/sys/arch/amd64/amd64: fpu.c machdep.c netbsd32_machdep.c
process_machdep.c
src/sys/arch/amd64/include: proc.h
src/sys/arch/sh3/include: proc.h userret.h
src/sys/arch/sh3/sh3: exception.c process_machdep.c sh3_machdep.c
src/sys/compat/linux/arch/amd64: linux_machdep.c
src/sys/compat/linux32/arch/amd64: linux32_machdep.c

Log Message:
The MDP_USEDFPU (amd64 and sh3) and MDP_SSTEP (sh3) are lwp flags not
process ones, rename to MDL_xxx.


To generate a diff of this commit:
cvs rdiff -u -r1.38 -r1.39 src/sys/arch/amd64/amd64/fpu.c
cvs rdiff -u -r1.187 -r1.188 src/sys/arch/amd64/amd64/machdep.c
cvs rdiff -u -r1.77 -r1.78 src/sys/arch/amd64/amd64/netbsd32_machdep.c
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/amd64/amd64/process_machdep.c
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/amd64/include/proc.h
cvs rdiff -u -r1.16 -r1.17 src/sys/arch/sh3/include/proc.h
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/sh3/include/userret.h
cvs rdiff -u -r1.62 -r1.63 src/sys/arch/sh3/sh3/exception.c
cvs rdiff -u -r1.19 -r1.20 src/sys/arch/sh3/sh3/process_machdep.c
cvs rdiff -u -r1.99 -r1.100 src/sys/arch/sh3/sh3/sh3_machdep.c
cvs rdiff -u -r1.39 -r1.40 src/sys/compat/linux/arch/amd64/linux_machdep.c
cvs rdiff -u -r1.29 -r1.30 \
src/sys/compat/linux32/arch/amd64/linux32_machdep.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/amd64/amd64/fpu.c
diff -u src/sys/arch/amd64/amd64/fpu.c:1.38 src/sys/arch/amd64/amd64/fpu.c:1.39
--- src/sys/arch/amd64/amd64/fpu.c:1.38	Thu Aug 11 18:36:14 2011
+++ src/sys/arch/amd64/amd64/fpu.c	Sun Jul  8 20:14:11 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: fpu.c,v 1.38 2011/08/11 18:36:14 cherry Exp $	*/
+/*	$NetBSD: fpu.c,v 1.39 2012/07/08 20:14:11 dsl Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.  All
@@ -100,7 +100,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: fpu.c,v 1.38 2011/08/11 18:36:14 cherry Exp $);
+__KERNEL_RCSID(0, $NetBSD: fpu.c,v 1.39 2012/07/08 20:14:11 dsl Exp $);
 
 #include opt_multiprocessor.h
 
@@ -137,17 +137,17 @@ __KERNEL_RCSID(0, $NetBSD: fpu.c,v 1.38
 
 /*
  * We do lazy initialization and switching using the TS bit in cr0 and the
- * MDP_USEDFPU bit in mdproc.
+ * MDL_USEDFPU bit in mdlwp.
  *
  * DNA exceptions are handled like this:
  *
  * 1) If there is no FPU, return and go to the emulator.
  * 2) If someone else has used the FPU, save its state into that lwp's PCB.
- * 3a) If MDP_USEDFPU is not set, set it and initialize the FPU.
+ * 3a) If MDL_USEDFPU is not set, set it and initialize the FPU.
  * 3b) Otherwise, reload the lwp's previous FPU state.
  *
  * When a lwp is created or exec()s, its saved cr0 image has the TS bit
- * set and the MDP_USEDFPU bit clear.  The MDP_USEDFPU bit is set when the
+ * set and the MDL_USEDFPU bit clear.  The MDL_USEDFPU bit is set when the
  * lwp first gets a DNA and the FPU is initialized.  The TS bit is turned
  * off when the FPU is used, and turned on again later when the lwp's FPU
  * state is saved.
@@ -305,13 +305,13 @@ fpudna(struct cpu_info *ci)
 	clts();
 	ci-ci_fpcurlwp = l;
 	pcb-pcb_fpcpu = ci;
-	if ((l-l_md.md_flags  MDP_USEDFPU) == 0) {
+	if ((l-l_md.md_flags  MDL_USEDFPU) == 0) {
 		fninit();
 		cw = pcb-pcb_savefpu.fp_fxsave.fx_fcw;
 		fldcw(cw);
 		mxcsr = pcb-pcb_savefpu.fp_fxsave.fx_mxcsr;
 		x86_ldmxcsr(mxcsr);
-		l-l_md.md_flags |= MDP_USEDFPU;
+		l-l_md.md_flags |= MDL_USEDFPU;
 	} else {
 		/*
 		 * AMD FPU's do not restore FIP, FDP, and FOP on fxrstor,
@@ -426,6 +426,6 @@ fpusave_lwp(struct lwp *l, bool save)
 
 	if (!save) {
 		/* Ensure we restart with a clean slate. */
-	 	l-l_md.md_flags = ~MDP_USEDFPU;
+	 	l-l_md.md_flags = ~MDL_USEDFPU;
 	}
 }

Index: src/sys/arch/amd64/amd64/machdep.c
diff -u src/sys/arch/amd64/amd64/machdep.c:1.187 src/sys/arch/amd64/amd64/machdep.c:1.188
--- src/sys/arch/amd64/amd64/machdep.c:1.187	Wed Jun 27 00:37:07 2012
+++ src/sys/arch/amd64/amd64/machdep.c	Sun Jul  8 20:14:11 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: machdep.c,v 1.187 2012/06/27 00:37:07 jym Exp $	*/
+/*	$NetBSD: machdep.c,v 1.188 2012/07/08 20:14:11 dsl Exp $	*/
 
 /*-
  * Copyright (c) 1996, 1997, 1998, 2000, 2006, 2007, 2008, 2011
@@ -111,7 +111,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.187 2012/06/27 00:37:07 jym Exp $);
+__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.188 2012/07/08 20:14:11 dsl Exp $);
 
 /* #define XENDEBUG_LOW  */
 
@@ -627,7 +627,7 @@ buildcontext(struct lwp *l, void *catche
 	tf-tf_ss = GSEL(GUDATA_SEL, SEL_UPL);
 
 	/* Ensure FP state is reset, if FP is used. */
-	l-l_md.md_flags = ~MDP_USEDFPU;
+	l-l_md.md_flags = ~MDL_USEDFPU;
 }
 
 void
@@ -674,7 +674,7 @@ sendsig_siginfo(const ksiginfo_t *ksi, c
 	/*
 	 * Don't bother copying out FP state if there is none.
 	 */
-	if 

CVS commit: src/share/man/man4

2012-07-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sun Jul  8 22:47:42 UTC 2012

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

Log Message:
From Bug Hunting:
improve wording, macro usage, and punctuation.

While here, remove an unnecessary comma and sort SEE ALSO.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/share/man/man4/vnd.4

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

Modified files:

Index: src/share/man/man4/vnd.4
diff -u src/share/man/man4/vnd.4:1.17 src/share/man/man4/vnd.4:1.18
--- src/share/man/man4/vnd.4:1.17	Fri Dec 18 23:37:38 2009
+++ src/share/man/man4/vnd.4	Sun Jul  8 22:47:41 2012
@@ -1,4 +1,4 @@
-.\	$NetBSD: vnd.4,v 1.17 2009/12/18 23:37:38 dyoung Exp $
+.\	$NetBSD: vnd.4,v 1.18 2012/07/08 22:47:41 wiz Exp $
 .\
 .\ Copyright (c) 1996, 1997 The NetBSD Foundation, Inc.
 .\ All rights reserved.
@@ -43,11 +43,13 @@ driver provides a disk-like interface to
 This is useful for a variety of applications, including swap files
 and building miniroot or floppy disk images.
 .Pp
-This document assumes that you're familiar with how to generate kernels,
-how to properly configure disks and pseudo-devices in a kernel
+This document assumes that you're familiar with how to generate kernels
+and how to properly configure disks and pseudo-devices in a kernel
 configuration file.
 .Pp
-In order to compile in support for the vnd, you must add a line similar
+In order to compile in support for the
+.Nm ,
+you must add a line similar
 to the following to your kernel configuration file:
 .Bd -unfilled -offset indent
 pseudo-device	vnd		# vnode disk driver
@@ -59,15 +61,17 @@ add the following option to your kernel 
 optionsVND_COMPRESSION# compressed vnd(4)
 .Ed
 .Pp
-Compressed disk images are expected in the cloop2 format,
-they can be created from normal disk images by the
+Compressed disk images are expected in the cloop2 format.
+They can be created from
+.Dq normal
+disk images by the
 .Xr vndcompress 1
 program.
 .Pp
 There is a run-time utility that is used for configuring
 both compressed and uncompressed
-.Nm vnd Ns s .
-See
+.Nm vnd Ns s ;
+see
 .Xr vnconfig 8
 for more information.
 .Sh FILES
@@ -78,8 +82,8 @@ vnd device special files.
 .Sh SEE ALSO
 .Xr config 1 ,
 .Xr vndcompress 1 ,
-.Xr MAKEDEV 8 ,
 .Xr fsck 8 ,
+.Xr MAKEDEV 8 ,
 .Xr mount 8 ,
 .Xr newfs 8 ,
 .Xr vnconfig 8



CVS commit: src/usr.bin/vndcompress

2012-07-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sun Jul  8 22:48:32 UTC 2012

Modified Files:
src/usr.bin/vndcompress: vndcompress.1

Log Message:
Improve wording, fix typo, bump date.
From Bug Hunting.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/usr.bin/vndcompress/vndcompress.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/vndcompress/vndcompress.1
diff -u src/usr.bin/vndcompress/vndcompress.1:1.6 src/usr.bin/vndcompress/vndcompress.1:1.7
--- src/usr.bin/vndcompress/vndcompress.1:1.6	Sat Mar 24 23:16:11 2007
+++ src/usr.bin/vndcompress/vndcompress.1	Sun Jul  8 22:48:32 2012
@@ -1,4 +1,4 @@
-.\	$NetBSD: vndcompress.1,v 1.6 2007/03/24 23:16:11 dillo Exp $
+.\	$NetBSD: vndcompress.1,v 1.7 2012/07/08 22:48:32 wiz Exp $
 .\
 .\ Copyright (c) 2005 Florian Stoehr net...@wolfnode.de
 .\ All rights reserved.
@@ -30,7 +30,7 @@
 .\ SUCH DAMAGE.
 .\
 .\
-.Dd December 12, 2005
+.Dd July 8, 2012
 .Dt VNDCOMPRESS 1
 .Os
 .Sh NAME
@@ -57,7 +57,7 @@ If omitted, the default of 64kB is used.
 .Pp
 The
 .Nm vnduncompress
-command decompress a cloop2-compressed file system image back into a
+command decompress a cloop2 compressed file system image back into a
 regular image.
 .Pp
 The
@@ -141,7 +141,7 @@ was compiled with
 .Dv VND_COMPRESSION ,
 you can use
 .Xr vnconfig 8
-to access the cloop-compressed image directly, e.g.,
+to access the cloop2 compressed image directly, e.g.,
 .Bd -literal -offset indent
 # vnconfig vnd0 KNOPPIX.iso
 # mount -t cd9660 -o ro /dev/vnd0d /mnt



CVS commit: src/usr.sbin/vnconfig

2012-07-08 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Sun Jul  8 22:49:56 UTC 2012

Modified Files:
src/usr.sbin/vnconfig: vnconfig.8

Log Message:
From Bug Hunting: Add vndcompress(1) to SEE ALSO, bump date.

While here:
New sentence, new line.


To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/usr.sbin/vnconfig/vnconfig.8

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

Modified files:

Index: src/usr.sbin/vnconfig/vnconfig.8
diff -u src/usr.sbin/vnconfig/vnconfig.8:1.36 src/usr.sbin/vnconfig/vnconfig.8:1.37
--- src/usr.sbin/vnconfig/vnconfig.8:1.36	Wed Feb  9 10:25:40 2011
+++ src/usr.sbin/vnconfig/vnconfig.8	Sun Jul  8 22:49:55 2012
@@ -1,4 +1,4 @@
-.\	$NetBSD: vnconfig.8,v 1.36 2011/02/09 10:25:40 rmind Exp $
+.\	$NetBSD: vnconfig.8,v 1.37 2012/07/08 22:49:55 wiz Exp $
 .\
 .\ Copyright (c) 1997 The NetBSD Foundation, Inc.
 .\ All rights reserved.
@@ -61,7 +61,7 @@
 .\
 .\	@(#)vnconfig.8	8.1 (Berkeley) 6/5/93
 .\
-.Dd July 16, 2005
+.Dd July 9, 2012
 .Dt VNCONFIG 8
 .Os
 .Sh NAME
@@ -123,7 +123,8 @@ argument is:
 If geometry is not specified, the kernel will choose a default based on 1MB
 cylinders.
 .Ar secsize
-is the number of bytes per sector.  It must be an even multiple of 512.
+is the number of bytes per sector.
+It must be an even multiple of 512.
 .Ar nsectors
 is the number of sectors per track.
 .Ar ntracks
@@ -142,7 +143,8 @@ option should look up in
 instead of in
 .Pa /etc/disktab .
 .It Fl l
-List the vnd devices and indicate which ones are in use.  If a specific
+List the vnd devices and indicate which ones are in use.
+If a specific
 .Ar vnode_disk
 is given, then only that will be described.
 .It Fl t Ar typename
@@ -150,7 +152,8 @@ If configuring the device, look up
 .Ar typename
 in
 .Pa /etc/disktab
-and use the geometry specified in the entry.  This option and the
+and use the geometry specified in the entry.
+This option and the
 .Ar geomspec
 argument are mutually exclusive.
 .It Fl r
@@ -210,6 +213,7 @@ Unconfigures the
 .Pa vnd0
 device.
 .Sh SEE ALSO
+.Xr vndcompress 1 ,
 .Xr opendisk 3 ,
 .Xr vnd 4 ,
 .Xr mount 8 ,



CVS commit: src/usr.sbin/makemandb

2012-07-08 Thread Valeriy E. Ushakov
Module Name:src
Committed By:   uwe
Date:   Sun Jul  8 23:18:23 UTC 2012

Modified Files:
src/usr.sbin/makemandb: makemandb.c

Log Message:
Fix typo in a message.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/usr.sbin/makemandb/makemandb.c

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

Modified files:

Index: src/usr.sbin/makemandb/makemandb.c
diff -u src/usr.sbin/makemandb/makemandb.c:1.9 src/usr.sbin/makemandb/makemandb.c:1.10
--- src/usr.sbin/makemandb/makemandb.c:1.9	Mon May  7 11:18:16 2012
+++ src/usr.sbin/makemandb/makemandb.c	Sun Jul  8 23:18:23 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: makemandb.c,v 1.9 2012/05/07 11:18:16 wiz Exp $	*/
+/*	$NetBSD: makemandb.c,v 1.10 2012/07/08 23:18:23 uwe Exp $	*/
 /*
  * Copyright (c) 2011 Abhinav Upadhyay er.abhinav.upadh...@gmail.com
  * Copyright (c) 2011 Kristaps Dzonsons krist...@bsd.lv
@@ -17,7 +17,7 @@
  */
 
 #include sys/cdefs.h
-__RCSID($NetBSD: makemandb.c,v 1.9 2012/05/07 11:18:16 wiz Exp $);
+__RCSID($NetBSD: makemandb.c,v 1.10 2012/07/08 23:18:23 uwe Exp $);
 
 #include sys/stat.h
 #include sys/types.h
@@ -763,7 +763,7 @@ update_db(sqlite3 *db, struct mparse *mp
 	sqlite3_finalize(stmt);
 	
 	if (mflags.verbosity) {
-		printf(Total Number of new or updated pages enountered = %d\n
+		printf(Total Number of new or updated pages encountered = %d\n
 			Total number of pages that were successfully
 			 indexed/updated = %d\n
 			Total number of (hard or symbolic) links found = %d\n



CVS commit: src/lib/libexecinfo

2012-07-08 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Mon Jul  9 03:11:59 UTC 2012

Modified Files:
src/lib/libexecinfo: backtrace.c

Log Message:
fix cleanup on error


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/lib/libexecinfo/backtrace.c

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

Modified files:

Index: src/lib/libexecinfo/backtrace.c
diff -u src/lib/libexecinfo/backtrace.c:1.1 src/lib/libexecinfo/backtrace.c:1.2
--- src/lib/libexecinfo/backtrace.c:1.1	Sat May 26 18:02:29 2012
+++ src/lib/libexecinfo/backtrace.c	Sun Jul  8 23:11:59 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: backtrace.c,v 1.1 2012/05/26 22:02:29 christos Exp $	*/
+/*	$NetBSD: backtrace.c,v 1.2 2012/07/09 03:11:59 christos Exp $	*/
 
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include sys/cdefs.h
-__RCSID($NetBSD: backtrace.c,v 1.1 2012/05/26 22:02:29 christos Exp $);
+__RCSID($NetBSD: backtrace.c,v 1.2 2012/07/09 03:11:59 christos Exp $);
 
 #include sys/param.h
 #include assert.h
@@ -168,7 +168,7 @@ backtrace_symbols_fmt(void *const *trace
 		st = NULL;
 
 	if ((ptr = calloc(len, slen)) == NULL)
-		return NULL;
+		goto out;
 
 	size_t psize = len * slen;
 	size_t offs = len * sizeof(char *);
@@ -180,7 +180,8 @@ backtrace_symbols_fmt(void *const *trace
 		x = format_address(st, ptr, psize, offs, fmt, trace[i]);
 		if (x == -1) {
 			free(ptr);
-			return NULL;
+			ptr = NULL;
+			goto out;
 		}
 		offs += x;
 		ptr[offs++] = '\0';
@@ -191,6 +192,7 @@ backtrace_symbols_fmt(void *const *trace
 	for (size_t j = 0; j  len; j++)
 		((char **)(void *)ptr)[j] += (intptr_t)ptr;
 
+out:
 	symtab_destroy(st);
 	if (fd != -1)
 		(void)close(fd);



CVS commit: src/sys/kern

2012-07-08 Thread Chuck Silvers
Module Name:src
Committed By:   chs
Date:   Mon Jul  9 04:35:14 UTC 2012

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

Log Message:
in soreceive(), handle uios larger than 31 bits.
fixes the remaining problem in PR 43240.


To generate a diff of this commit:
cvs rdiff -u -r1.210 -r1.211 src/sys/kern/uipc_socket.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/uipc_socket.c
diff -u src/sys/kern/uipc_socket.c:1.210 src/sys/kern/uipc_socket.c:1.211
--- src/sys/kern/uipc_socket.c:1.210	Fri Mar 16 06:47:37 2012
+++ src/sys/kern/uipc_socket.c	Mon Jul  9 04:35:13 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: uipc_socket.c,v 1.210 2012/03/16 06:47:37 matt Exp $	*/
+/*	$NetBSD: uipc_socket.c,v 1.211 2012/07/09 04:35:13 chs Exp $	*/
 
 /*-
  * Copyright (c) 2002, 2007, 2008, 2009 The NetBSD Foundation, Inc.
@@ -63,7 +63,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: uipc_socket.c,v 1.210 2012/03/16 06:47:37 matt Exp $);
+__KERNEL_RCSID(0, $NetBSD: uipc_socket.c,v 1.211 2012/07/09 04:35:13 chs Exp $);
 
 #include opt_compat_netbsd.h
 #include opt_sock_counters.h
@@ -1132,7 +1132,8 @@ soreceive(struct socket *so, struct mbuf
 {
 	struct lwp *l = curlwp;
 	struct mbuf	*m, **mp, *mt;
-	int atomic, flags, len, error, s, offset, moff, type, orig_resid;
+	size_t len, offset, moff, orig_resid;
+	int atomic, flags, error, s, type;
 	const struct protosw	*pr;
 	struct mbuf	*nextrecord;
 	int		mbuf_removed = 0;
@@ -1165,7 +1166,7 @@ soreceive(struct socket *so, struct mbuf
 			goto bad;
 		do {
 			error = uiomove(mtod(m, void *),
-			(int) min(uio-uio_resid, m-m_len), uio);
+			MIN(uio-uio_resid, m-m_len), uio);
 			m = m_free(m);
 		} while (uio-uio_resid  0  error == 0  m);
  bad:
@@ -1419,7 +1420,7 @@ soreceive(struct socket *so, struct mbuf
 			SBLASTMBUFCHK(so-so_rcv, soreceive uiomove);
 			sounlock(so);
 			splx(s);
-			error = uiomove(mtod(m, char *) + moff, (int)len, uio);
+			error = uiomove(mtod(m, char *) + moff, len, uio);
 			s = splsoftnet();
 			solock(so);
 			if (error != 0) {