CVS commit: src/sys/fs/tmpfs

2013-12-24 Thread Juergen Hannken-Illjes
Module Name:src
Committed By:   hannken
Date:   Tue Dec 24 09:23:33 UTC 2013

Modified Files:
src/sys/fs/tmpfs: tmpfs_vnops.c

Log Message:
It is not the task of tmpfs_open() to check for unlinked nodes.

Fix tmpfs_lookup() to always return ENOENT when looking up from
an unlinked directory.


To generate a diff of this commit:
cvs rdiff -u -r1.109 -r1.110 src/sys/fs/tmpfs/tmpfs_vnops.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/fs/tmpfs/tmpfs_vnops.c
diff -u src/sys/fs/tmpfs/tmpfs_vnops.c:1.109 src/sys/fs/tmpfs/tmpfs_vnops.c:1.110
--- src/sys/fs/tmpfs/tmpfs_vnops.c:1.109	Sun Nov 24 17:16:29 2013
+++ src/sys/fs/tmpfs/tmpfs_vnops.c	Tue Dec 24 09:23:33 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: tmpfs_vnops.c,v 1.109 2013/11/24 17:16:29 rmind Exp $	*/
+/*	$NetBSD: tmpfs_vnops.c,v 1.110 2013/12/24 09:23:33 hannken Exp $	*/
 
 /*
  * Copyright (c) 2005, 2006, 2007 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: tmpfs_vnops.c,v 1.109 2013/11/24 17:16:29 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: tmpfs_vnops.c,v 1.110 2013/12/24 09:23:33 hannken Exp $);
 
 #include sys/param.h
 #include sys/dirent.h
@@ -176,6 +176,15 @@ tmpfs_lookup(void *v)
 		goto out;
 	}
 
+	/*
+	 * Treat an unlinked directory as empty (no . or ..)
+	 */
+	if (dnode-tn_links == 0) {
+		KASSERT(dnode-tn_size == 0);
+		error = ENOENT;
+		goto out;
+	}
+
 	if (cnp-cn_flags  ISDOTDOT) {
 		tmpfs_node_t *pnode;
 
@@ -352,14 +361,6 @@ tmpfs_open(void *v)
 	KASSERT(VOP_ISLOCKED(vp));
 
 	node = VP_TO_TMPFS_NODE(vp);
-	if (node-tn_links  1) {
-		/*
-		 * The file is still active, but all its names have been
-		 * removed (e.g. by a rmdir $(pwd)).  It cannot be opened
-		 * any more, as it is about to be destroyed.
-		 */
-		return ENOENT;
-	}
 
 	/* If the file is marked append-only, deny write requests. */
 	if ((node-tn_flags  APPEND) != 0 



CVS commit: src/sys/fs/sysvbfs

2013-12-24 Thread Juergen Hannken-Illjes
Module Name:src
Committed By:   hannken
Date:   Tue Dec 24 09:56:18 UTC 2013

Modified Files:
src/sys/fs/sysvbfs: sysvbfs_vnops.c

Log Message:
It is not the task of sysvbfs_open() to check for unlinked nodes.


To generate a diff of this commit:
cvs rdiff -u -r1.48 -r1.49 src/sys/fs/sysvbfs/sysvbfs_vnops.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/fs/sysvbfs/sysvbfs_vnops.c
diff -u src/sys/fs/sysvbfs/sysvbfs_vnops.c:1.48 src/sys/fs/sysvbfs/sysvbfs_vnops.c:1.49
--- src/sys/fs/sysvbfs/sysvbfs_vnops.c:1.48	Wed May 15 16:44:03 2013
+++ src/sys/fs/sysvbfs/sysvbfs_vnops.c	Tue Dec 24 09:56:18 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: sysvbfs_vnops.c,v 1.48 2013/05/15 16:44:03 pooka Exp $	*/
+/*	$NetBSD: sysvbfs_vnops.c,v 1.49 2013/12/24 09:56:18 hannken Exp $	*/
 
 /*-
  * Copyright (c) 2004 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: sysvbfs_vnops.c,v 1.48 2013/05/15 16:44:03 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: sysvbfs_vnops.c,v 1.49 2013/12/24 09:56:18 hannken Exp $);
 
 #include sys/param.h
 #include sys/kernel.h
@@ -185,14 +185,10 @@ sysvbfs_open(void *arg)
 	struct vnode *v = a-a_vp;
 	struct sysvbfs_node *bnode = v-v_data;
 	struct bfs_inode *inode = bnode-inode;
-	struct bfs *bfs = bnode-bmp-bfs;
-	struct bfs_dirent *dirent;
 
 	DPRINTF(%s:\n, __func__);
 	KDASSERT(v-v_type == VREG || v-v_type == VDIR);
 
-	if (!bfs_dirent_lookup_by_inode(bfs, inode-number, dirent))
-		return ENOENT;
 	bnode-update_atime = true;
 	if ((a-a_mode  FWRITE)  !(a-a_mode  O_APPEND)) {
 		bnode-size = 0;



CVS commit: src/share/man/man4/man4.amiga

2013-12-24 Thread Radoslaw Kujawa
Module Name:src
Committed By:   rkujawa
Date:   Tue Dec 24 12:07:16 UTC 2013

Modified Files:
src/share/man/man4/man4.amiga: Makefile clockport.4
Added Files:
src/share/man/man4/man4.amiga: acafh.4

Log Message:
Add acafh(4) page for the recently addded acafh driver.
Be more precise in clockport(4).


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/share/man/man4/man4.amiga/Makefile
cvs rdiff -u -r0 -r1.1 src/share/man/man4/man4.amiga/acafh.4
cvs rdiff -u -r1.8 -r1.9 src/share/man/man4/man4.amiga/clockport.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/man4.amiga/Makefile
diff -u src/share/man/man4/man4.amiga/Makefile:1.29 src/share/man/man4/man4.amiga/Makefile:1.30
--- src/share/man/man4/man4.amiga/Makefile:1.29	Fri Aug  9 15:35:54 2013
+++ src/share/man/man4/man4.amiga/Makefile	Tue Dec 24 12:07:16 2013
@@ -1,8 +1,9 @@
 # 	from: @(#)Makefile	8.2 (Berkeley) 2/16/94
-#	$NetBSD: Makefile,v 1.29 2013/08/09 15:35:54 pgoyette Exp $
+#	$NetBSD: Makefile,v 1.30 2013/12/24 12:07:16 rkujawa Exp $
 
-MAN=	a1k2cp.4 afsc.4 ahsc.4 amidisplaycc.4 atzsc.4 autoconf.4 console.4 \
-	bah.4 bppcsc.4 clockport.4 cv3dpb.4 ed.4 efa.4 em4k.4 empb.4 es.4 fdc.4 grf.4 \
+MAN=	a1k2cp.4 acafh.4 afsc.4 ahsc.4 amidisplaycc.4 atzsc.4 autoconf.4 \
+	console.4 bah.4 bppcsc.4 clockport.4 cv3dpb.4 ed.4 efa.4 em4k.4 empb.4 \
+	es.4 fdc.4 grf.4 \
 	grfcl.4 grfcv.4 grfcv3d.4 grfet.4 grfrh.4 grfrt.4 grful.4 \
 	gtsc.4 intro.4 ite.4 mem.4 mfcs.4 mgnsc.4 mppb.4 p5membar.4 p5pb.4 \
 	qn.4 ser.4 wesc.4 xsh.4 xsurf.4 z3rambd.4 zssc.4

Index: src/share/man/man4/man4.amiga/clockport.4
diff -u src/share/man/man4/man4.amiga/clockport.4:1.8 src/share/man/man4/man4.amiga/clockport.4:1.9
--- src/share/man/man4/man4.amiga/clockport.4:1.8	Sat Jul 20 21:39:59 2013
+++ src/share/man/man4/man4.amiga/clockport.4	Tue Dec 24 12:07:16 2013
@@ -1,4 +1,4 @@
-.\ $NetBSD: clockport.4,v 1.8 2013/07/20 21:39:59 wiz Exp $
+.\ $NetBSD: clockport.4,v 1.9 2013/12/24 12:07:16 rkujawa Exp $
 .\
 .\ Copyright (c) 2012 The NetBSD Foundation, Inc.
 .\ All rights reserved.
@@ -52,7 +52,7 @@ Individual Computers SilverSurfer 16C550
 .Sh CODE REFERENCES
 The
 .Nm
-interface is implemented within the
+interface and drivers for it are implemented within the
 .Pa sys/arch/amiga/clockport
 directory.
 .Sh SEE ALSO

Added files:

Index: src/share/man/man4/man4.amiga/acafh.4
diff -u /dev/null src/share/man/man4/man4.amiga/acafh.4:1.1
--- /dev/null	Tue Dec 24 12:07:16 2013
+++ src/share/man/man4/man4.amiga/acafh.4	Tue Dec 24 12:07:16 2013
@@ -0,0 +1,67 @@
+.\ $NetBSD: acafh.4,v 1.1 2013/12/24 12:07:16 rkujawa Exp $
+.\
+.\ Copyright (c) 2013 The NetBSD Foundation, Inc.
+.\ All rights reserved.
+.\
+.\ This code is derived from software contributed to The NetBSD Foundation
+.\ by Radoslaw Kujawa.
+.\
+.\ 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.
+.\
+.Dd December 23, 2013
+.Dt ACAFH 4 amiga
+.Os
+.Sh NAME
+.Nm acafh 
+.Nd Individual Computers ACA500 driver
+.Sh SYNOPSIS
+.Cd acafh0 at mainbus0
+.Cd gencp* at acafhbus?
+.Cd wdc* at acafhbus?
+.Sh DESCRIPTION
+The
+.Nm
+driver provides support for CompactFlash interface (both slots) and clockport
+present on the Individual Computers ACA500 board.
+.Sh HARDWARE
+The
+.Nm
+driver supports the following hardware:
+.Bl -tag -offset indent
+.It Individual Computers ACA500 
+.El
+.Sh SEE ALSO
+.Xr clockport 4 ,
+.\ .Xr gencp 4 ,
+.Xr wdc 4
+.Sh HISTORY
+The
+.Nm
+device first appeared in
+.Nx 7.0 .
+.Sh AUTHORS
+.An -nosplit
+The
+.Nm
+driver was written by
+.An Radoslaw Kujawa
+.Aq radoslaw.kuj...@gmail.com .



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

2013-12-24 Thread Radoslaw Kujawa
Module Name:src
Committed By:   rkujawa
Date:   Tue Dec 24 12:09:19 UTC 2013

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

Log Message:
Add acafh(4) to man dist list.


To generate a diff of this commit:
cvs rdiff -u -r1.1452 -r1.1453 src/distrib/sets/lists/man/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/man/mi
diff -u src/distrib/sets/lists/man/mi:1.1452 src/distrib/sets/lists/man/mi:1.1453
--- src/distrib/sets/lists/man/mi:1.1452	Tue Dec 17 08:46:37 2013
+++ src/distrib/sets/lists/man/mi	Tue Dec 24 12:09:19 2013
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.1452 2013/12/17 08:46:37 njoly Exp $
+# $NetBSD: mi,v 1.1453 2013/12/24 12:09:19 rkujawa Exp $
 #
 # Note: don't delete entries from here - mark them as obsolete instead.
 #
@@ -768,6 +768,7 @@
 ./usr/share/man/cat4/amdtemp.0			man-sys-catman		.cat
 ./usr/share/man/cat4/amhphy.0			man-sys-catman		.cat
 ./usr/share/man/cat4/amiga/a1k2cp.0		man-sys-catman		.cat
+./usr/share/man/cat4/amiga/acafh.0		man-sys-catman		.cat
 ./usr/share/man/cat4/amiga/afsc.0		man-sys-catman		.cat
 ./usr/share/man/cat4/amiga/ahsc.0		man-sys-catman		.cat
 ./usr/share/man/cat4/amiga/amidisplaycc.0	man-sys-catman		.cat
@@ -3809,6 +3810,7 @@
 ./usr/share/man/html4/amdtemp.html		man-sys-htmlman		html
 ./usr/share/man/html4/amhphy.html		man-sys-htmlman		html
 ./usr/share/man/html4/amiga/a1k2cp.html		man-sys-htmlman		html
+./usr/share/man/html4/amiga/acafh.html		man-sys-htmlman		html
 ./usr/share/man/html4/amiga/afsc.html		man-sys-htmlman		html
 ./usr/share/man/html4/amiga/ahsc.html		man-sys-htmlman		html
 ./usr/share/man/html4/amiga/amidisplaycc.html	man-sys-htmlman		html
@@ -6542,6 +6544,7 @@
 ./usr/share/man/man4/amdtemp.4			man-sys-man		.man
 ./usr/share/man/man4/amhphy.4			man-sys-man		.man
 ./usr/share/man/man4/amiga/a1k2cp.4		man-sys-man		.man
+./usr/share/man/man4/amiga/acafh.4		man-sys-man		.man
 ./usr/share/man/man4/amiga/afsc.4		man-sys-man		.man
 ./usr/share/man/man4/amiga/ahsc.4		man-sys-man		.man
 ./usr/share/man/man4/amiga/amidisplaycc.4	man-sys-man		.man



CVS commit: src/share/man/man4/man4.amiga

2013-12-24 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Tue Dec 24 12:20:51 UTC 2013

Modified Files:
src/share/man/man4/man4.amiga: acafh.4

Log Message:
Use Mt. Remove trailing whitespace.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/share/man/man4/man4.amiga/acafh.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/man4.amiga/acafh.4
diff -u src/share/man/man4/man4.amiga/acafh.4:1.1 src/share/man/man4/man4.amiga/acafh.4:1.2
--- src/share/man/man4/man4.amiga/acafh.4:1.1	Tue Dec 24 12:07:16 2013
+++ src/share/man/man4/man4.amiga/acafh.4	Tue Dec 24 12:20:50 2013
@@ -1,4 +1,4 @@
-.\ $NetBSD: acafh.4,v 1.1 2013/12/24 12:07:16 rkujawa Exp $
+.\ $NetBSD: acafh.4,v 1.2 2013/12/24 12:20:50 wiz Exp $
 .\
 .\ Copyright (c) 2013 The NetBSD Foundation, Inc.
 .\ All rights reserved.
@@ -31,7 +31,7 @@
 .Dt ACAFH 4 amiga
 .Os
 .Sh NAME
-.Nm acafh 
+.Nm acafh
 .Nd Individual Computers ACA500 driver
 .Sh SYNOPSIS
 .Cd acafh0 at mainbus0
@@ -47,7 +47,7 @@ The
 .Nm
 driver supports the following hardware:
 .Bl -tag -offset indent
-.It Individual Computers ACA500 
+.It Individual Computers ACA500
 .El
 .Sh SEE ALSO
 .Xr clockport 4 ,
@@ -64,4 +64,4 @@ The
 .Nm
 driver was written by
 .An Radoslaw Kujawa
-.Aq radoslaw.kuj...@gmail.com .
+.Aq Mt radoslaw.kuj...@gmail.com .



CVS commit: src/sys/compat/linux/arch/m68k

2013-12-24 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Tue Dec 24 13:41:25 UTC 2013

Modified Files:
src/sys/compat/linux/arch/m68k: files.linux_m68k syscalls.master

Log Message:
Reduce diffs between arches, add fcntl64() to m68k.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/compat/linux/arch/m68k/files.linux_m68k
cvs rdiff -u -r1.79 -r1.80 src/sys/compat/linux/arch/m68k/syscalls.master

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/linux/arch/m68k/files.linux_m68k
diff -u src/sys/compat/linux/arch/m68k/files.linux_m68k:1.6 src/sys/compat/linux/arch/m68k/files.linux_m68k:1.7
--- src/sys/compat/linux/arch/m68k/files.linux_m68k:1.6	Mon May 30 17:50:31 2011
+++ src/sys/compat/linux/arch/m68k/files.linux_m68k	Tue Dec 24 13:41:25 2013
@@ -1,4 +1,4 @@
-#	$NetBSD: files.linux_m68k,v 1.6 2011/05/30 17:50:31 alnsn Exp $
+#	$NetBSD: files.linux_m68k,v 1.7 2013/12/24 13:41:25 njoly Exp $
 #
 # Config file description for m68k-dependent Linux compat code.
 
@@ -21,3 +21,4 @@ file	compat/linux/common/linux_uid16.c		
 file	compat/linux/common/linux_futex.c		compat_linux
 file	compat/linux/common/linux_fadvise64.c		compat_linux
 file	compat/linux/common/linux_fadvise64_64.c	compat_linux
+file	compat/linux/common/linux_fcntl64.c		compat_linux

Index: src/sys/compat/linux/arch/m68k/syscalls.master
diff -u src/sys/compat/linux/arch/m68k/syscalls.master:1.79 src/sys/compat/linux/arch/m68k/syscalls.master:1.80
--- src/sys/compat/linux/arch/m68k/syscalls.master:1.79	Sun Dec  8 15:55:10 2013
+++ src/sys/compat/linux/arch/m68k/syscalls.master	Tue Dec 24 13:41:25 2013
@@ -1,4 +1,4 @@
-	$NetBSD: syscalls.master,v 1.79 2013/12/08 15:55:10 njoly Exp $
+	$NetBSD: syscalls.master,v 1.80 2013/12/24 13:41:25 njoly Exp $
 
 ;	@(#)syscalls.master	8.1 (Berkeley) 7/19/93
 
@@ -426,7 +426,7 @@
 236	UNIMPL		sendfile64
 237	UNIMPL		mincore
 238	UNIMPL		madvise
-239	UNIMPL		fcntl64
+239	STD		{ int|linux_sys||fcntl64(int fd, int cmd, void *arg); }
 240	UNIMPL		readahead
 241	UNIMPL		io_setup
 242	UNIMPL		io_destroy



CVS commit: src/sys/compat/linux/arch/m68k

2013-12-24 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Tue Dec 24 13:41:55 UTC 2013

Modified Files:
src/sys/compat/linux/arch/m68k: linux_syscall.h linux_syscallargs.h
linux_syscalls.c linux_sysent.c

Log Message:
Regen for fcntl64().


To generate a diff of this commit:
cvs rdiff -u -r1.85 -r1.86 src/sys/compat/linux/arch/m68k/linux_syscall.h \
src/sys/compat/linux/arch/m68k/linux_syscalls.c \
src/sys/compat/linux/arch/m68k/linux_sysent.c
cvs rdiff -u -r1.84 -r1.85 src/sys/compat/linux/arch/m68k/linux_syscallargs.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/compat/linux/arch/m68k/linux_syscall.h
diff -u src/sys/compat/linux/arch/m68k/linux_syscall.h:1.85 src/sys/compat/linux/arch/m68k/linux_syscall.h:1.86
--- src/sys/compat/linux/arch/m68k/linux_syscall.h:1.85	Sun Dec  8 15:56:13 2013
+++ src/sys/compat/linux/arch/m68k/linux_syscall.h	Tue Dec 24 13:41:55 2013
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.85 2013/12/08 15:56:13 njoly Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.86 2013/12/24 13:41:55 njoly Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.79 2013/12/08 15:55:10 njoly Exp
+ * created from	NetBSD: syscalls.master,v 1.80 2013/12/24 13:41:25 njoly Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -615,6 +615,9 @@
 /* syscall: futex ret: int args: int * int int const struct linux_timespec * int * int */
 #define	LINUX_SYS_futex	235
 
+/* syscall: fcntl64 ret: int args: int int void * */
+#define	LINUX_SYS_fcntl64	239
+
 /* syscall: fadvise64 ret: int args: int linux_off_t size_t int */
 #define	LINUX_SYS_fadvise64	246
 
Index: src/sys/compat/linux/arch/m68k/linux_syscalls.c
diff -u src/sys/compat/linux/arch/m68k/linux_syscalls.c:1.85 src/sys/compat/linux/arch/m68k/linux_syscalls.c:1.86
--- src/sys/compat/linux/arch/m68k/linux_syscalls.c:1.85	Sun Dec  8 15:56:13 2013
+++ src/sys/compat/linux/arch/m68k/linux_syscalls.c	Tue Dec 24 13:41:55 2013
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.85 2013/12/08 15:56:13 njoly Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.86 2013/12/24 13:41:55 njoly Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.79 2013/12/08 15:55:10 njoly Exp
+ * created from	NetBSD: syscalls.master,v 1.80 2013/12/24 13:41:25 njoly Exp
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: linux_syscalls.c,v 1.85 2013/12/08 15:56:13 njoly Exp $);
+__KERNEL_RCSID(0, $NetBSD: linux_syscalls.c,v 1.86 2013/12/24 13:41:55 njoly Exp $);
 
 #if defined(_KERNEL_OPT)
 #if defined(_KERNEL_OPT)
@@ -291,7 +291,7 @@ const char *const linux_syscallnames[] =
 	/* 236 */	#236 (unimplemented sendfile64),
 	/* 237 */	#237 (unimplemented mincore),
 	/* 238 */	#238 (unimplemented madvise),
-	/* 239 */	#239 (unimplemented fcntl64),
+	/* 239 */	fcntl64,
 	/* 240 */	#240 (unimplemented readahead),
 	/* 241 */	#241 (unimplemented io_setup),
 	/* 242 */	#242 (unimplemented io_destroy),
Index: src/sys/compat/linux/arch/m68k/linux_sysent.c
diff -u src/sys/compat/linux/arch/m68k/linux_sysent.c:1.85 src/sys/compat/linux/arch/m68k/linux_sysent.c:1.86
--- src/sys/compat/linux/arch/m68k/linux_sysent.c:1.85	Sun Dec  8 15:56:13 2013
+++ src/sys/compat/linux/arch/m68k/linux_sysent.c	Tue Dec 24 13:41:55 2013
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.85 2013/12/08 15:56:13 njoly Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.86 2013/12/24 13:41:55 njoly Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.79 2013/12/08 15:55:10 njoly Exp
+ * created from	NetBSD: syscalls.master,v 1.80 2013/12/24 13:41:25 njoly Exp
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: linux_sysent.c,v 1.85 2013/12/08 15:56:13 njoly Exp $);
+__KERNEL_RCSID(0, $NetBSD: linux_sysent.c,v 1.86 2013/12/24 13:41:55 njoly Exp $);
 
 #if defined(_KERNEL_OPT)
 #include opt_compat_netbsd.h
