CVS commit: src/external/gpl2/lvm2/sbin/lvm

2014-01-14 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Jan 14 20:22:35 UTC 2014

Modified Files:
src/external/gpl2/lvm2/sbin/lvm: Makefile

Log Message:
USE_SSP is not defined in bsd.sys.mk


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/external/gpl2/lvm2/sbin/lvm/Makefile

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

Modified files:

Index: src/external/gpl2/lvm2/sbin/lvm/Makefile
diff -u src/external/gpl2/lvm2/sbin/lvm/Makefile:1.11 src/external/gpl2/lvm2/sbin/lvm/Makefile:1.12
--- src/external/gpl2/lvm2/sbin/lvm/Makefile:1.11	Wed May  2 09:35:04 2012
+++ src/external/gpl2/lvm2/sbin/lvm/Makefile	Tue Jan 14 15:22:35 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.11 2012/05/02 13:35:04 cheusov Exp $
+#	$NetBSD: Makefile,v 1.12 2014/01/14 20:22:35 christos Exp $
 
 USE_FORT?=	no
 NOLINT=		#defined
@@ -31,7 +31,6 @@ CPPFLAGS+=	-I${LVM2_DISTDIR}/lib -I${LVM
 CPPFLAGS+=	-DLVM_SHARED_PATH=\"$(BINDIR)/lvm\"
 
 .include 
-.include  # for USE_SSP
 
 # Some parts of the code can't be protected because if its
 # alloca() usage.



CVS commit: src/external/gpl2/lvm2/lib/liblvm

2014-01-14 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Jan 14 19:58:19 UTC 2014

Modified Files:
src/external/gpl2/lvm2/lib/liblvm: Makefile

Log Message:
USE_SSP is defined in bsd.own.mk


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/external/gpl2/lvm2/lib/liblvm/Makefile

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

Modified files:

Index: src/external/gpl2/lvm2/lib/liblvm/Makefile
diff -u src/external/gpl2/lvm2/lib/liblvm/Makefile:1.6 src/external/gpl2/lvm2/lib/liblvm/Makefile:1.7
--- src/external/gpl2/lvm2/lib/liblvm/Makefile:1.6	Wed May  2 09:35:03 2012
+++ src/external/gpl2/lvm2/lib/liblvm/Makefile	Tue Jan 14 14:58:19 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.6 2012/05/02 13:35:03 cheusov Exp $
+#	$NetBSD: Makefile,v 1.7 2014/01/14 19:58:19 christos Exp $
 
 LIBISPRIVATE=	yes
 
@@ -15,7 +15,6 @@ CPPFLAGS+=	-I${LVM2_DISTDIR}/lib -I${LVM
 		-I. 
 
 .include 
-.include  # for USE_SSP
 
 # Some parts of liblvm can't be protected because if its
 # alloca() usage.



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

2014-01-14 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Jan 14 18:52:19 UTC 2014

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

Log Message:
new bsd.syscall.mk


To generate a diff of this commit:
cvs rdiff -u -r1.1057 -r1.1058 src/distrib/sets/lists/base/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/mi
diff -u src/distrib/sets/lists/base/mi:1.1057 src/distrib/sets/lists/base/mi:1.1058
--- src/distrib/sets/lists/base/mi:1.1057	Sun Jan  5 11:38:05 2014
+++ src/distrib/sets/lists/base/mi	Tue Jan 14 13:52:19 2014
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.1057 2014/01/05 16:38:05 joerg Exp $
+# $NetBSD: mi,v 1.1058 2014/01/14 18:52:19 christos Exp $
 #
 # Note:	Don't delete entries from here - mark them as "obsolete" instead,
 #	unless otherwise stated below.
@@ -4337,6 +4337,7 @@
 ./usr/share/mk/bsd.shlib.mk			base-mk-share		share
 ./usr/share/mk/bsd.subdir.mk			base-mk-share		share
 ./usr/share/mk/bsd.sys.mk			base-mk-share		share
+./usr/share/mk/bsd.syscall.mk			base-mk-share		share
 ./usr/share/mk/bsd.test.mk			base-mk-share		share
 ./usr/share/mk/bsd.x11.mk			base-mk-share		share
 ./usr/share/mk/sys.mkbase-mk-share		share



CVS commit: src/sys/compat

2014-01-14 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Jan 14 18:51:25 UTC 2014

Modified Files:
src/sys/compat/aoutm68k: Makefile
src/sys/compat/freebsd: Makefile
src/sys/compat/ibcs2: Makefile
src/sys/compat/linux: Makefile.inc
src/sys/compat/linux32: Makefile.inc
src/sys/compat/netbsd32: Makefile
src/sys/compat/osf1: Makefile
src/sys/compat/sunos: Makefile
src/sys/compat/sunos32: Makefile
src/sys/compat/svr4: Makefile
src/sys/compat/svr4_32: Makefile
src/sys/compat/ultrix: Makefile

Log Message:
use new bsd.syscall.mk


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/compat/aoutm68k/Makefile
cvs rdiff -u -r1.7 -r1.8 src/sys/compat/freebsd/Makefile
cvs rdiff -u -r1.5 -r1.6 src/sys/compat/ibcs2/Makefile
cvs rdiff -u -r1.5 -r1.6 src/sys/compat/linux/Makefile.inc
cvs rdiff -u -r1.2 -r1.3 src/sys/compat/linux32/Makefile.inc
cvs rdiff -u -r1.7 -r1.8 src/sys/compat/netbsd32/Makefile
cvs rdiff -u -r1.6 -r1.7 src/sys/compat/osf1/Makefile
cvs rdiff -u -r1.5 -r1.6 src/sys/compat/sunos/Makefile
cvs rdiff -u -r1.5 -r1.6 src/sys/compat/sunos32/Makefile
cvs rdiff -u -r1.5 -r1.6 src/sys/compat/svr4/Makefile
cvs rdiff -u -r1.6 -r1.7 src/sys/compat/svr4_32/Makefile
cvs rdiff -u -r1.5 -r1.6 src/sys/compat/ultrix/Makefile

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/aoutm68k/Makefile
diff -u src/sys/compat/aoutm68k/Makefile:1.6 src/sys/compat/aoutm68k/Makefile:1.7
--- src/sys/compat/aoutm68k/Makefile:1.6	Thu May  4 18:27:51 2006
+++ src/sys/compat/aoutm68k/Makefile	Tue Jan 14 13:51:24 2014
@@ -1,14 +1,5 @@
-#	$NetBSD: Makefile,v 1.6 2006/05/04 22:27:51 tsutsui Exp $
+#	$NetBSD: Makefile,v 1.7 2014/01/14 18:51:24 christos Exp $
 
-.include 		# for HOST_SH
+SYSCALL_PREFIX=aoutm68k
 
-DEP=	syscalls.conf syscalls.master ../../kern/makesyscalls.sh
-OBJS=	aoutm68k_sysent.c aoutm68k_syscalls.c \
-	aoutm68k_syscall.h aoutm68k_syscallargs.h
-
-${OBJS}: ${DEP}
-	${HOST_SH} ../../kern/makesyscalls.sh syscalls.conf syscalls.master
-
-all: ${OBJS}
-
-.include 
+.include 

Index: src/sys/compat/freebsd/Makefile
diff -u src/sys/compat/freebsd/Makefile:1.7 src/sys/compat/freebsd/Makefile:1.8
--- src/sys/compat/freebsd/Makefile:1.7	Sun Dec 11 07:20:02 2005
+++ src/sys/compat/freebsd/Makefile	Tue Jan 14 13:51:24 2014
@@ -1,14 +1,5 @@
-#	$NetBSD: Makefile,v 1.7 2005/12/11 12:20:02 christos Exp $
+#	$NetBSD: Makefile,v 1.8 2014/01/14 18:51:24 christos Exp $
 
-.include 		# for HOST_SH
+SYSCALL_PREFIX=freebsd
 
-DEP=	syscalls.conf syscalls.master ../../kern/makesyscalls.sh
-OBJS=	freebsd_sysent.c freebsd_syscalls.c \
-	freebsd_syscall.h freebsd_syscallargs.h
-
-${OBJS}: ${DEP}
-	${HOST_SH} ../../kern/makesyscalls.sh syscalls.conf syscalls.master
-
-all: ${OBJS}
-
-.include 
+.include 

Index: src/sys/compat/ibcs2/Makefile
diff -u src/sys/compat/ibcs2/Makefile:1.5 src/sys/compat/ibcs2/Makefile:1.6
--- src/sys/compat/ibcs2/Makefile:1.5	Sun Dec 11 07:20:02 2005
+++ src/sys/compat/ibcs2/Makefile	Tue Jan 14 13:51:25 2014
@@ -1,13 +1,5 @@
-#	$NetBSD: Makefile,v 1.5 2005/12/11 12:20:02 christos Exp $
+#	$NetBSD: Makefile,v 1.6 2014/01/14 18:51:25 christos Exp $
 
-.include 		# for HOST_SH
+SYSCALL_PREFIX=ibcs2
 
-DEP=	syscalls.conf syscalls.master ../../kern/makesyscalls.sh
-OBJS=	ibcs2_sysent.c ibcs2_syscalls.c ibcs2_syscall.h ibcs2_syscallargs.h
-
-${OBJS}: ${DEP}
-	${HOST_SH} ../../kern/makesyscalls.sh syscalls.conf syscalls.master
-
-all: ${OBJS}
-
-.include 
+.include 

Index: src/sys/compat/linux/Makefile.inc
diff -u src/sys/compat/linux/Makefile.inc:1.5 src/sys/compat/linux/Makefile.inc:1.6
--- src/sys/compat/linux/Makefile.inc:1.5	Sun Dec 11 07:20:12 2005
+++ src/sys/compat/linux/Makefile.inc	Tue Jan 14 13:51:25 2014
@@ -1,11 +1,5 @@
-#	$NetBSD: Makefile.inc,v 1.5 2005/12/11 12:20:12 christos Exp $
+#	$NetBSD: Makefile.inc,v 1.6 2014/01/14 18:51:25 christos Exp $
 
-.include 		# for HOST_SH
+SYSCALL_PREFIX=linux
 
-DEP=	syscalls.conf syscalls.master ../../../../kern/makesyscalls.sh
-OBJS=	linux_sysent.c linux_syscalls.c linux_syscall.h linux_syscallargs.h
-
-${OBJS}: ${DEP}
-	${HOST_SH} ../../../../kern/makesyscalls.sh syscalls.conf syscalls.master
-
-all: ${OBJS}
+.include 

Index: src/sys/compat/linux32/Makefile.inc
diff -u src/sys/compat/linux32/Makefile.inc:1.2 src/sys/compat/linux32/Makefile.inc:1.3
--- src/sys/compat/linux32/Makefile.inc:1.2	Fri Mar 23 08:26:10 2007
+++ src/sys/compat/linux32/Makefile.inc	Tue Jan 14 13:51:25 2014
@@ -1,11 +1,5 @@
-#	$NetBSD: Makefile.inc,v 1.2 2007/03/23 12:26:10 njoly Exp $
+#	$NetBSD: Makefile.inc,v 1.3 2014/01/14 18:51:25 christos Exp $
 
-.include 		# for HOST_SH
+SYSCALL_PREFIX=linux32
 
-DEP=	syscalls.conf syscalls.master ../../../../kern/makesyscalls.sh
-OBJS=	linux32_sysent.c linux32_syscalls.c linux32_syscall.h linux32_syscallargs.h
-
-${OBJS}: ${DEP}
-	${HOST_SH} .

CVS commit: src/share/mk

2014-01-14 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Jan 14 18:51:45 UTC 2014

Modified Files:
src/share/mk: Makefile bsd.README
Added Files:
src/share/mk: bsd.syscall.mk

Log Message:
use bsd.syscall.mk


To generate a diff of this commit:
cvs rdiff -u -r1.47 -r1.48 src/share/mk/Makefile
cvs rdiff -u -r1.324 -r1.325 src/share/mk/bsd.README
cvs rdiff -u -r0 -r1.1 src/share/mk/bsd.syscall.mk

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

Modified files:

Index: src/share/mk/Makefile
diff -u src/share/mk/Makefile:1.47 src/share/mk/Makefile:1.48
--- src/share/mk/Makefile:1.47	Thu Nov 15 18:51:53 2012
+++ src/share/mk/Makefile	Tue Jan 14 13:51:45 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.47 2012/11/15 23:51:53 joerg Exp $
+#	$NetBSD: Makefile,v 1.48 2014/01/14 18:51:45 christos Exp $
 #	@(#)Makefile	8.1 (Berkeley) 6/8/93
 
 NOOBJ=	# defined
@@ -13,7 +13,7 @@ FILES=	bsd.README bsd.buildinstall.mk bs
 	bsd.kmodule.mk bsd.lib.mk bsd.links.mk bsd.lua.mk \
 	bsd.man.mk bsd.nls.mk \
 	bsd.obj.mk bsd.own.mk bsd.prog.mk bsd.rpc.mk bsd.shlib.mk \
-	bsd.subdir.mk bsd.sys.mk bsd.test.mk bsd.x11.mk sys.mk
+	bsd.subdir.mk bsd.sys.mk bsd.syscall.mk bsd.test.mk bsd.x11.mk sys.mk
 
 FILESDIR=/usr/share/mk
 .endif

Index: src/share/mk/bsd.README
diff -u src/share/mk/bsd.README:1.324 src/share/mk/bsd.README:1.325
--- src/share/mk/bsd.README:1.324	Tue Jan 14 06:32:35 2014
+++ src/share/mk/bsd.README	Tue Jan 14 13:51:45 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.README,v 1.324 2014/01/14 11:32:35 apb Exp $
+#	$NetBSD: bsd.README,v 1.325 2014/01/14 18:51:45 christos Exp $
 #	@(#)bsd.README	8.2 (Berkeley) 4/2/94
 
 This is the README file for the make "include" files for the NetBSD
@@ -1123,6 +1123,11 @@ kernel Makefiles.  It uses similar varia
 Please see  for more details, and keep the documentation
 in that file up to date.
 
+=-=-=-=-=   bsd.syscall.mk =-=-=-=-=
+
+The include file  contains the logic to create syscall
+files for various emulations. It includes  to handle the
+rest of the targets.
 
 =-=-=-=-=   bsd.lib.mk   =-=-=-=-=
 

Added files:

Index: src/share/mk/bsd.syscall.mk
diff -u /dev/null src/share/mk/bsd.syscall.mk:1.1
--- /dev/null	Tue Jan 14 13:51:45 2014
+++ src/share/mk/bsd.syscall.mk	Tue Jan 14 13:51:45 2014
@@ -0,0 +1,17 @@
+# $NetBSD: bsd.syscall.mk,v 1.1 2014/01/14 18:51:45 christos Exp $
+#
+.include 
+.include 
+
+SYSCALL_OBJS?=	${SYSCALL_PREFIX}_sysent.c ${SYSCALL_PREFIX}_syscalls.c \
+	${SYSCALL_PREFIX}_syscall.h ${SYSCALL_PREFIX}_syscallargs.h
+
+SYSCALL_DEPS?=	${NETBSDSRCDIR}/sys/kern/makesyscalls.sh \
+	syscalls.conf syscalls.master
+
+all: ${SYSCALL_OBJS}
+
+${SYSCALL_OBJS}: ${SYSCALL_DEPS}
+	${HOST_SH} ${.ALLSRC}
+
+.include 



CVS commit: src/etc/mtree

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 18:07:20 UTC 2014

Modified Files:
src/etc/mtree: NetBSD.dist.tests

Log Message:
Create new directory for the opencrypto tests


To generate a diff of this commit:
cvs rdiff -u -r1.99 -r1.100 src/etc/mtree/NetBSD.dist.tests

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

Modified files:

Index: src/etc/mtree/NetBSD.dist.tests
diff -u src/etc/mtree/NetBSD.dist.tests:1.99 src/etc/mtree/NetBSD.dist.tests:1.100
--- src/etc/mtree/NetBSD.dist.tests:1.99	Tue Jan  7 16:47:13 2014
+++ src/etc/mtree/NetBSD.dist.tests	Tue Jan 14 18:07:20 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: NetBSD.dist.tests,v 1.99 2014/01/07 16:47:13 gson Exp $
+#	$NetBSD: NetBSD.dist.tests,v 1.100 2014/01/14 18:07:20 pgoyette Exp $
 
 ./usr/libdata/debug/usr/tests
 ./usr/libdata/debug/usr/tests/atf
@@ -14,6 +14,7 @@
 ./usr/libdata/debug/usr/tests/bin/df
 ./usr/libdata/debug/usr/tests/crypto
 ./usr/libdata/debug/usr/tests/crypto/libcrypto
+./usr/libdata/debug/usr/tests/crypto/opencrypto
 ./usr/libdata/debug/usr/tests/dev
 ./usr/libdata/debug/usr/tests/dev/audio
 ./usr/libdata/debug/usr/tests/dev/cgd
@@ -170,6 +171,7 @@
 ./usr/tests/bin/tar
 ./usr/tests/crypto
 ./usr/tests/crypto/libcrypto
+./usr/tests/crypto/opencrypto
 ./usr/tests/dev
 ./usr/tests/dev/audio
 ./usr/tests/dev/cgd



CVS commit: src/tests/crypto

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 18:06:27 UTC 2014

Modified Files:
src/tests/crypto: Makefile

Log Message:
Descend into new opencrypto test suite


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

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

Modified files:

Index: src/tests/crypto/Makefile
diff -u src/tests/crypto/Makefile:1.3 src/tests/crypto/Makefile:1.4
--- src/tests/crypto/Makefile:1.3	Tue Jan 14 17:51:39 2014
+++ src/tests/crypto/Makefile	Tue Jan 14 18:06:27 2014
@@ -1,8 +1,9 @@
-# $NetBSD: Makefile,v 1.3 2014/01/14 17:51:39 pgoyette Exp $
+# $NetBSD: Makefile,v 1.4 2014/01/14 18:06:27 pgoyette Exp $
 
 .include 
 
 TESTS_SUBDIRS=		libcrypto
+TESTS_SUBDIRS+=		opencrypto
 
 TESTSDIR=	${TESTSBASE}/crypto
 TESTSDIR+=	${TESTSBASE}/opencrypto



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

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 17:53:02 UTC 2014

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

Log Message:
Update sets list for new opencrypto test suite


To generate a diff of this commit:
cvs rdiff -u -r1.556 -r1.557 src/distrib/sets/lists/tests/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/tests/mi
diff -u src/distrib/sets/lists/tests/mi:1.556 src/distrib/sets/lists/tests/mi:1.557
--- src/distrib/sets/lists/tests/mi:1.556	Thu Jan  9 02:18:55 2014
+++ src/distrib/sets/lists/tests/mi	Tue Jan 14 17:53:02 2014
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.556 2014/01/09 02:18:55 christos Exp $
+# $NetBSD: mi,v 1.557 2014/01/14 17:53:02 pgoyette Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -21,6 +21,7 @@
 ./usr/libdata/debug/usr/tests/bin/df	tests-bin-debug
 ./usr/libdata/debug/usr/tests/crypto	tests-crypto-debug
 ./usr/libdata/debug/usr/tests/crypto/libcryptotests-crypto-debug
+./usr/libdata/debug/usr/tests/crypto/opencryptotests-crypto-debug
 ./usr/libdata/debug/usr/tests/dev	tests-fs-debug
 ./usr/libdata/debug/usr/tests/dev/audio	tests-fs-debug
 ./usr/libdata/debug/usr/tests/dev/cgd	tests-fs-debug
@@ -857,6 +858,23 @@
 ./usr/tests/crypto/libcrypto/t_hashes		tests-crypto-tests	crypto
 ./usr/tests/crypto/libcrypto/t_libcrypto	tests-crypto-tests	crypto
 ./usr/tests/crypto/libcrypto/t_pubkey		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto			tests-crypto-tests
+./usr/tests/crypto/opencrypto/Atffile		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/Kyuafile		tests-crypto-tests	crypto,kyua
+./usr/tests/crypto/opencrypto/h_aesctr1		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_aesctr2		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_arc4		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_camellia	tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_cbcdes		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_comp		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_comp_zlib	tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_comp_zlib_rnd	tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_gcm		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_md5		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_md5hmac		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_null		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/h_xcbcmac		tests-crypto-tests	crypto
+./usr/tests/crypto/opencrypto/t_opencrypto	tests-crypto-tests	crypto
 ./usr/tests/dev	tests-fs-tests
 ./usr/tests/dev/Atffiletests-fs-tests		atf
 ./usr/tests/dev/Kyuafile			tests-fs-tests		atf,kyua



CVS commit: src/tests/crypto

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 17:51:39 UTC 2014

Modified Files:
src/tests/crypto: Makefile
Added Files:
src/tests/crypto/opencrypto: Makefile Makefile.inc h_aesctr1.c
h_aesctr2.c h_arc4.c h_camellia.c h_cbcdes.c h_comp.c h_comp_zlib.c
h_comp_zlib_rnd.c h_gcm.c h_md5.c h_md5hmac.c h_null.c h_xcbcmac.c
t_opencrypto.sh

Log Message:
Add some trivial tests for the in-kernel opencrypto framework, and link
them into the build.  (Thanks to Matthias Drochner for the test programs!)

XXX The arc4 and null tests currently fail - under investigation.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/tests/crypto/Makefile
cvs rdiff -u -r0 -r1.1 src/tests/crypto/opencrypto/Makefile \
src/tests/crypto/opencrypto/Makefile.inc \
src/tests/crypto/opencrypto/h_aesctr1.c \
src/tests/crypto/opencrypto/h_aesctr2.c \
src/tests/crypto/opencrypto/h_arc4.c \
src/tests/crypto/opencrypto/h_camellia.c \
src/tests/crypto/opencrypto/h_cbcdes.c \
src/tests/crypto/opencrypto/h_comp.c \
src/tests/crypto/opencrypto/h_comp_zlib.c \
src/tests/crypto/opencrypto/h_comp_zlib_rnd.c \
src/tests/crypto/opencrypto/h_gcm.c src/tests/crypto/opencrypto/h_md5.c \
src/tests/crypto/opencrypto/h_md5hmac.c \
src/tests/crypto/opencrypto/h_null.c \
src/tests/crypto/opencrypto/h_xcbcmac.c \
src/tests/crypto/opencrypto/t_opencrypto.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/crypto/Makefile
diff -u src/tests/crypto/Makefile:1.2 src/tests/crypto/Makefile:1.3
--- src/tests/crypto/Makefile:1.2	Tue Jul 13 21:13:21 2010
+++ src/tests/crypto/Makefile	Tue Jan 14 17:51:39 2014
@@ -1,9 +1,10 @@
-# $NetBSD: Makefile,v 1.2 2010/07/13 21:13:21 jmmv Exp $
+# $NetBSD: Makefile,v 1.3 2014/01/14 17:51:39 pgoyette Exp $
 
 .include 
 
 TESTS_SUBDIRS=		libcrypto
 
 TESTSDIR=	${TESTSBASE}/crypto
+TESTSDIR+=	${TESTSBASE}/opencrypto
 
 .include 

Added files:

Index: src/tests/crypto/opencrypto/Makefile
diff -u /dev/null src/tests/crypto/opencrypto/Makefile:1.1
--- /dev/null	Tue Jan 14 17:51:39 2014
+++ src/tests/crypto/opencrypto/Makefile	Tue Jan 14 17:51:39 2014
@@ -0,0 +1,30 @@
+# $NetBSD: Makefile,v 1.1 2014/01/14 17:51:39 pgoyette Exp $
+
+.include 
+
+TESTSDIR=	${TESTSBASE}/crypto/opencrypto
+
+TESTS_SH+=	t_opencrypto
+
+BINDIR=		${TESTSDIR}
+MKMAN=		no
+
+PROGS+=		h_aesctr1
+PROGS+=		h_aesctr2
+PROGS+=		h_arc4
+PROGS+=		h_camellia
+PROGS+=		h_cbcdes
+PROGS+=		h_comp
+PROGS+=		h_comp_zlib
+PROGS+=		h_comp_zlib_rnd
+PROGS+=		h_gcm
+PROGS+=		h_md5
+PROGS+=		h_md5hmac
+PROGS+=		h_null
+PROGS+=		h_xcbcmac
+
+LDADD.h_comp_zlib+=	-lz
+LDADD.h_comp_zlib_rnd+=	-lz
+
+.include 
+
Index: src/tests/crypto/opencrypto/Makefile.inc
diff -u /dev/null src/tests/crypto/opencrypto/Makefile.inc:1.1
--- /dev/null	Tue Jan 14 17:51:39 2014
+++ src/tests/crypto/opencrypto/Makefile.inc	Tue Jan 14 17:51:39 2014
@@ -0,0 +1,3 @@
+# $NetBSD: Makefile.inc,v 1.1 2014/01/14 17:51:39 pgoyette Exp $
+
+.include "../Makefile.inc"
Index: src/tests/crypto/opencrypto/h_aesctr1.c
diff -u /dev/null src/tests/crypto/opencrypto/h_aesctr1.c:1.1
--- /dev/null	Tue Jan 14 17:51:39 2014
+++ src/tests/crypto/opencrypto/h_aesctr1.c	Tue Jan 14 17:51:39 2014
@@ -0,0 +1,91 @@
+/* $NetBSD: h_aesctr1.c,v 1.1 2014/01/14 17:51:39 pgoyette Exp $ */
+
+/*-
+ * Copyright (c) 2014 The NetBSD Foundation, Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *notice, this list of conditions and the following disclaimer in the
+ *documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+#include 
+
+unsigned char key[20] = {0xae, 0x68, 0x5

CVS commit: src/lib/libc

2014-01-14 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Jan 14 17:20:57 UTC 2014

Modified Files:
src/lib/libc: shlib_version

Log Message:
TODO: fix stdout/stdin/stderr to not require copy relocations


To generate a diff of this commit:
cvs rdiff -u -r1.246 -r1.247 src/lib/libc/shlib_version

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

Modified files:

Index: src/lib/libc/shlib_version
diff -u src/lib/libc/shlib_version:1.246 src/lib/libc/shlib_version:1.247
--- src/lib/libc/shlib_version:1.246	Wed Jan  8 12:29:49 2014
+++ src/lib/libc/shlib_version	Tue Jan 14 17:20:57 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: shlib_version,v 1.246 2014/01/08 12:29:49 christos Exp $
+#	$NetBSD: shlib_version,v 1.247 2014/01/14 17:20:57 joerg Exp $
 #	Remember to update distrib/sets/lists/base/shl.* when changing
 #
 # things we wish to do on next major version bump:
@@ -38,5 +38,6 @@
 # - remove alloca fallback and expect compiler to provide a builtin version.
 # - switch to DT_INIT_ARRAY on all platforms
 # - consolidate ownership with crt0.o and avoid common symbols
+# - redo stdin/stdout/stderr to not require copy relocations
 major=12
 minor=188



CVS commit: src/sys/rump/dev

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 17:17:53 UTC 2014

Modified Files:
src/sys/rump/dev: Makefile.rumpdevcomp

Log Message:
Link new opencrypto library into the build.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/rump/dev/Makefile.rumpdevcomp

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

Modified files:

Index: src/sys/rump/dev/Makefile.rumpdevcomp
diff -u src/sys/rump/dev/Makefile.rumpdevcomp:1.6 src/sys/rump/dev/Makefile.rumpdevcomp:1.7
--- src/sys/rump/dev/Makefile.rumpdevcomp:1.6	Thu Mar 31 08:22:54 2011
+++ src/sys/rump/dev/Makefile.rumpdevcomp	Tue Jan 14 17:17:52 2014
@@ -1,8 +1,9 @@
-#	$NetBSD: Makefile.rumpdevcomp,v 1.6 2011/03/31 08:22:54 pooka Exp $
+#	$NetBSD: Makefile.rumpdevcomp,v 1.7 2014/01/14 17:17:52 pgoyette Exp $
 #
 
 RUMPDEVCOMP=	audio bpf cgd disk dm drvctl fss md netsmb pad pud	\
-		putter raidframe rnd scsipi scsitest sysmon wscons
+		putter raidframe rnd scsipi scsitest sysmon wscons	\
+		opencrypto
 
 RUMPUSBDEVS=	ubt ucom ugenhc ulpt umass usb
 



CVS commit: src/distrib/sets/lists

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 17:18:43 UTC 2014

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

Log Message:
Update sets lists for new rump opencrypto library


To generate a diff of this commit:
cvs rdiff -u -r1.685 -r1.686 src/distrib/sets/lists/base/shl.mi
cvs rdiff -u -r1.1873 -r1.1874 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.260 -r1.261 src/distrib/sets/lists/comp/shl.mi
cvs rdiff -u -r1.46 -r1.47 src/distrib/sets/lists/debug/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.685 src/distrib/sets/lists/base/shl.mi:1.686
--- src/distrib/sets/lists/base/shl.mi:1.685	Sat Jan 11 18:38:00 2014
+++ src/distrib/sets/lists/base/shl.mi	Tue Jan 14 17:18:43 2014
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.685 2014/01/11 18:38:00 christos Exp $
+# $NetBSD: shl.mi,v 1.686 2014/01/14 17:18:43 pgoyette Exp $
 #
 # Note:	Don't delete entries from here - mark them as "obsolete" instead,
 #	unless otherwise stated below.
@@ -499,6 +499,9 @@
 ./usr/lib/librumpdev_netsmb.so			base-rump-shlib	rump
 ./usr/lib/librumpdev_netsmb.so.0		base-rump-shlib	rump
 ./usr/lib/librumpdev_netsmb.so.0.0		base-rump-shlib	rump
+./usr/lib/librumpdev_opencrypto.so		base-rump-shlib	rump
+./usr/lib/librumpdev_opencrypto.so.0		base-rump-shlib	rump
+./usr/lib/librumpdev_opencrypto.so.0.0		base-rump-shlib	rump
 ./usr/lib/librumpdev_pad.so			base-rump-shlib	rump
 ./usr/lib/librumpdev_pad.so.0			base-rump-shlib	rump
 ./usr/lib/librumpdev_pad.so.0.0			base-rump-shlib	rump

Index: src/distrib/sets/lists/comp/mi
diff -u src/distrib/sets/lists/comp/mi:1.1873 src/distrib/sets/lists/comp/mi:1.1874
--- src/distrib/sets/lists/comp/mi:1.1873	Wed Jan  8 02:19:12 2014
+++ src/distrib/sets/lists/comp/mi	Tue Jan 14 17:18:43 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: mi,v 1.1873 2014/01/08 02:19:12 christos Exp $
+#	$NetBSD: mi,v 1.1874 2014/01/14 17:18:43 pgoyette Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -3747,6 +3747,8 @@
 ./usr/lib/librumpdev_md_p.a			comp-c-proflib		profile,rump
 ./usr/lib/librumpdev_netsmb.a			comp-c-lib		rump
 ./usr/lib/librumpdev_netsmb_p.a			comp-c-proflib		profile,rump
+./usr/lib/librumpdev_opencrypto.a		comp-c-lib		rump
+./usr/lib/librumpdev_opencrypto_p.a		comp-c-proflib		profile,rump
 ./usr/lib/librumpdev_p.a			comp-c-proflib		profile,rump
 ./usr/lib/librumpdev_pad.a			comp-c-lib		rump
 ./usr/lib/librumpdev_pad_p.a			comp-c-proflib		profile,rump

Index: src/distrib/sets/lists/comp/shl.mi
diff -u src/distrib/sets/lists/comp/shl.mi:1.260 src/distrib/sets/lists/comp/shl.mi:1.261
--- src/distrib/sets/lists/comp/shl.mi:1.260	Thu Jan  2 16:46:40 2014
+++ src/distrib/sets/lists/comp/shl.mi	Tue Jan 14 17:18:43 2014
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.260 2014/01/02 16:46:40 tho Exp $
+# $NetBSD: shl.mi,v 1.261 2014/01/14 17:18:43 pgoyette Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -156,6 +156,7 @@
 ./usr/lib/librumpdev_fss_pic.a			comp-c-piclib		rump,picinstall
 ./usr/lib/librumpdev_md_pic.a			comp-c-piclib		rump,picinstall
 ./usr/lib/librumpdev_netsmb_pic.a		comp-c-piclib		rump,picinstall
+./usr/lib/librumpdev_opencrypto_pic.a		comp-c-piclib		rump,picinstall
 ./usr/lib/librumpdev_pad_pic.a			comp-c-piclib		rump,picinstall
 ./usr/lib/librumpdev_pic.a			comp-c-piclib		rump,picinstall
 ./usr/lib/librumpdev_pud_pic.a			comp-c-piclib		rump,picinstall

Index: src/distrib/sets/lists/debug/mi
diff -u src/distrib/sets/lists/debug/mi:1.46 src/distrib/sets/lists/debug/mi:1.47
--- src/distrib/sets/lists/debug/mi:1.46	Mon Jan  6 14:50:32 2014
+++ src/distrib/sets/lists/debug/mi	Tue Jan 14 17:18:43 2014
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.46 2014/01/06 14:50:32 gson Exp $
+# $NetBSD: mi,v 1.47 2014/01/14 17:18:43 pgoyette Exp $
 
 ./etc/mtree/set.debug   comp-sys-root
 ./usr/lib/i18n/libBIG5_g.a			comp-c-debuglib		debuglib
@@ -145,6 +145,7 @@
 ./usr/lib/librumpdev_g.a			comp-c-debuglib		debuglib,rump
 ./usr/lib/librumpdev_md_g.a			comp-c-debuglib		debuglib,rump
 ./usr/lib/librumpdev_netsmb_g.a			comp-c-debuglib		debuglib,rump
+./usr/lib/librumpdev_opencrypto.a		comp-c-debuglib		debuglib,rump
 ./usr/lib/librumpdev_pad_g.a			comp-c-debuglib		debuglib,rump
 ./usr/lib/librumpdev_pud_g.a			comp-c-debuglib		debuglib,rump
 ./usr/lib/librumpdev_putter_g.a			comp-c-debuglib		debuglib,rump



CVS commit: src/sys/rump/dev/lib/libopencrypto

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 17:15:09 UTC 2014

Added Files:
src/sys/rump/dev/lib/libopencrypto: Makefile component.c shlib_version

Log Message:
Add new rump library for opencrypto framework


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/sys/rump/dev/lib/libopencrypto/Makefile \
src/sys/rump/dev/lib/libopencrypto/component.c \
src/sys/rump/dev/lib/libopencrypto/shlib_version

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

Added files:

Index: src/sys/rump/dev/lib/libopencrypto/Makefile
diff -u /dev/null src/sys/rump/dev/lib/libopencrypto/Makefile:1.1
--- /dev/null	Tue Jan 14 17:15:09 2014
+++ src/sys/rump/dev/lib/libopencrypto/Makefile	Tue Jan 14 17:15:09 2014
@@ -0,0 +1,37 @@
+#	$NetBSD: Makefile,v 1.1 2014/01/14 17:15:09 pgoyette Exp $
+#
+
+.PATH:	${.CURDIR}/../../../../opencrypto
+
+LIB=	rumpdev_opencrypto
+
+SRCS=	component.c
+
+# Sources for crypto framework
+
+SRCS+=	criov.c
+SRCS+=	crypto.c
+SRCS+=	xform.c
+
+# Sources for crypto device, for userland access
+
+SRCS+=	cryptodev.c
+SRCS+=	ocryptodev.c
+
+# Sources for swcrypto device to access opencrypto software algorithms
+# (Other algorithms are in rumpkern_crypto)
+
+SRCS+=	aesxcbcmac.c
+SRCS+=	cryptosoft.c
+SRCS+=	deflate.c
+SRCS+=	gmac.c
+
+.PATH:	${.CURDIR}/../../../../net
+
+SRCS+=	zlib.c
+
+CPPFLAGS+=	-I${RUMPTOP}/librump/rumpvfs
+CPPFLAGS+=	-DCOMPAT_50
+
+.include 
+.include 
Index: src/sys/rump/dev/lib/libopencrypto/component.c
diff -u /dev/null src/sys/rump/dev/lib/libopencrypto/component.c:1.1
--- /dev/null	Tue Jan 14 17:15:09 2014
+++ src/sys/rump/dev/lib/libopencrypto/component.c	Tue Jan 14 17:15:09 2014
@@ -0,0 +1,69 @@
+/*	$NetBSD: component.c,v 1.1 2014/01/14 17:15:09 pgoyette Exp $ */
+
+/*
+ * Copyright (c) 2009 Antti Kantee.  All Rights Reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *notice, this list of conditions and the following disclaimer in the
+ *documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include 
+__KERNEL_RCSID(0, "$NetBSD: component.c,v 1.1 2014/01/14 17:15:09 pgoyette Exp $");
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include "rump_private.h"
+#include "rump_dev_private.h"
+#include "rump_vfs_private.h"
+
+void cryptoattach(int);
+void swcryptoattach(int);
+void crypto_init(void);
+
+RUMP_COMPONENT(RUMP_COMPONENT_DEV)
+{
+	extern const struct cdevsw crypto_cdevsw;
+	devmajor_t bmaj, cmaj;
+	int error;
+
+	/* go, mydevfs */
+	bmaj = cmaj = -1;
+
+	if ((error = devsw_attach("crypto", NULL, &bmaj,
+	&crypto_cdevsw, &cmaj)) != 0)
+		panic("cannot attach crypto: %d", error);
+
+	if ((error = rump_vfs_makeonedevnode(S_IFCHR, "/dev/crypto",
+	cmaj, 0)) != 0)
+		panic("cannot create /dev/crypto: %d", error);
+
+	/*
+	 * Initialize OpenCrypto and its pseudo-devices here
+	 */
+	crypto_init();
+	rump_pdev_add(cryptoattach, 1);
+	rump_pdev_add(swcryptoattach, 0);
+}
Index: src/sys/rump/dev/lib/libopencrypto/shlib_version
diff -u /dev/null src/sys/rump/dev/lib/libopencrypto/shlib_version:1.1
--- /dev/null	Tue Jan 14 17:15:09 2014
+++ src/sys/rump/dev/lib/libopencrypto/shlib_version	Tue Jan 14 17:15:09 2014
@@ -0,0 +1,4 @@
+#	$NetBSD: shlib_version,v 1.1 2014/01/14 17:15:09 pgoyette Exp $
+#
+major=0
+minor=0



CVS commit: src/sys/rump/kern/lib/libcrypto

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 17:05:50 UTC 2014

Modified Files:
src/sys/rump/kern/lib/libcrypto: Makefile

Log Message:
Add the MODULE parts for blowfish and des.

Add camellia algorithm.  (pooka@ says no lib version change required)


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/rump/kern/lib/libcrypto/Makefile

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

Modified files:

Index: src/sys/rump/kern/lib/libcrypto/Makefile
diff -u src/sys/rump/kern/lib/libcrypto/Makefile:1.1 src/sys/rump/kern/lib/libcrypto/Makefile:1.2
--- src/sys/rump/kern/lib/libcrypto/Makefile:1.1	Sun Dec  5 20:11:22 2010
+++ src/sys/rump/kern/lib/libcrypto/Makefile	Tue Jan 14 17:05:50 2014
@@ -1,8 +1,9 @@
-#	$NetBSD: Makefile,v 1.1 2010/12/05 20:11:22 pooka Exp $
+#	$NetBSD: Makefile,v 1.2 2014/01/14 17:05:50 pgoyette Exp $
 #
 
 .PATH:	${.CURDIR}/../../../../crypto/arc4\
 	${.CURDIR}/../../../../crypto/blowfish\
+	${.CURDIR}/../../../../crypto/camellia\
 	${.CURDIR}/../../../../crypto/cast128\
 	${.CURDIR}/../../../../crypto/des\
 	${.CURDIR}/../../../../crypto/rijndael\
@@ -14,13 +15,16 @@ LIB=	rumpkern_crypto
 SRCS+=	arc4.c
 
 # blowfish
-SRCS+=	bf_ecb.c bf_enc.c bf_cbc.c bf_skey.c
+SRCS+=	bf_ecb.c bf_enc.c bf_cbc.c bf_skey.c bf_module.c
+
+# camellia
+SRCS+=  camellia.c camellia-api.c
 
 # cast128
 SRCS+=	cast128.c
 
 # DES
-SRCS+=	des_ecb.c des_setkey.c des_enc.c des_cbc.c
+SRCS+=	des_ecb.c des_setkey.c des_enc.c des_cbc.c des_module.c
 
 # rijndael
 SRCS+=	rijndael-alg-fst.c rijndael-api-fst.c rijndael.c



CVS commit: src/sys/opencrypto

2014-01-14 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Tue Jan 14 14:16:47 UTC 2014

Modified Files:
src/sys/opencrypto: crypto.c

Log Message:
Clean-up module initialization


To generate a diff of this commit:
cvs rdiff -u -r1.43 -r1.44 src/sys/opencrypto/crypto.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/opencrypto/crypto.c
diff -u src/sys/opencrypto/crypto.c:1.43 src/sys/opencrypto/crypto.c:1.44
--- src/sys/opencrypto/crypto.c:1.43	Mon Jan 13 21:15:36 2014
+++ src/sys/opencrypto/crypto.c	Tue Jan 14 14:16:47 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: crypto.c,v 1.43 2014/01/13 21:15:36 pgoyette Exp $ */
+/*	$NetBSD: crypto.c,v 1.44 2014/01/14 14:16:47 pgoyette Exp $ */
 /*	$FreeBSD: src/sys/opencrypto/crypto.c,v 1.4.2.5 2003/02/26 00:14:05 sam Exp $	*/
 /*	$OpenBSD: crypto.c,v 1.41 2002/07/17 23:52:38 art Exp $	*/
 
@@ -53,7 +53,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: crypto.c,v 1.43 2014/01/13 21:15:36 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: crypto.c,v 1.44 2014/01/14 14:16:47 pgoyette Exp $");
 
 #include 
 #include 
@@ -249,6 +249,10 @@ static struct cryptostats cryptostats;
 static	int crypto_timing = 0;
 #endif
 
+#ifdef _MODULE
+	static struct sysctllog *sysctl_opencrypto_clog;
+#endif
+
 static int
 crypto_init0(void)
 {
@@ -282,6 +286,9 @@ crypto_init0(void)
 		crypto_destroy();
 	}
 
+#ifdef _MODULE
+	sysctl_opencrypto_setup(&sysctl_opencrypto_clog);
+#endif
 	return 0;
 }
 