@@ -537,8 +537,8 @@ struct sysent linux_sysent[] = {
 	linux_sys_nosys },			/* 237 = unimplemented mincore */
 	{ 0, 0, 0,
 	linux_sys_nosys },			/* 238 = unimplemented madvise */
-	{ 0, 0, 0,
-	linux_sys_nosys },			/* 239 = unimplemented fcntl64 */
+	{ ns(struct linux_sys_fcntl64_args), SYCALL_ARG_PTR,
+	(sy_call_t *)linux_sys_fcntl64 },	/* 239 = fcntl64 */
 	{ 0, 0, 0,
 	linux_sys_nosys },			/* 240 = unimplemented readahead */
 	{ 0, 0, 0,

Index: src/sys/compat/linux/arch/m68k/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/m68k/linux_syscallargs.h:1.84 src/sys/compat/linux/arch/m68k/linux_syscallargs.h:1.85
--- src/sys/compat/linux/arch/m68k/linux_syscallargs.h:1.84	Sun Dec  8 15:56:13 2013
+++ src/sys/compat/linux/arch/m68k/linux_syscallargs.h	Tue Dec 24 13:41:55 2013
@@ -1,10 +1,10 @@
-/* $NetBSD: 

CVS commit: src/sys/netipsec

2013-12-24 Thread Arnaud Degroote
Module Name:src
Committed By:   degroote
Date:   Tue Dec 24 13:57:06 UTC 2013

Modified Files:
src/sys/netipsec: ipsec.c

Log Message:
fix a typo in the log ouput of ipsec4_get_policy


To generate a diff of this commit:
cvs rdiff -u -r1.60 -r1.61 src/sys/netipsec/ipsec.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/netipsec/ipsec.c
diff -u src/sys/netipsec/ipsec.c:1.60 src/sys/netipsec/ipsec.c:1.61
--- src/sys/netipsec/ipsec.c:1.60	Sat Jun  8 13:50:22 2013
+++ src/sys/netipsec/ipsec.c	Tue Dec 24 13:57:06 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: ipsec.c,v 1.60 2013/06/08 13:50:22 rmind Exp $	*/
+/*	$NetBSD: ipsec.c,v 1.61 2013/12/24 13:57:06 degroote Exp $	*/
 /*	$FreeBSD: /usr/local/www/cvsroot/FreeBSD/src/sys/netipsec/ipsec.c,v 1.2.2.2 2003/07/01 01:38:13 sam Exp $	*/
 /*	$KAME: ipsec.c,v 1.103 2001/05/24 07:14:18 sakane Exp $	*/
 
@@ -32,7 +32,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: ipsec.c,v 1.60 2013/06/08 13:50:22 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: ipsec.c,v 1.61 2013/12/24 13:57:06 degroote Exp $);
 
 /*
  * IPsec controller part.
@@ -1611,7 +1611,7 @@ ipsec4_get_policy(struct inpcb *inp, con
 		policy = inp-inp_sp-sp_out;
 		break;
 	default:
-		ipseclog((LOG_ERR, ipsec4_set_policy: invalid direction=%u\n,
+		ipseclog((LOG_ERR, ipsec4_get_policy: invalid direction=%u\n,
 			xpl-sadb_x_policy_dir));
 		return EINVAL;
 	}



CVS commit: src/sys/kern

2013-12-24 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Dec 24 14:47:04 UTC 2013

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

Log Message:
replace strcpy with copystr and remove useless strcpy (Maxime Villard)


To generate a diff of this commit:
cvs rdiff -u -r1.367 -r1.368 src/sys/kern/kern_exec.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/kern_exec.c
diff -u src/sys/kern/kern_exec.c:1.367 src/sys/kern/kern_exec.c:1.368
--- src/sys/kern/kern_exec.c:1.367	Sat Nov 23 17:15:16 2013
+++ src/sys/kern/kern_exec.c	Tue Dec 24 09:47:04 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: kern_exec.c,v 1.367 2013/11/23 22:15:16 christos Exp $	*/
+/*	$NetBSD: kern_exec.c,v 1.368 2013/12/24 14:47:04 christos Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -59,7 +59,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: kern_exec.c,v 1.367 2013/11/23 22:15:16 christos Exp $);
+__KERNEL_RCSID(0, $NetBSD: kern_exec.c,v 1.368 2013/12/24 14:47:04 christos Exp $);
 
 #include opt_exec.h
 #include opt_execfmt.h
@@ -319,8 +319,9 @@ check_exec(struct lwp *l, struct exec_pa
 	if ((error = namei(nd)) != 0)
 		return error;
 	epp-ep_vp = vp = nd.ni_vp;
-	/* this cannot overflow as both are size PATH_MAX */
-	strcpy(epp-ep_resolvedname, nd.ni_pnbuf);
+	/* normally this can't fail */
+	if ((error = copystr(nd.ni_pnbuf, epp-ep_resolvedname, PATH_MAX, NULL)))
+		goto bad1;
 
 #ifdef DIAGNOSTIC
 	/* paranoia (take this out once namei stuff stabilizes) */