@@ -1342,14 +1349,11 @@ MODULE(MODULE_CLASS_MISC, opencrypto, NU
 static int
 opencrypto_modcmd(modcmd_t cmd, void *opaque)
 {
-#ifdef _MODULE
-	static struct sysctllog *sysctl_opencrypto_clog;
-#endif
 
 	switch (cmd) {
 	case MODULE_CMD_INIT:
 #ifdef _MODULE
-		sysctl_opencrypto_setup(&sysctl_opencrypto_clog);
+		crypto_init();
 #endif
 		return 0;
 	case MODULE_CMD_FINI:



CVS commit: src/etc

2014-01-14 Thread Alan Barrett
Module Name:src
Committed By:   apb
Date:   Tue Jan 14 13:23:46 UTC 2014

Modified Files:
src/etc: ntp.conf

Log Message:
Don't try to use server-specific "restrict" settings;
they do not work when the server is specified by domain name
and the name is associated with multiple IP addresses.

This also means that uncommenting "restrict default ignore"
will not work, so remove the comments suggesting that.

Also edit some other comments.


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/etc/ntp.conf

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

Modified files:

Index: src/etc/ntp.conf
diff -u src/etc/ntp.conf:1.18 src/etc/ntp.conf:1.19
--- src/etc/ntp.conf:1.18	Mon Jan  6 11:26:06 2014
+++ src/etc/ntp.conf	Tue Jan 14 13:23:46 2014
@@ -1,4 +1,4 @@
-# $NetBSD: ntp.conf,v 1.18 2014/01/06 11:26:06 apb Exp $
+# $NetBSD: ntp.conf,v 1.19 2014/01/14 13:23:46 apb Exp $
 #
 # NetBSD default Network Time Protocol (NTP) configuration file for ntpd
 
@@ -50,20 +50,18 @@ mdnstries	0
 #   ntpq or ntpdc queries.
 #   noquery Deny all ntpq and ntpdc queries.  Does not affect time
 #   synchronisation.
-#   nopeer  Prevent establishing an new peer association.
-#   Does not affect preconfigured peer associations.
+#   nopeer  Prevent establishing new peer associations.
+#   Does not affect peers configured using "peer" lines.
 #   Does not affect client/server time synchronisation.
 #   noserve Deny all time synchronisation.  Does not affect ntpq or
 #   ntpdc queries.
 #   notrap  Deny the trap subset of the ntpdc control message protocol.
 #   notrust Deny packets that are not cryptographically authenticated.
 #
-# By default, either deny everything, or allow client/server time exchange
-# but deny configuration changes, queries, and peer associations that were not
-# explicitly configured.
-# (Uncomment one of the following "restrict default" lines.)
+# By default, allow client/server time exchange without prior
+# arrangement, but deny configuration changes, queries, and peer
+# associations that were not explicitly configured.
 #
-#restrict default ignore
 restrict default kod nopeer noquery
 
 # Fewer restrictions for the local subnet.
@@ -84,23 +82,18 @@ restrict ::1
 # and 
 # for advice.
 #
-# Peers should be selected in such a way that the network path to them
-# is short, uncongested, and symmetric (that is, the series of links
-# and routers used to get to the peer is the same one that the peer
-# uses to get back).  The best place to start looking for NTP peers for
-# your system is within your own network, or at your Internet Service
-# Provider (ISP).
+# Peers or servers should be selected in such a way that the network
+# path to them is short, uncongested, and symmetric (that is, the series
+# of links and routers used to get to the peer is the same one that
+# the peer uses to get back).  The best place to start looking for NTP
+# peers for your system is within your own network, or at your Internet
+# Service Provider (ISP).
 #
 # Ideally, you should select at least three other systems to talk NTP
 # with, for an "what I tell you three times is true" effect.
-#
-# A "restrict" line for each configured peer or server might be necessary,
-# if the "restrict default" settings are very restrictive.  As a courtesy
-# to configured peers and servers, consider allowing them to query.
 
 #peer		an.ntp.peer.goes.here
 #server		an.ntp.server.goes.here
-#restrict	an.ntp.server.goes.here nomodify notrap
 
 # The pool.ntp.org project coordinates public time servers provided by
 # volunteers.  See .  The *.netbsd.pool.ntp.org
@@ -117,10 +110,6 @@ restrict ::1
 #
 
 server		0.netbsd.pool.ntp.org
-restrict	0.netbsd.pool.ntp.org nomodify notrap
 server		1.netbsd.pool.ntp.org
-restrict	1.netbsd.pool.ntp.org nomodify notrap
 server		2.netbsd.pool.ntp.org
-restrict	2.netbsd.pool.ntp.org nomodify notrap
 server		3.netbsd.pool.ntp.org
-restrict	3.netbsd.pool.ntp.org nomodify notrap



CVS commit: src/share/mk

2014-01-14 Thread Alan Barrett
Module Name:src
Committed By:   apb
Date:   Tue Jan 14 11:32:35 UTC 2014

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

Log Message:
Document new default for MKARZERO.


To generate a diff of this commit:
cvs rdiff -u -r1.323 -r1.324 src/share/mk/bsd.README

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

Modified files:

Index: src/share/mk/bsd.README
diff -u src/share/mk/bsd.README:1.323 src/share/mk/bsd.README:1.324
--- src/share/mk/bsd.README:1.323	Fri Dec  6 23:14:15 2013
+++ src/share/mk/bsd.README	Tue Jan 14 11:32:35 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.README,v 1.323 2013/12/06 23:14:15 matt Exp $
+#	$NetBSD: bsd.README,v 1.324 2014/01/14 11:32:35 apb Exp $
 #	@(#)bsd.README	8.2 (Berkeley) 4/2/94
 
 This is the README file for the make "include" files for the NetBSD
@@ -1143,7 +1143,8 @@ LIBDIR		Target directory for libraries.
 MKARZERO	Normally, ar(1) sets the timestamps, uid, gid and
 		permissions in files inside its archives to those of
 		the file it was fed. This leads to non-reproduceable
-		builds. If MKARZERO is set to "yes" (default is "no")
+		builds. If MKARZERO is set to "yes" (default is the
+		same as MKREPRO, or "no" if MKREPRO is not defined),
 		then the "D" flag is passed to ar, causing the
 		timestamp, uid and gid to be zeroed and the file
 		permissions to be set to 644. This allows .a files



CVS commit: src/share/mk

2014-01-14 Thread Alan Barrett
Module Name:src
Committed By:   apb
Date:   Tue Jan 14 11:31:01 UTC 2014

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

Log Message:
Let MKARZERO default to the same value as MKREPRO, so callers
can set MKREPRO=yes and automatically get MKARZERO=yes.


To generate a diff of this commit:
cvs rdiff -u -r1.344 -r1.345 src/share/mk/bsd.lib.mk

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

Modified files:

Index: src/share/mk/bsd.lib.mk
diff -u src/share/mk/bsd.lib.mk:1.344 src/share/mk/bsd.lib.mk:1.345
--- src/share/mk/bsd.lib.mk:1.344	Mon Dec 16 21:34:16 2013
+++ src/share/mk/bsd.lib.mk	Tue Jan 14 11:31:01 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.lib.mk,v 1.344 2013/12/16 21:34:16 matt Exp $
+#	$NetBSD: bsd.lib.mk,v 1.345 2014/01/14 11:31:01 apb Exp $
 #	@(#)bsd.lib.mk	8.3 (Berkeley) 4/22/94
 
 .include 
@@ -518,7 +518,7 @@ _YLSRCS=	${SRCS:M*.[ly]:C/\..$/.c/} ${YH
 
 realall: ${SRCS} ${ALLOBJS:O} ${_LIBS} ${_LIB.so.debug}
 
-MKARZERO?=no
+MKARZERO?= ${MKREPRO:Uno}
 
 .if ${MKARZERO} == "yes"
 _ARFL=crsD



CVS commit: src/share/mk

2014-01-14 Thread Alan Barrett
Module Name:src
Committed By:   apb
Date:   Tue Jan 14 11:14:27 UTC 2014

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

Log Message:
Use parentheses in .if A && ( B || C || D || ... )


To generate a diff of this commit:
cvs rdiff -u -r1.760 -r1.761 src/share/mk/bsd.own.mk

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

Modified files:

Index: src/share/mk/bsd.own.mk
diff -u src/share/mk/bsd.own.mk:1.760 src/share/mk/bsd.own.mk:1.761
--- src/share/mk/bsd.own.mk:1.760	Tue Dec 31 18:46:09 2013
+++ src/share/mk/bsd.own.mk	Tue Jan 14 11:14:27 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.own.mk,v 1.760 2013/12/31 18:46:09 christos Exp $
+#	$NetBSD: bsd.own.mk,v 1.761 2014/01/14 11:14:27 apb Exp $
 
 # This needs to be before bsd.init.mk
 .if defined(BSD_MK_COMPAT_FILE)
@@ -973,7 +973,7 @@ X11FLAVOUR?=	Xorg
 # Which platforms build the xorg-server drivers (as opposed
 # to just Xnest and Xvfb.)
 #
-.if ${X11FLAVOUR} == "Xorg"	&& \
+.if ${X11FLAVOUR} == "Xorg"	&& ( \
 ${MACHINE} == "alpha"	|| \
 ${MACHINE} == "amd64"	|| \
 ${MACHINE} == "bebox"	|| \
@@ -998,7 +998,7 @@ X11FLAVOUR?=	Xorg
 ${MACHINE} == "sparc"	|| \
 ${MACHINE} == "sparc64"	|| \
 ${MACHINE} == "vax"		|| \
-${MACHINE} == "zaurus"
+${MACHINE} == "zaurus"	)
 MKXORG_SERVER?=yes
 .else
 MKXORG_SERVER?=no



CVS commit: src/sys/dev/pci

2014-01-14 Thread Michael Lorenz
Module Name:src
Committed By:   macallan
Date:   Tue Jan 14 09:46:42 UTC 2014

Modified Files:
src/sys/dev/pci: radeonfb.c

Log Message:
cap mappable framebuffer size at 64MB before dividing it up for each output
now we can actually access the 2nd fb on boards with more than 64MB VRAM


To generate a diff of this commit:
cvs rdiff -u -r1.80 -r1.81 src/sys/dev/pci/radeonfb.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/pci/radeonfb.c
diff -u src/sys/dev/pci/radeonfb.c:1.80 src/sys/dev/pci/radeonfb.c:1.81
--- src/sys/dev/pci/radeonfb.c:1.80	Tue Jan 14 01:35:13 2014
+++ src/sys/dev/pci/radeonfb.c	Tue Jan 14 09:46:42 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: radeonfb.c,v 1.80 2014/01/14 01:35:13 macallan Exp $ */
+/*	$NetBSD: radeonfb.c,v 1.81 2014/01/14 09:46:42 macallan Exp $ */
 
 /*-
  * Copyright (c) 2006 Itronix Inc.
@@ -70,7 +70,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: radeonfb.c,v 1.80 2014/01/14 01:35:13 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: radeonfb.c,v 1.81 2014/01/14 09:46:42 macallan Exp $");
 
 #include 
 #include 
@@ -627,6 +627,10 @@ radeonfb_attach(device_t parent, device_
 
 	radeonfb_set_fbloc(sc);
 
+	/* 64 MB should be enough -- more just wastes map entries */
+	if (sc->sc_memsz > (64 << 20))
+		sc->sc_memsz = (64 << 20);
+
 	for (i = 0; radeonfb_limits[i].size; i++) {
 		if (sc->sc_memsz >= radeonfb_limits[i].size) {
 			sc->sc_maxx = radeonfb_limits[i].maxx;
@@ -748,10 +752,6 @@ radeonfb_attach(device_t parent, device_
 		goto error;
 	}
 
-	/* 64 MB should be enough -- more just wastes map entries */
-	if (sc->sc_memsz > (64 << 20))
-		sc->sc_memsz = (64 << 20);
-
 	sc->sc_memt = pa->pa_memt;
 	if (bus_space_map(sc->sc_memt, sc->sc_memaddr, sc->sc_memsz,
 		BUS_SPACE_MAP_LINEAR, &sc->sc_memh) != 0) {



CVS commit: src/external/bsd/bind/dist

2014-01-14 Thread S.P.Zeidler
Module Name:src
Committed By:   spz
Date:   Tue Jan 14 08:03:07 UTC 2014

Modified Files:
src/external/bsd/bind/dist: version
src/external/bsd/bind/dist/bin/named: query.c

Log Message:
a fix by ISC for CVE-2014-0591:
3693.  [security]  memcpy was incorrectly called with overlapping
   ranges resulting in malformed names being generated
   on some platforms.  This could cause INSIST failures
   when serving NSEC3 signed zones.  [RT #35120]


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/bsd/bind/dist/version
cvs rdiff -u -r1.12 -r1.13 src/external/bsd/bind/dist/bin/named/query.c

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

Modified files:

Index: src/external/bsd/bind/dist/version
diff -u src/external/bsd/bind/dist/version:1.7 src/external/bsd/bind/dist/version:1.8
--- src/external/bsd/bind/dist/version:1.7	Tue Dec 31 20:24:38 2013
+++ src/external/bsd/bind/dist/version	Tue Jan 14 08:03:07 2014
@@ -4,10 +4,10 @@
 # configure.
 #
 PRODUCT=BIND
-DESCRIPTION="(Extended Support Version)"
+DESCRIPTION="(Development release)"
 MAJORVER=9
 MINORVER=9
 PATCHVER=5
 RELEASETYPE=b
 RELEASEVER=1
-EXTENSIONS=
+EXTENSIONS=nb1

Index: src/external/bsd/bind/dist/bin/named/query.c
diff -u src/external/bsd/bind/dist/bin/named/query.c:1.12 src/external/bsd/bind/dist/bin/named/query.c:1.13
--- src/external/bsd/bind/dist/bin/named/query.c:1.12	Tue Dec 31 20:24:39 2013
+++ src/external/bsd/bind/dist/bin/named/query.c	Tue Jan 14 08:03:07 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: query.c,v 1.12 2013/12/31 20:24:39 christos Exp $	*/
+/*	$NetBSD: query.c,v 1.13 2014/01/14 08:03:07 spz Exp $	*/
 
 /*
  * Copyright (C) 2004-2013  Internet Systems Consortium, Inc. ("ISC")
@@ -5263,8 +5263,7 @@ query_findclosestnsec3(dns_name_t *qname
 	dns_fixedname_t fixed;
 	dns_hash_t hash;
 	dns_name_t name;
-	int order;
-	unsigned int count;
+	unsigned int skip = 0, labels;
 	dns_rdata_nsec3_t nsec3;
 	dns_rdata_t rdata = DNS_RDATA_INIT;
 	isc_boolean_t optout;
@@ -5279,6 +5278,7 @@ query_findclosestnsec3(dns_name_t *qname
 
 	dns_name_init(&name, NULL);
 	dns_name_clone(qname, &name);
+	labels = dns_name_countlabels(&name);
 	dns_clientinfomethods_init(&cm, ns_client_sourceip);
 	dns_clientinfo_init(&ci, client);
 
@@ -5312,13 +5312,14 @@ query_findclosestnsec3(dns_name_t *qname
 		dns_rdata_reset(&rdata);
 		optout = ISC_TF((nsec3.flags & DNS_NSEC3FLAG_OPTOUT) != 0);
 		if (found != NULL && optout &&
-		dns_name_fullcompare(&name, dns_db_origin(db), &order,
-	 &count) == dns_namereln_subdomain) {
+		dns_name_issubdomain(&name, dns_db_origin(db)))
+		{
 			dns_rdataset_disassociate(rdataset);
 			if (dns_rdataset_isassociated(sigrdataset))
 dns_rdataset_disassociate(sigrdataset);
-			count = dns_name_countlabels(&name) - 1;
-			dns_name_getlabelsequence(&name, 1, count, &name);
+			skip++;
+			dns_name_getlabelsequence(qname, skip, labels - skip,
+			  &name);
 			ns_client_log(client, DNS_LOGCATEGORY_DNSSEC,
   NS_LOGMODULE_QUERY, ISC_LOG_DEBUG(3),
   "looking for closest provable encloser");
@@ -5336,7 +5337,11 @@ query_findclosestnsec3(dns_name_t *qname
 		ns_client_log(client, DNS_LOGCATEGORY_DNSSEC,
 			  NS_LOGMODULE_QUERY, ISC_LOG_WARNING,
 			  "expected covering NSEC3, got an exact match");
-	if (found != NULL)
+	if (found == qname) {
+		if (skip != 0U)
+			dns_name_getlabelsequence(qname, skip, labels - skip,
+			  found);
+	} else if (found != NULL)
 		dns_name_copy(&name, found, NULL);
 	return;
 }