@@ -640,11 +641,7 @@ execve_loadvm(struct lwp *l, const char 
 		goto clrflg;
 	}
 	data-ed_pathstring = pathbuf_stringcopy_get(data-ed_pathbuf);
-
 	data-ed_resolvedpathbuf = PNBUF_GET();
-#ifdef DIAGNOSTIC
-	strcpy(data-ed_resolvedpathbuf, /wrong);
-#endif
 
 	/*
 	 * initialize the fields of the exec package.



CVS commit: src/external/gpl3/binutils/dist/bfd

2013-12-24 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Tue Dec 24 15:06:40 UTC 2013

Modified Files:
src/external/gpl3/binutils/dist/bfd: config.bfd

Log Message:
Enable 32/64-bit PE-COFF targets for NetBSD/i386 in libbfd.
Needed to build UEFI things for IA32 using native toolchain.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/external/gpl3/binutils/dist/bfd/config.bfd

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

Modified files:

Index: src/external/gpl3/binutils/dist/bfd/config.bfd
diff -u src/external/gpl3/binutils/dist/bfd/config.bfd:1.9 src/external/gpl3/binutils/dist/bfd/config.bfd:1.10
--- src/external/gpl3/binutils/dist/bfd/config.bfd:1.9	Sun Sep 29 14:03:29 2013
+++ src/external/gpl3/binutils/dist/bfd/config.bfd	Tue Dec 24 15:06:39 2013
@@ -575,8 +575,8 @@ case ${targ} in
 ;;
   i[3-7]86-*-netbsdelf* | i[3-7]86-*-netbsd*-gnu* | i[3-7]86-*-knetbsd*-gnu)
 targ_defvec=bfd_elf32_i386_vec
-targ_selvecs=i386netbsd_vec
-targ64_selvecs=bfd_elf64_x86_64_vec bfd_elf64_l1om_vec bfd_elf64_k1om_vec
+targ_selvecs=i386netbsd_vec i386coff_vec i386pei_vec
+targ64_selvecs=bfd_elf64_x86_64_vec x86_64pei_vec bfd_elf64_l1om_vec bfd_elf64_k1om_vec
 ;;
   i[3-7]86-*-netbsdpe*)
 targ_defvec=i386pe_vec



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

2013-12-24 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Dec 24 15:42:56 UTC 2013

Modified Files:
src/sys/arch/x86/x86: bus_dma.c

Log Message:
use __func__


To generate a diff of this commit:
cvs rdiff -u -r1.70 -r1.71 src/sys/arch/x86/x86/bus_dma.c

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

Modified files:

Index: src/sys/arch/x86/x86/bus_dma.c
diff -u src/sys/arch/x86/x86/bus_dma.c:1.70 src/sys/arch/x86/x86/bus_dma.c:1.71
--- src/sys/arch/x86/x86/bus_dma.c:1.70	Tue Jul  2 18:39:45 2013
+++ src/sys/arch/x86/x86/bus_dma.c	Tue Dec 24 10:42:56 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: bus_dma.c,v 1.70 2013/07/02 22:39:45 christos Exp $	*/
+/*	$NetBSD: bus_dma.c,v 1.71 2013/12/24 15:42:56 christos Exp $	*/
 
 /*-
  * Copyright (c) 1996, 1997, 1998, 2007 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: bus_dma.c,v 1.70 2013/07/02 22:39:45 christos Exp $);
+__KERNEL_RCSID(0, $NetBSD: bus_dma.c,v 1.71 2013/12/24 15:42:56 christos Exp $);
 
 /*
  * The following is included because _bus_dma_uiomove is derived from
@@ -802,11 +802,11 @@ _bus_dmamap_sync(bus_dma_tag_t t, bus_dm
 #ifdef DIAGNOSTIC
 	if ((ops  (BUS_DMASYNC_PREWRITE|BUS_DMASYNC_POSTREAD)) != 0) {
 		if (offset = map-dm_mapsize)
-			panic(_bus_dmamap_sync: bad offset 0x%jx = 0x%jx,
+			panic(%s: bad offset 0x%jx = 0x%jx, __func__,
 			(intmax_t)offset, (intmax_t)map-dm_mapsize);
 		if ((offset + len)  map-dm_mapsize)
-			panic(_bus_dmamap_sync: bad length 0x%jx + 0x%jx 
-			 0x%jx, (intmax_t)offset, (intmax_t)len,
+			panic(%s: bad length 0x%jx + 0x%jx  0x%jx, __func__,
+			(intmax_t)offset, (intmax_t)len,
 			(intmax_t)map-dm_mapsize);
 	}
 #endif



CVS commit: src/sys/netipsec

2013-12-24 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Dec 24 15:48:53 UTC 2013

Modified Files:
src/sys/netipsec: ipsec.c

Log Message:
fix debugging output printfs to use __func__ so they print the correct names.


To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/sys/netipsec/ipsec.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/netipsec/ipsec.c
diff -u src/sys/netipsec/ipsec.c:1.61 src/sys/netipsec/ipsec.c:1.62
--- src/sys/netipsec/ipsec.c:1.61	Tue Dec 24 08:57:06 2013
+++ src/sys/netipsec/ipsec.c	Tue Dec 24 10:48:53 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: ipsec.c,v 1.61 2013/12/24 13:57:06 degroote Exp $	*/
+/*	$NetBSD: ipsec.c,v 1.62 2013/12/24 15:48:53 christos Exp $	*/
 /*	$FreeBSD: /usr/local/www/cvsroot/FreeBSD/src/sys/netipsec/ipsec.c,v 1.2.2.2 2003/07/01 01:38:13 sam Exp $	*/
 /*	$KAME: ipsec.c,v 1.103 2001/05/24 07:14:18 sakane Exp $	*/
 
@@ -32,7 +32,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: ipsec.c,v 1.61 2013/12/24 13:57:06 degroote Exp $);
+__KERNEL_RCSID(0, $NetBSD: ipsec.c,v 1.62 2013/12/24 15:48:53 christos Exp $);
 
 /*
  * IPsec controller part.
@@ -268,7 +268,7 @@ ipsec_checkpcbcache(struct mbuf *m, stru
 	}
 #ifdef DIAGNOSTIC
 	if (pcbsp == NULL) {
-		printf(ipsec_checkpcbcache: NULL pcbsp\n);
+		printf(%s: NULL pcbsp\n, __func__);
 		/* XXX panic? */
 		return NULL;
 	}
@@ -320,9 +320,9 @@ ipsec_checkpcbcache(struct mbuf *m, stru
 	pcbsp-sp_cache[dir].cachesp-lastused = time_second;
 	pcbsp-sp_cache[dir].cachesp-refcnt++;
 	KEYDEBUG(KEYDEBUG_IPSEC_STAMP,
-		printf(DP ipsec_checkpcbcache cause refcnt++:%d SP:%p\n,
-		pcbsp-sp_cache[dir].cachesp-refcnt,
-		pcbsp-sp_cache[dir].cachesp));
+	printf(DP %s cause refcnt++:%d SP:%p\n, __func__,
+	pcbsp-sp_cache[dir].cachesp-refcnt,
+	pcbsp-sp_cache[dir].cachesp));
 	return pcbsp-sp_cache[dir].cachesp;
 }
 
@@ -354,9 +354,9 @@ ipsec_fillpcbcache(struct inpcbpolicy *p
 	if (pcbsp-sp_cache[dir].cachesp) {
 		pcbsp-sp_cache[dir].cachesp-refcnt++;
 		KEYDEBUG(KEYDEBUG_IPSEC_STAMP,
-			printf(DP ipsec_fillpcbcache cause refcnt++:%d SP:%p\n,
-			pcbsp-sp_cache[dir].cachesp-refcnt,
-			pcbsp-sp_cache[dir].cachesp));
+		printf(DP %s cause refcnt++:%d SP:%p\n, __func__,
+		pcbsp-sp_cache[dir].cachesp-refcnt,
+		pcbsp-sp_cache[dir].cachesp));
 
 		/*
 		 * If the PCB is connected, we can remember a hint to
@@ -435,7 +435,7 @@ key_allocsp_default(int af, const char *
 	struct secpolicy *sp;
 
 	KEYDEBUG(KEYDEBUG_IPSEC_STAMP,
-		printf(DP key_allocsp_default from %s:%u\n, where, tag));
+	printf(DP %s from %s:%u\n, __func__, where, tag));
 
 switch(af) {
 case AF_INET:
@@ -448,22 +448,21 @@ key_allocsp_default(int af, const char *
 #endif
 default:
 	KEYDEBUG(KEYDEBUG_IPSEC_STAMP,
-		printf(key_allocsp_default : unexpected protocol family %u\n,
-   af));
+		printf(%s: unexpected protocol family %u\n, __func__,
+af));
 return NULL;
 }
 
 	if (sp-policy != IPSEC_POLICY_DISCARD 
 		sp-policy != IPSEC_POLICY_NONE) {
 		ipseclog((LOG_INFO, fixed system default policy: %d-%d\n,
-			sp-policy, IPSEC_POLICY_NONE));
+		sp-policy, IPSEC_POLICY_NONE));
 		sp-policy = IPSEC_POLICY_NONE;
 	}
 	sp-refcnt++;
 
-	KEYDEBUG(KEYDEBUG_IPSEC_STAMP,
-		printf(DP key_allocsp_default returns SP:%p (%u)\n,
-			sp, sp-refcnt));
+	KEYDEBUG(KEYDEBUG_IPSEC_STAMP, printf(DP %s returns SP:%p (%u)\n,
+	__func__, sp, sp-refcnt));
 	return sp;
 }
 #define	KEY_ALLOCSP_DEFAULT(af) \
@@ -486,14 +485,14 @@ ipsec_getpolicy(const struct tdb_ident *
 {
 	struct secpolicy *sp;
 
-	IPSEC_ASSERT(tdbi != NULL, (ipsec_getpolicy: null tdbi));
+	IPSEC_ASSERT(tdbi != NULL, (%s: null tdbi, __func__));
 	IPSEC_ASSERT(dir == IPSEC_DIR_INBOUND || dir == IPSEC_DIR_OUTBOUND,
-		(ipsec_getpolicy: invalid direction %u, dir));
+	(%s: invalid direction %u, __func__, dir));
 
 	sp = KEY_ALLOCSP2(tdbi-spi, tdbi-dst, tdbi-proto, dir);
 	if (sp == NULL)			/*XXX*/
 		sp = KEY_ALLOCSP_DEFAULT(tdbi-dst.sa.sa_family);
-	IPSEC_ASSERT(sp != NULL, (ipsec_getpolicy: null SP));
+	IPSEC_ASSERT(sp != NULL, (%s: null SP, __func__));
 	return sp;
 }
 
@@ -517,19 +516,18 @@ ipsec_getpolicybysock(struct mbuf *m, u_
 	struct secpolicy *sp;
 	int af;
 
-	IPSEC_ASSERT(m != NULL, (ipsec_getpolicybysock: null mbuf));
-	IPSEC_ASSERT(inp != NULL, (ipsec_getpolicybysock: null inpcb));
-	IPSEC_ASSERT(error != NULL, (ipsec_getpolicybysock: null error));
+	IPSEC_ASSERT(m != NULL, (%s: null mbuf, __func__));
+	IPSEC_ASSERT(inp != NULL, (%s: null inpcb, __func__));
+	IPSEC_ASSERT(error != NULL, (%s: null error, __func__));
 	IPSEC_ASSERT(dir == IPSEC_DIR_INBOUND || dir == IPSEC_DIR_OUTBOUND,
-		(ipsec_getpolicybysock: invalid direction %u, dir));
+	(%s: invalid direction %u, __func__, dir));
 
-	IPSEC_ASSERT(PCB_SOCKET(inp) != NULL,
-		(ipsec_getppolicybysock: null 

CVS commit: src/external/gpl3/binutils/lib/libbfd/arch/i386

2013-12-24 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Tue Dec 24 16:01:07 UTC 2013

Modified Files:
src/external/gpl3/binutils/lib/libbfd/arch/i386: defs.mk

Log Message:
regenerate for src/external/gpl3/binutils/dist/bfd/config.bfd r1.10:

Enable 32/64-bit PE-COFF targets for NetBSD/i386 in libbfd.
Needed to build UEFI things for IA32 using native toolchain.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 \
src/external/gpl3/binutils/lib/libbfd/arch/i386/defs.mk

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

Modified files:

Index: src/external/gpl3/binutils/lib/libbfd/arch/i386/defs.mk
diff -u src/external/gpl3/binutils/lib/libbfd/arch/i386/defs.mk:1.3 src/external/gpl3/binutils/lib/libbfd/arch/i386/defs.mk:1.4
--- src/external/gpl3/binutils/lib/libbfd/arch/i386/defs.mk:1.3	Sun Sep 29 14:20:35 2013
+++ src/external/gpl3/binutils/lib/libbfd/arch/i386/defs.mk	Tue Dec 24 16:01:07 2013
@@ -1,9 +1,9 @@
 # This file is automatically generated.  DO NOT EDIT!
-# Generated from: 	NetBSD: mknative-binutils,v 1.8 2011/09/25 04:00:58 christos Exp 
-# Generated from: NetBSD: mknative.common,v 1.9 2007/02/05 18:26:01 apb Exp 
+# Generated from: 	NetBSD: mknative-binutils,v 1.9 2013/10/01 15:41:17 skrll Exp 
+# Generated from: NetBSD: mknative.common,v 1.10 2013/10/20 16:00:20 skrll Exp 
 #
-G_libbfd_la_DEPENDENCIES=elf32-i386.lo elf-ifunc.lo elf-nacl.lo elf-vxworks.lo elf32.lo elf.lo elflink.lo elf-attrs.lo elf-strtab.lo elf-eh-frame.lo dwarf1.lo i386netbsd.lo aout32.lo elf32-gen.lo cpu-i386.lo netbsd-core.lo ofiles
+G_libbfd_la_DEPENDENCIES=elf32-i386.lo elf-ifunc.lo elf-nacl.lo elf-vxworks.lo elf32.lo elf.lo elflink.lo elf-attrs.lo elf-strtab.lo elf-eh-frame.lo dwarf1.lo i386netbsd.lo aout32.lo coff-i386.lo cofflink.lo pei-i386.lo peigen.lo elf32-gen.lo cpu-i386.lo netbsd-core.lo ofiles
 G_libbfd_la_OBJECTS=archive.lo archures.lo bfd.lo bfdio.lo bfdwin.lo  cache.lo coffgen.lo corefile.lo format.lo init.lo libbfd.lo  opncls.lo reloc.lo section.lo syms.lo targets.lo hash.lo  linker.lo srec.lo binary.lo tekhex.lo ihex.lo stabs.lo  stab-syms.lo merge.lo dwarf2.lo simple.lo compress.lo  verilog.lo
 G_DEFS=-DHAVE_CONFIG_H
-G_INCLUDES=-DNETBSD_CORE   -I. -I${GNUHOSTDIST}/bfd -I${GNUHOSTDIST}/bfd/../include   -DHAVE_bfd_elf32_i386_vec -DHAVE_i386netbsd_vec -DHAVE_bfd_elf32_little_generic_vec -DHAVE_bfd_elf32_big_generic_vec -I./../intl
-G_TDEFAULTS=-DDEFAULT_VECTOR=bfd_elf32_i386_vec -DSELECT_VECS='bfd_elf32_i386_vec,i386netbsd_vec,bfd_elf32_little_generic_vec,bfd_elf32_big_generic_vec' -DSELECT_ARCHITECTURES='bfd_i386_arch'
+G_INCLUDES=-DNETBSD_CORE   -I. -I${GNUHOSTDIST}/bfd -I${GNUHOSTDIST}/bfd/../include   -DHAVE_bfd_elf32_i386_vec -DHAVE_i386netbsd_vec -DHAVE_i386coff_vec -DHAVE_i386pei_vec -DHAVE_bfd_elf32_little_generic_vec -DHAVE_bfd_elf32_big_generic_vec -I./../intl
+G_TDEFAULTS=-DDEFAULT_VECTOR=bfd_elf32_i386_vec -DSELECT_VECS='bfd_elf32_i386_vec,i386netbsd_vec,i386coff_vec,i386pei_vec,bfd_elf32_little_generic_vec,bfd_elf32_big_generic_vec' -DSELECT_ARCHITECTURES='bfd_i386_arch'



CVS commit: src/sys/fs/msdosfs

2013-12-24 Thread Michael van Elst
Module Name:src
Committed By:   mlelstv
Date:   Tue Dec 24 16:51:24 UTC 2013

Modified Files:
src/sys/fs/msdosfs: msdosfs_lookup.c

Log Message:
don't treat adjacent members as a larger array
Coverity CID 977367


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/sys/fs/msdosfs/msdosfs_lookup.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/fs/msdosfs/msdosfs_lookup.c
diff -u src/sys/fs/msdosfs/msdosfs_lookup.c:1.29 src/sys/fs/msdosfs/msdosfs_lookup.c:1.30
--- src/sys/fs/msdosfs/msdosfs_lookup.c:1.29	Sat Jan 26 16:51:51 2013
+++ src/sys/fs/msdosfs/msdosfs_lookup.c	Tue Dec 24 16:51:24 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: msdosfs_lookup.c,v 1.29 2013/01/26 16:51:51 christos Exp $	*/
+/*	$NetBSD: msdosfs_lookup.c,v 1.30 2013/12/24 16:51:24 mlelstv Exp $	*/
 
 /*-
  * Copyright (C) 1994, 1995, 1997 Wolfgang Solfrank.
@@ -52,7 +52,7 @@
 #endif
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: msdosfs_lookup.c,v 1.29 2013/01/26 16:51:51 christos Exp $);
+__KERNEL_RCSID(0, $NetBSD: msdosfs_lookup.c,v 1.30 2013/12/24 16:51:24 mlelstv Exp $);
 
 #include sys/param.h
 
@@ -300,8 +300,10 @@ msdosfs_lookup(void *v)
  * Check for a checksum or name match
  */
 chksum_ok = (chksum == winChksum(dep-deName));
-if (!chksum_ok
- (!olddos || memcmp(dosfilename, dep-deName, 11))) {
+if (!chksum_ok  (
+	!olddos ||
+	memcmp(dosfilename[0],dep-deName,8) ||
+	memcmp(dosfilename[8],dep-deExtension,3))) {
 	chksum = -1;
 	continue;
 }



CVS commit: src/sys/arch/evbarm/conf

2013-12-24 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Dec 24 17:00:39 UTC 2013

Modified Files:
src/sys/arch/evbarm/conf: ldscript.evbarm

Log Message:
Make sure _edata starts on a 8-byte boundary.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/evbarm/conf/ldscript.evbarm

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/evbarm/conf/ldscript.evbarm
diff -u src/sys/arch/evbarm/conf/ldscript.evbarm:1.6 src/sys/arch/evbarm/conf/ldscript.evbarm:1.7
--- src/sys/arch/evbarm/conf/ldscript.evbarm:1.6	Sun Mar  6 02:22:27 2011
+++ src/sys/arch/evbarm/conf/ldscript.evbarm	Tue Dec 24 17:00:39 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: ldscript.evbarm,v 1.6 2011/03/06 02:22:27 jakllsch Exp $	*/
+/*	$NetBSD: ldscript.evbarm,v 1.7 2013/12/24 17:00:39 matt Exp $	*/
 
 OUTPUT_ARCH(arm)
 ENTRY(KERNEL_BASE_phys)
@@ -42,6 +42,7 @@ SECTIONS
 *(.sdata)
 *(.sdata.*)
   }
+  . = ALIGN(8);
   _edata = .;
   PROVIDE (edata = .);
   __bss_start = .;



CVS commit: src/sys/arch/arm/conf

2013-12-24 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Dec 24 17:03:07 UTC 2013

Modified Files:
src/sys/arch/arm/conf: kern.ldscript.tail

Log Message:
Make sure _edata is aligned to a 8-byte boundary.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/conf/kern.ldscript.tail

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/arm/conf/kern.ldscript.tail
diff -u src/sys/arch/arm/conf/kern.ldscript.tail:1.2 src/sys/arch/arm/conf/kern.ldscript.tail:1.3
--- src/sys/arch/arm/conf/kern.ldscript.tail:1.2	Sun Dec 11 12:16:45 2005
+++ src/sys/arch/arm/conf/kern.ldscript.tail	Tue Dec 24 17:03:07 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: kern.ldscript.tail,v 1.2 2005/12/11 12:16:45 christos Exp $	*/
+/*	$NetBSD: kern.ldscript.tail,v 1.3 2013/12/24 17:03:07 matt Exp $	*/
 
   } =0
   PROVIDE (__etext = .);
@@ -13,6 +13,7 @@
 *(.sdata)
 *(.sdata.*)
   }
+  . = ALIGN(8);
   _edata = .;
   PROVIDE (edata = .);
   __bss_start = .;



CVS commit: src/sys/arch/i386/stand/lib

2013-12-24 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Tue Dec 24 19:00:56 UTC 2013

Modified Files:
src/sys/arch/i386/stand/lib: realprot.S

Log Message:
Obtain CR0_PE constant from x86/specialreg.h rather than a local #define.


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/i386/stand/lib/realprot.S

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

Modified files:

Index: src/sys/arch/i386/stand/lib/realprot.S
diff -u src/sys/arch/i386/stand/lib/realprot.S:1.10 src/sys/arch/i386/stand/lib/realprot.S:1.11
--- src/sys/arch/i386/stand/lib/realprot.S:1.10	Sun Dec 19 17:18:23 2010
+++ src/sys/arch/i386/stand/lib/realprot.S	Tue Dec 24 19:00:56 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: realprot.S,v 1.10 2010/12/19 17:18:23 jakllsch Exp $	*/
+/*	$NetBSD: realprot.S,v 1.11 2013/12/24 19:00:56 jakllsch Exp $	*/
 
 /*-
  * Copyright (c) 2003 The NetBSD Foundation, Inc.
@@ -34,8 +34,7 @@
  */
 
 #include machine/asm.h
-
-#define	CR0_PE		1
+#include x86/specialreg.h
 
 	.text
 	.align  16



CVS commit: src/doc

2013-12-24 Thread Valeriy E. Ushakov
Module Name:src
Committed By:   uwe
Date:   Tue Dec 24 20:10:29 UTC 2013

Modified Files:
src/doc: BUILDING.mdoc

Log Message:
Add missing Ar


To generate a diff of this commit:
cvs rdiff -u -r1.94 -r1.95 src/doc/BUILDING.mdoc

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

Modified files:

Index: src/doc/BUILDING.mdoc
diff -u src/doc/BUILDING.mdoc:1.94 src/doc/BUILDING.mdoc:1.95
--- src/doc/BUILDING.mdoc:1.94	Wed May 29 14:45:55 2013
+++ src/doc/BUILDING.mdoc	Tue Dec 24 20:10:29 2013
@@ -1,4 +1,4 @@
-.\	$NetBSD: BUILDING.mdoc,v 1.94 2013/05/29 14:45:55 wiz Exp $
+.\	$NetBSD: BUILDING.mdoc,v 1.95 2013/12/24 20:10:29 uwe Exp $
 .\
 .\ Copyright (c) 2001-2011 The NetBSD Foundation, Inc.
 .\ All rights reserved.
@@ -1574,7 +1574,7 @@ to
 Unsets
 .Sy MAKEOBJDIR .
 See
-.Dq Fl O obj
+.Dq Fl O Ar obj
 for more information.
 .Pp
 For instance, if the source directory is



CVS commit: src/sys/lib/libsa

2013-12-24 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Tue Dec 24 21:41:49 UTC 2013

Modified Files:
src/sys/lib/libsa: subr_prf.c

Log Message:
Add 'j' format modifier for intmax_t.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/lib/libsa/subr_prf.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/lib/libsa/subr_prf.c
diff -u src/sys/lib/libsa/subr_prf.c:1.21 src/sys/lib/libsa/subr_prf.c:1.22
--- src/sys/lib/libsa/subr_prf.c:1.21	Sun Jul 17 20:54:52 2011
+++ src/sys/lib/libsa/subr_prf.c	Tue Dec 24 21:41:49 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: subr_prf.c,v 1.21 2011/07/17 20:54:52 joerg Exp $	*/
+/*	$NetBSD: subr_prf.c,v 1.22 2013/12/24 21:41:49 jakllsch Exp $	*/
 
 /*-
  * Copyright (c) 1993
@@ -213,6 +213,10 @@ reswitch:
 #endif
 lflag |= LONG;
 			goto reswitch;
+		case 'j':
+			if (sizeof(intmax_t) == sizeof(long))
+lflag |= LONG;
+			goto reswitch;
 		case 't':
 			if (sizeof(PTRDIFF_T) == sizeof(long))
 lflag |= LONG;



CVS commit: src/sys/arch/evbarm/bcm53xx

2013-12-24 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Dec 24 21:59:59 UTC 2013

Modified Files:
src/sys/arch/evbarm/bcm53xx: bcm53xx_start.S

Log Message:
Use the right BCM563XX symbol


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/evbarm/bcm53xx/bcm53xx_start.S

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

Modified files:

Index: src/sys/arch/evbarm/bcm53xx/bcm53xx_start.S
diff -u src/sys/arch/evbarm/bcm53xx/bcm53xx_start.S:1.8 src/sys/arch/evbarm/bcm53xx/bcm53xx_start.S:1.9
--- src/sys/arch/evbarm/bcm53xx/bcm53xx_start.S:1.8	Mon Oct 28 22:35:07 2013
+++ src/sys/arch/evbarm/bcm53xx/bcm53xx_start.S	Tue Dec 24 21:59:59 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm53xx_start.S,v 1.8 2013/10/28 22:35:07 matt Exp $	*/
+/*	$NetBSD: bcm53xx_start.S,v 1.9 2013/12/24 21:59:59 matt Exp $	*/
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -45,7 +45,7 @@
 #define	CONADDR		0x18000300
 #endif
 
-RCSID($NetBSD: bcm53xx_start.S,v 1.8 2013/10/28 22:35:07 matt Exp $)
+RCSID($NetBSD: bcm53xx_start.S,v 1.9 2013/12/24 21:59:59 matt Exp $)
 
 #undef VERBOSE_INIT_ARM
 #define VERBOSE_INIT_ARM
@@ -176,7 +176,7 @@ mmu_init_table:
 #ifdef BCM5301X
 	MMU_INIT(KERNEL_BASE, 0x8000, 128,
 	L1_S_PROTO | L1_S_APv7_KRW | L1_S_B | L1_S_C | L1_S_V6_S)
-#elif defined(BCM56340)
+#elif defined(BCM563XX)
 	MMU_INIT(KERNEL_BASE, 0x6000, 128,
 	L1_S_PROTO | L1_S_APv7_KRW | L1_S_B | L1_S_C | L1_S_V6_S)
 #endif



CVS commit: src/sys/dev/dm

2013-12-24 Thread Michael van Elst
Module Name:src
Committed By:   mlelstv
Date:   Tue Dec 24 22:14:07 UTC 2013

Modified Files:
src/sys/dev/dm: dm_ioctl.c

Log Message:
release proplib iterator in failure paths.


To generate a diff of this commit:
cvs rdiff -u -r1.27 -r1.28 src/sys/dev/dm/dm_ioctl.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/dm/dm_ioctl.c
diff -u src/sys/dev/dm/dm_ioctl.c:1.27 src/sys/dev/dm/dm_ioctl.c:1.28
--- src/sys/dev/dm/dm_ioctl.c:1.27	Fri Oct 18 19:56:30 2013
+++ src/sys/dev/dm/dm_ioctl.c	Tue Dec 24 22:14:07 2013
@@ -1,4 +1,4 @@
-/* $NetBSD: dm_ioctl.c,v 1.27 2013/10/18 19:56:30 christos Exp $  */
+/* $NetBSD: dm_ioctl.c,v 1.28 2013/12/24 22:14:07 mlelstv Exp $  */
 
 /*
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -712,6 +712,7 @@ dm_table_load_ioctl(prop_dictionary_t dm
 
 	if ((dmv = dm_dev_lookup(name, uuid, minor)) == NULL) {
 		DM_REMOVE_FLAG(flags, DM_EXISTS_FLAG);
+		prop_object_iterator_release(iter);
 		return ENOENT;
 	}
 	aprint_debug(Loading table to device: %s--%d\n, name,
@@ -743,12 +744,14 @@ dm_table_load_ioctl(prop_dictionary_t dm
 		((target = dm_target_autoload(type)) == NULL)) {
 			dm_table_release(dmv-table_head, DM_TABLE_INACTIVE);
 			dm_dev_unbusy(dmv);
+			prop_object_iterator_release(iter);
 			return ENOENT;
 		}
 		if ((table_en = kmem_alloc(sizeof(dm_table_entry_t),
 			KM_SLEEP)) == NULL) {
 			dm_table_release(dmv-table_head, DM_TABLE_INACTIVE);
 			dm_dev_unbusy(dmv);
+			prop_object_iterator_release(iter);
 			return ENOMEM;
 		}
 		prop_dictionary_get_uint64(target_dict, DM_TABLE_START,
@@ -791,6 +794,7 @@ dm_table_load_ioctl(prop_dictionary_t dm
 
 			dm_dev_unbusy(dmv);
 			dm_target_unbusy(target);
+			prop_object_iterator_release(iter);
 			return ret;
 		}
 		last_table = table_en;



CVS commit: src/sys/lib/libsa

2013-12-24 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Tue Dec 24 22:26:21 UTC 2013

Modified Files:
src/sys/lib/libsa: subr_prf.c

Log Message:
intmax_t might be long long, handle accordingly. from christos


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/sys/lib/libsa/subr_prf.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/lib/libsa/subr_prf.c
diff -u src/sys/lib/libsa/subr_prf.c:1.22 src/sys/lib/libsa/subr_prf.c:1.23
--- src/sys/lib/libsa/subr_prf.c:1.22	Tue Dec 24 21:41:49 2013
+++ src/sys/lib/libsa/subr_prf.c	Tue Dec 24 22:26:21 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: subr_prf.c,v 1.22 2013/12/24 21:41:49 jakllsch Exp $	*/
+/*	$NetBSD: subr_prf.c,v 1.23 2013/12/24 22:26:21 jakllsch Exp $	*/
 
 /*-
  * Copyright (c) 1993
@@ -214,6 +214,11 @@ reswitch:
 lflag |= LONG;
 			goto reswitch;
 		case 'j':
+#ifdef LIBSA_PRINTF_LONGLONG_SUPPORT
+			if (sizeof(intmax_t) == sizeof(long long))
+lflag |= LLONG;
+			else
+#endif
 			if (sizeof(intmax_t) == sizeof(long))
 lflag |= LONG;
 			goto reswitch;



CVS commit: src/lib/libc/sys

2013-12-24 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Tue Dec 24 22:31:11 UTC 2013

Modified Files:
src/lib/libc/sys: dup.2

Log Message:
Rewrite for clarity and add an example.


To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/lib/libc/sys/dup.2

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/sys/dup.2
diff -u src/lib/libc/sys/dup.2:1.28 src/lib/libc/sys/dup.2:1.29
--- src/lib/libc/sys/dup.2:1.28	Wed Jan 25 00:28:35 2012
+++ src/lib/libc/sys/dup.2	Tue Dec 24 22:31:11 2013
@@ -1,4 +1,4 @@
-.\	$NetBSD: dup.2,v 1.28 2012/01/25 00:28:35 christos Exp $
+.\	$NetBSD: dup.2,v 1.29 2013/12/24 22:31:11 dholland Exp $
 .\
 .\ Copyright (c) 1980, 1991, 1993
 .\	The Regents of the University of California.  All rights reserved.
@@ -29,7 +29,7 @@
 .\
 .\ @(#)dup.2	8.1 (Berkeley) 6/4/93
 .\
-.Dd January 23, 2012
+.Dd December 24, 2013
 .Dt DUP 2
 .Os
 .Sh NAME
@@ -42,129 +42,190 @@
 .Sh SYNOPSIS
 .In unistd.h
 .Ft int
-.Fn dup int oldd
+.Fn dup int oldfd
 .Ft int
-.Fn dup2 int oldd int newd
+.Fn dup2 int oldfd int newfd
 .Ft int
-.Fn dup3 int oldd int newd int flags
+.Fn dup3 int oldfd int newfd int flags
 .Sh DESCRIPTION
+The
 .Fn dup
-duplicates an existing object descriptor and returns its value to
-the calling process
-.Fa ( newd
-=
-.Fn dup oldd ) .
-The argument
-.Fa oldd
-is a small non-negative integer index in
-the per-process descriptor table.
-The value must be less than the size of the table, which is returned by
-.Xr getdtablesize 3 .
-The new descriptor returned by the call
-is the lowest numbered descriptor currently not in use by the process.
-.Pp
-The object referenced by the descriptor does not distinguish
-between
-.Fa oldd
-and
-.Fa newd
-in any way.
-Thus if
-.Fa newd
-and
-.Fa oldd
-are duplicate references to an open
-file,
+family of calls duplicates an existing file descriptor
+.Fa oldfd .
+A new file descriptor is produced; it is a new reference to the same
+underlying system object.
+The object in question does not distinguish between the descriptors
+referencing it in any way.
+Thus for files,
 .Xr read 2 ,
 .Xr write 2
 and
 .Xr lseek 2
-calls all move a single pointer into the file,
-and append mode, non-blocking I/O and asynchronous I/O options
-are shared between the references.
-If a separate pointer into the file is desired, a different
-object reference to the file must be obtained by issuing an
-additional
+calls all move a single shared seek position.
+Similarly, all object modes, settings, properties, and behavior other
+than the close-on-exec flag are shared between references.
+This includes the setting of append mode, non-blocking I/O actions,
+asynchronous I/O operations in progress, socket options, and so forth.
+The close-on-exec flag, however, is a property of the descriptor
+rather than the object and can be set independently for each
+reference.
+.Pp
+To get an independent handle with its own seek position and settings,
+an additional
 .Xr open 2
-call.
-The close-on-exec flag on the new file descriptor is unset.
+call must be issued.
+.Pq This is not generally possible for pipes and sockets.
 .Pp
-In
-.Fn dup2 ,
-the value of the new descriptor
-.Fa newd
-is specified.
-If this descriptor is already
-in use, the descriptor is first deallocated as if a
-.Xr close 2
-call had been done first.
+The
+.Nm dup
+call chooses the new descriptor: it is the lowest-numbered descriptor
+not currently in use.
+The
+.Nm dup2
+and
+.Nm dup3
+calls allow the caller to choose the new descriptor by passing
+.Fa newfd ,
+which must be within the range of valid descriptors.
 If
-.Fa newd
+.Fa newfd
+is the same as
+.Fa oldfd ,
+the call has no effect.
+Otherwise, if
+.Fa newfd
+is already in use, it is closed as if
+.Xr close 2
+had been called.
+.Pp
+File descriptors are small non-negative integers that index into the
+per-process file table.
+Values 0, 1, and 2 have the special property that they are treated as
+standard input, standard output, and standard error respectively.
+(The constants
+.Dv STDIN_FILENO ,
+.Dv STDOUT_FILENO ,
 and
-.Fa oldd
-are the same, the call has no effect.
+.Dv STDERR_FILENO
+are provided as symbolic forms for these values.)
+The maximum value for a file descriptor is one less than the file
+table size.
+The file table size can be interrogated with
+.Xr getdtablesize 3
+and can to some extent be adjusted with
+.Xr setrlimit 2 .
 .Pp
+The
 .Fn dup3
-behaves exactly like
-.Fn dup2
-only it allows extra
+call includs an additional
 .Fa flags
-to be set on the returned file descriptor.
-The following flags are valid:
-.Bl -tag -width O_NONBLOCK -offset indent
+argument supporting a subset of the
+.Xr open 2
+flags:
+.Bl -tag -width O_NOSIGPIPE -offset indent
 .It Dv O_CLOEXEC
-Set the
-.Dq close-on-exec
-property.
+Set the close-on-exec flag on
+.Fa newfd .
 .It Dv O_NONBLOCK
 Sets non-blocking I/O.
 .It Dv O_NOSIGPIPE
-Return

CVS commit: src/lib/libc/sys

2013-12-24 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Wed Dec 25 02:49:52 UTC 2013

Modified Files:
src/lib/libc/sys: dup.2

Log Message:
Sort errors. Use parentheses instead of Pq in normal text.


To generate a diff of this commit:
cvs rdiff -u -r1.29 -r1.30 src/lib/libc/sys/dup.2

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/sys/dup.2
diff -u src/lib/libc/sys/dup.2:1.29 src/lib/libc/sys/dup.2:1.30
--- src/lib/libc/sys/dup.2:1.29	Tue Dec 24 22:31:11 2013
+++ src/lib/libc/sys/dup.2	Wed Dec 25 02:49:52 2013
@@ -1,4 +1,4 @@
-.\	$NetBSD: dup.2,v 1.29 2013/12/24 22:31:11 dholland Exp $
+.\	$NetBSD: dup.2,v 1.30 2013/12/25 02:49:52 wiz Exp $
 .\
 .\ Copyright (c) 1980, 1991, 1993
 .\	The Regents of the University of California.  All rights reserved.
@@ -74,7 +74,7 @@ To get an independent handle with its ow
 an additional
 .Xr open 2
 call must be issued.
-.Pq This is not generally possible for pipes and sockets.
+(This is not generally possible for pipes and sockets.)
 .Pp
 The
 .Nm dup
@@ -206,17 +206,17 @@ and
 .Fn dup3 ,
 .Fa newfd
 is not in the range of valid file descriptors.
-.It Bq Er EMFILE
-Too many descriptors are active.
-Only
-.Fn dup
-can generate this error.
 .It Bq Er EINVAL
 .Fa flags
 contained an invalid value.
 Only
 .Fn dup3
 can generate this error.
+.It Bq Er EMFILE
+Too many descriptors are active.
+Only
+.Fn dup
+can generate this error.
 .El
 .Sh SEE ALSO
 .Xr accept 2 ,



CVS commit: src/lib/libc/sys

2013-12-24 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Wed Dec 25 00:58:50 UTC 2013

Modified Files:
src/lib/libc/sys: nanosleep.2

Log Message:
typo


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/lib/libc/sys/nanosleep.2

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/sys/nanosleep.2
diff -u src/lib/libc/sys/nanosleep.2:1.13 src/lib/libc/sys/nanosleep.2:1.14
--- src/lib/libc/sys/nanosleep.2:1.13	Mon Oct  8 18:08:40 2012
+++ src/lib/libc/sys/nanosleep.2	Wed Dec 25 00:58:50 2013
@@ -1,4 +1,4 @@
-.\	$NetBSD: nanosleep.2,v 1.13 2012/10/08 18:08:40 njoly Exp $
+.\	$NetBSD: nanosleep.2,v 1.14 2013/12/25 00:58:50 dholland Exp $
 .\
 .\ Copyright (c) 1986, 1991, 1993
 .\	The Regents of the University of California.  All rights reserved.
@@ -112,7 +112,7 @@ If the
 or the
 .Fn nanosleep
 functions return due to the delivery of a signal, the value returned
-will be the \-1, and the global variable
+will be \-1, and the global variable
 .Va errno
 will be set to indicate the interruption.
 If