CVS commit: src/sys/dev

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 14:20:03 UTC 2013

Modified Files:
src/sys/dev/cardbus: if_athn_cardbus.c
src/sys/dev/ic: aic79xx_inline.h aic79xx_osm.h arn5008.c arn5416.c
arn9003.c arn9280.c arn9285.c arn9287.c arn9380.c athnvar.h
src/sys/dev/pci: if_athn_pci.c

Log Message:
instead of ifnet use ethercom.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/dev/cardbus/if_athn_cardbus.c
cvs rdiff -u -r1.19 -r1.20 src/sys/dev/ic/aic79xx_inline.h
cvs rdiff -u -r1.21 -r1.22 src/sys/dev/ic/aic79xx_osm.h
cvs rdiff -u -r1.1 -r1.2 src/sys/dev/ic/arn5008.c src/sys/dev/ic/arn5416.c \
src/sys/dev/ic/arn9003.c src/sys/dev/ic/arn9280.c \
src/sys/dev/ic/arn9285.c src/sys/dev/ic/arn9287.c \
src/sys/dev/ic/arn9380.c
cvs rdiff -u -r1.2 -r1.3 src/sys/dev/ic/athnvar.h
cvs rdiff -u -r1.4 -r1.5 src/sys/dev/pci/if_athn_pci.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/cardbus/if_athn_cardbus.c
diff -u src/sys/dev/cardbus/if_athn_cardbus.c:1.1 src/sys/dev/cardbus/if_athn_cardbus.c:1.2
--- src/sys/dev/cardbus/if_athn_cardbus.c:1.1	Fri Mar 29 22:53:00 2013
+++ src/sys/dev/cardbus/if_athn_cardbus.c	Wed Apr  3 10:20:02 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_athn_cardbus.c,v 1.1 2013/03/30 02:53:00 christos Exp $	*/
+/*	$NetBSD: if_athn_cardbus.c,v 1.2 2013/04/03 14:20:02 christos Exp $	*/
 /*	$OpenBSD: if_athn_cardbus.c,v 1.13 2011/01/08 10:02:32 damien Exp $	*/
 
 /*-
@@ -22,7 +22,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_athn_cardbus.c,v 1.1 2013/03/30 02:53:00 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_athn_cardbus.c,v 1.2 2013/04/03 14:20:02 christos Exp $");
 
 #include "opt_inet.h"
 
@@ -40,6 +40,7 @@ __KERNEL_RCSID(0, "$NetBSD: if_athn_card
 #include 
 
 #include 
+#include 
 #include 
 
 #include 

Index: src/sys/dev/ic/aic79xx_inline.h
diff -u src/sys/dev/ic/aic79xx_inline.h:1.19 src/sys/dev/ic/aic79xx_inline.h:1.20
--- src/sys/dev/ic/aic79xx_inline.h:1.19	Sat Sep  5 08:39:25 2009
+++ src/sys/dev/ic/aic79xx_inline.h	Wed Apr  3 10:20:02 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic79xx_inline.h,v 1.19 2009/09/05 12:39:25 tsutsui Exp $	*/
+/*	$NetBSD: aic79xx_inline.h,v 1.20 2013/04/03 14:20:02 christos Exp $	*/
 
 /*
  * Inline routines shareable across OS platforms.
@@ -854,7 +854,7 @@ ahd_check_cmdcmpltqueues(struct ahd_soft
 	u_int retval;
 
 	retval = 0;
-	ahd_dmamap_sync(ahd, ahd->parent_dmat /*shared_data_dmat*/, ahd->shared_data_map.dmamap,
+	ahd_dmamap_sync1(ahd, ahd->parent_dmat /*shared_data_dmat*/, ahd->shared_data_map.dmamap,
 			/*offset*/ahd->qoutfifonext, /*len*/2,
 			BUS_DMASYNC_POSTREAD);
 	if ((ahd->qoutfifo[ahd->qoutfifonext]

Index: src/sys/dev/ic/aic79xx_osm.h
diff -u src/sys/dev/ic/aic79xx_osm.h:1.21 src/sys/dev/ic/aic79xx_osm.h:1.22
--- src/sys/dev/ic/aic79xx_osm.h:1.21	Sat Nov 13 08:52:00 2010
+++ src/sys/dev/ic/aic79xx_osm.h	Wed Apr  3 10:20:02 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic79xx_osm.h,v 1.21 2010/11/13 13:52:00 uebayasi Exp $	*/
+/*	$NetBSD: aic79xx_osm.h,v 1.22 2013/04/03 14:20:02 christos Exp $	*/
 
 /*
  * NetBSD platform specific driver option settings, data structures,
@@ -32,9 +32,9 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $NetBSD: aic79xx_osm.h,v 1.21 2010/11/13 13:52:00 uebayasi Exp $
+ * $NetBSD: aic79xx_osm.h,v 1.22 2013/04/03 14:20:02 christos Exp $
  *
- * //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#19 $$NetBSD: aic79xx_osm.h,v 1.21 2010/11/13 13:52:00 uebayasi Exp $
+ * //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#19 $$NetBSD: aic79xx_osm.h,v 1.22 2013/04/03 14:20:02 christos Exp $
  *
  * $FreeBSD: src/sys/dev/aic7xxx/aic79xx_osm.h,v 1.9 2003/05/26 21:43:29 gibbs Exp $
  */
@@ -129,8 +129,28 @@ typedef pcireg_t ahd_dev_softc_t;
 	bus_dmamap_unload(tag, map)
 
 /* XXX Need to update Bus DMA for partial map syncs */
-#define ahd_dmamap_sync(ahd, dma_tag, dmamap, offset, len, op)		\
-	bus_dmamap_sync(dma_tag, dmamap, offset, len, op)
+#define ahd_dmamap_sync(ahd, dma_tag, dmamap, offset, len, op) 		\
+	do {\
+		if (((op) & (BUS_DMASYNC_PREWRITE|BUS_DMASYNC_POSTREAD)) != 0)\
+		if ((offset) >= (dmamap)->dm_mapsize) {			\
+			printf("%s, %d: %s: %x >= %x[%x]\n", __FILE__,	\
+			__LINE__, __func__, (int)(offset),		\
+			(int)(dmamap)->dm_mapsize, (int)(len));	\
+			return;		\
+		}			\
+		bus_dmamap_sync(dma_tag, dmamap, offset, len, op);	\
+	} while (/*CONSTCOND*/0)
+#define ahd_dmamap_sync1(ahd, dma_tag, dmamap, offset, len, op)		\
+	do {\
+		if (((op) & (BUS_DMASYNC_PREWRITE|BUS_DMASYNC_POSTREAD)) != 0)\
+		if ((offset) >= (dmamap)->dm_mapsize) {			\
+			printf("%s, %d: %s: %x >= %x[%x]\n", __FILE__,	\
+			__LINE__, __func__, (int)(offset),		\
+			(int)(dmamap)->dm_mapsize, (int)(len));	\
+			return 0;	\
+		}			\
+		bus_dmamap_sync(dma_tag, dmam

CVS commit: src/sys/dev/usb

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 14:20:18 UTC 2013

Modified Files:
src/sys/dev/usb: if_athn_usb.c

Log Message:
fix memory leak


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/dev/usb/if_athn_usb.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/usb/if_athn_usb.c
diff -u src/sys/dev/usb/if_athn_usb.c:1.4 src/sys/dev/usb/if_athn_usb.c:1.5
--- src/sys/dev/usb/if_athn_usb.c:1.4	Sat Mar 30 10:30:24 2013
+++ src/sys/dev/usb/if_athn_usb.c	Wed Apr  3 10:20:18 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_athn_usb.c,v 1.4 2013/03/30 14:30:24 christos Exp $	*/
+/*	$NetBSD: if_athn_usb.c,v 1.5 2013/04/03 14:20:18 christos Exp $	*/
 /*	$OpenBSD: if_athn_usb.c,v 1.12 2013/01/14 09:50:31 jsing Exp $	*/
 
 /*-
@@ -22,7 +22,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.4 2013/03/30 14:30:24 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.5 2013/04/03 14:20:18 christos Exp $");
 
 #ifdef	_KERNEL_OPT
 #include "opt_inet.h"
@@ -2441,13 +2441,13 @@ athn_usb_start(struct ifnet *ifp)
 		bpf_mtap3(ic->ic_rawbpf, m);
 
 		if (athn_usb_tx(sc, m, ni, data) != 0) {
-			m_free(m);
+			m_freem(m);
 			ieee80211_free_node(ni);
 			ifp->if_oerrors++;
 			continue;
 		}
 		data = NULL;
-		m_free(m);
+		m_freem(m);
 		ieee80211_free_node(ni);
 		sc->sc_tx_timer = 5;
 		ifp->if_timer = 1;



CVS commit: src/sys/dev/ic

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 14:40:41 UTC 2013

Modified Files:
src/sys/dev/ic: aic79xx_inline.h aic79xx_osm.h

Log Message:
undo previous commit of unrelated debugging.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/dev/ic/aic79xx_inline.h
cvs rdiff -u -r1.22 -r1.23 src/sys/dev/ic/aic79xx_osm.h

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

Modified files:

Index: src/sys/dev/ic/aic79xx_inline.h
diff -u src/sys/dev/ic/aic79xx_inline.h:1.20 src/sys/dev/ic/aic79xx_inline.h:1.21
--- src/sys/dev/ic/aic79xx_inline.h:1.20	Wed Apr  3 10:20:02 2013
+++ src/sys/dev/ic/aic79xx_inline.h	Wed Apr  3 10:40:41 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic79xx_inline.h,v 1.20 2013/04/03 14:20:02 christos Exp $	*/
+/*	$NetBSD: aic79xx_inline.h,v 1.21 2013/04/03 14:40:41 christos Exp $	*/
 
 /*
  * Inline routines shareable across OS platforms.
@@ -854,7 +854,7 @@ ahd_check_cmdcmpltqueues(struct ahd_soft
 	u_int retval;
 
 	retval = 0;
-	ahd_dmamap_sync1(ahd, ahd->parent_dmat /*shared_data_dmat*/, ahd->shared_data_map.dmamap,
+	ahd_dmamap_sync(ahd, ahd->parent_dmat /*shared_data_dmat*/, ahd->shared_data_map.dmamap,
 			/*offset*/ahd->qoutfifonext, /*len*/2,
 			BUS_DMASYNC_POSTREAD);
 	if ((ahd->qoutfifo[ahd->qoutfifonext]

Index: src/sys/dev/ic/aic79xx_osm.h
diff -u src/sys/dev/ic/aic79xx_osm.h:1.22 src/sys/dev/ic/aic79xx_osm.h:1.23
--- src/sys/dev/ic/aic79xx_osm.h:1.22	Wed Apr  3 10:20:02 2013
+++ src/sys/dev/ic/aic79xx_osm.h	Wed Apr  3 10:40:41 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic79xx_osm.h,v 1.22 2013/04/03 14:20:02 christos Exp $	*/
+/*	$NetBSD: aic79xx_osm.h,v 1.23 2013/04/03 14:40:41 christos Exp $	*/
 
 /*
  * NetBSD platform specific driver option settings, data structures,
@@ -32,9 +32,9 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $NetBSD: aic79xx_osm.h,v 1.22 2013/04/03 14:20:02 christos Exp $
+ * $NetBSD: aic79xx_osm.h,v 1.23 2013/04/03 14:40:41 christos Exp $
  *
- * //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#19 $$NetBSD: aic79xx_osm.h,v 1.22 2013/04/03 14:20:02 christos Exp $
+ * //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#19 $$NetBSD: aic79xx_osm.h,v 1.23 2013/04/03 14:40:41 christos Exp $
  *
  * $FreeBSD: src/sys/dev/aic7xxx/aic79xx_osm.h,v 1.9 2003/05/26 21:43:29 gibbs Exp $
  */
@@ -129,28 +129,8 @@ typedef pcireg_t ahd_dev_softc_t;
 	bus_dmamap_unload(tag, map)
 
 /* XXX Need to update Bus DMA for partial map syncs */
-#define ahd_dmamap_sync(ahd, dma_tag, dmamap, offset, len, op) 		\
-	do {\
-		if (((op) & (BUS_DMASYNC_PREWRITE|BUS_DMASYNC_POSTREAD)) != 0)\
-		if ((offset) >= (dmamap)->dm_mapsize) {			\
-			printf("%s, %d: %s: %x >= %x[%x]\n", __FILE__,	\
-			__LINE__, __func__, (int)(offset),		\
-			(int)(dmamap)->dm_mapsize, (int)(len));	\
-			return;		\
-		}			\
-		bus_dmamap_sync(dma_tag, dmamap, offset, len, op);	\
-	} while (/*CONSTCOND*/0)
-#define ahd_dmamap_sync1(ahd, dma_tag, dmamap, offset, len, op)		\
-	do {\
-		if (((op) & (BUS_DMASYNC_PREWRITE|BUS_DMASYNC_POSTREAD)) != 0)\
-		if ((offset) >= (dmamap)->dm_mapsize) {			\
-			printf("%s, %d: %s: %x >= %x[%x]\n", __FILE__,	\
-			__LINE__, __func__, (int)(offset),		\
-			(int)(dmamap)->dm_mapsize, (int)(len));	\
-			return 0;	\
-		}			\
-		bus_dmamap_sync(dma_tag, dmamap, offset, len, op);	\
-	} while (/*CONSTCOND*/0)
+#define ahd_dmamap_sync(ahd, dma_tag, dmamap, offset, len, op)		\
+	bus_dmamap_sync(dma_tag, dmamap, offset, len, op)
 
 / Tunable Driver Parameters  **/
 /*



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

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 14:46:57 UTC 2013

Update of /cvsroot/src/external/bsd/mdocml/dist
In directory ivanova.netbsd.org:/tmp/cvs-serv4396

Log Message:
import latest

Status:

Vendor Tag: KRISTAPS
Release Tags:   mdocml-1-12-1

U src/external/bsd/mdocml/dist/apropos.1
U src/external/bsd/mdocml/dist/Makefile
N src/external/bsd/mdocml/dist/TODO
U src/external/bsd/mdocml/dist/compat_fgetln.c
U src/external/bsd/mdocml/dist/apropos.c
U src/external/bsd/mdocml/dist/apropos_db.c
U src/external/bsd/mdocml/dist/apropos_db.h
U src/external/bsd/mdocml/dist/arch.c
U src/external/bsd/mdocml/dist/arch.in
U src/external/bsd/mdocml/dist/att.c
U src/external/bsd/mdocml/dist/att.in
U src/external/bsd/mdocml/dist/catman.8
U src/external/bsd/mdocml/dist/catman.c
U src/external/bsd/mdocml/dist/cgi.c
U src/external/bsd/mdocml/dist/chars.c
U src/external/bsd/mdocml/dist/chars.in
U src/external/bsd/mdocml/dist/example.style.css
U src/external/bsd/mdocml/dist/compat_getsubopt.c
U src/external/bsd/mdocml/dist/compat_strlcat.c
U src/external/bsd/mdocml/dist/compat_strlcpy.c
U src/external/bsd/mdocml/dist/config.h.post
U src/external/bsd/mdocml/dist/config.h.pre
U src/external/bsd/mdocml/dist/demandoc.1
U src/external/bsd/mdocml/dist/demandoc.c
U src/external/bsd/mdocml/dist/eqn.7
U src/external/bsd/mdocml/dist/eqn.c
U src/external/bsd/mdocml/dist/eqn_html.c
U src/external/bsd/mdocml/dist/eqn_term.c
U src/external/bsd/mdocml/dist/man_validate.c
U src/external/bsd/mdocml/dist/html.c
U src/external/bsd/mdocml/dist/html.h
U src/external/bsd/mdocml/dist/external.png.uu
U src/external/bsd/mdocml/dist/lib.c
U src/external/bsd/mdocml/dist/lib.in
U src/external/bsd/mdocml/dist/libman.h
U src/external/bsd/mdocml/dist/libmandoc.h
U src/external/bsd/mdocml/dist/libmdoc.h
U src/external/bsd/mdocml/dist/libroff.h
U src/external/bsd/mdocml/dist/main.c
U src/external/bsd/mdocml/dist/main.h
U src/external/bsd/mdocml/dist/man.7
U src/external/bsd/mdocml/dist/man.c
U src/external/bsd/mdocml/dist/man.cgi.7
U src/external/bsd/mdocml/dist/man-cgi.css
U src/external/bsd/mdocml/dist/man.h
U src/external/bsd/mdocml/dist/man_hash.c
U src/external/bsd/mdocml/dist/man_html.c
U src/external/bsd/mdocml/dist/man_macro.c
U src/external/bsd/mdocml/dist/man_term.c
U src/external/bsd/mdocml/dist/mandoc_char.7
U src/external/bsd/mdocml/dist/mandoc.1
U src/external/bsd/mdocml/dist/mandoc.3
U src/external/bsd/mdocml/dist/mandoc.c
C src/external/bsd/mdocml/dist/mandoc.h
C src/external/bsd/mdocml/dist/mdoc_validate.c
U src/external/bsd/mdocml/dist/mandocdb.8
U src/external/bsd/mdocml/dist/mandocdb.c
U src/external/bsd/mdocml/dist/mandocdb.h
U src/external/bsd/mdocml/dist/manpath.c
U src/external/bsd/mdocml/dist/manpath.h
U src/external/bsd/mdocml/dist/mdoc.7
U src/external/bsd/mdocml/dist/mdoc.c
U src/external/bsd/mdocml/dist/mdoc.h
C src/external/bsd/mdocml/dist/mdoc_argv.c
U src/external/bsd/mdocml/dist/mdoc_hash.c
U src/external/bsd/mdocml/dist/mdoc_html.c
U src/external/bsd/mdocml/dist/mdoc_macro.c
U src/external/bsd/mdocml/dist/mdoc_man.c
U src/external/bsd/mdocml/dist/mdoc_term.c
U src/external/bsd/mdocml/dist/test-fgetln.c
U src/external/bsd/mdocml/dist/msec.c
U src/external/bsd/mdocml/dist/msec.in
U src/external/bsd/mdocml/dist/out.c
U src/external/bsd/mdocml/dist/out.h
U src/external/bsd/mdocml/dist/preconv.1
U src/external/bsd/mdocml/dist/preconv.c
U src/external/bsd/mdocml/dist/predefs.in
C src/external/bsd/mdocml/dist/read.c
U src/external/bsd/mdocml/dist/roff.7
U src/external/bsd/mdocml/dist/roff.c
U src/external/bsd/mdocml/dist/st.c
U src/external/bsd/mdocml/dist/st.in
U src/external/bsd/mdocml/dist/tbl.7
U src/external/bsd/mdocml/dist/tbl.c
U src/external/bsd/mdocml/dist/tbl_data.c
U src/external/bsd/mdocml/dist/tbl_html.c
U src/external/bsd/mdocml/dist/tbl_layout.c
U src/external/bsd/mdocml/dist/tbl_opts.c
U src/external/bsd/mdocml/dist/tbl_term.c
U src/external/bsd/mdocml/dist/term.c
U src/external/bsd/mdocml/dist/term.h
U src/external/bsd/mdocml/dist/term_ascii.c
U src/external/bsd/mdocml/dist/term_ps.c
U src/external/bsd/mdocml/dist/test-getsubopt.c
U src/external/bsd/mdocml/dist/test-mmap.c
U src/external/bsd/mdocml/dist/test-strlcat.c
U src/external/bsd/mdocml/dist/test-strlcpy.c
U src/external/bsd/mdocml/dist/test-strptime.c
U src/external/bsd/mdocml/dist/tree.c
U src/external/bsd/mdocml/dist/vol.c
U src/external/bsd/mdocml/dist/vol.in
U src/external/bsd/mdocml/dist/whatis.1

4 conflicts created by this import.
Use the following command to help the merge:

cvs checkout -jKRISTAPS:yesterday -jKRISTAPS 
src/external/bsd/mdocml/dist



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

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 14:50:26 UTC 2013

Modified Files:
src/external/bsd/mdocml/dist: mdoc_argv.c mdoc_validate.c

Log Message:
merge diffs


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/mdocml/dist/mdoc_argv.c
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/mdocml/dist/mdoc_validate.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/mdocml/dist/mdoc_argv.c
diff -u src/external/bsd/mdocml/dist/mdoc_argv.c:1.3 src/external/bsd/mdocml/dist/mdoc_argv.c:1.4
--- src/external/bsd/mdocml/dist/mdoc_argv.c:1.3	Tue Oct 11 15:12:13 2011
+++ src/external/bsd/mdocml/dist/mdoc_argv.c	Wed Apr  3 10:50:26 2013
@@ -1,4 +1,4 @@
-/*	$Vendor-Id: mdoc_argv.c,v 1.81 2011/09/18 14:14:15 schwarze Exp $ */
+/*	$Vendor-Id: mdoc_argv.c,v 1.82 2012/03/23 05:50:24 kristaps Exp $ */
 /*
  * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons 
  *
@@ -81,7 +81,7 @@ static	const enum argvflag argvflags[MDO
 	ARGV_NONE,	/* MDOC_Ohang */
 	ARGV_NONE,	/* MDOC_Inset */
 	ARGV_MULTI,	/* MDOC_Column */
-	ARGV_SINGLE,	/* MDOC_Width */
+	ARGV_OPT_SINGLE, /* MDOC_Width */
 	ARGV_NONE,	/* MDOC_Compact */
 	ARGV_NONE,	/* MDOC_Std */
 	ARGV_NONE,	/* MDOC_Filled */

Index: src/external/bsd/mdocml/dist/mdoc_validate.c
diff -u src/external/bsd/mdocml/dist/mdoc_validate.c:1.4 src/external/bsd/mdocml/dist/mdoc_validate.c:1.5
--- src/external/bsd/mdocml/dist/mdoc_validate.c:1.4	Mon Jan 30 12:03:01 2012
+++ src/external/bsd/mdocml/dist/mdoc_validate.c	Wed Apr  3 10:50:26 2013
@@ -1,4 +1,4 @@
-/*	$Vendor-Id: mdoc_validate.c,v 1.181 2011/12/03 16:58:54 schwarze Exp $ */
+/*	$Vendor-Id: mdoc_validate.c,v 1.182 2012/03/23 05:50:25 kristaps Exp $ */
 /*
  * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons 
  * Copyright (c) 2010, 2011 Ingo Schwarze 
@@ -661,8 +661,13 @@ pre_bl(PRE_ARGS)
 			comp = 1;
 			break;
 		case (MDOC_Width):
-			dup = (NULL != n->norm->Bl.width);
-			width = n->args->argv[i].value[0];
+			/* NB: this can be empty! */
+			if (n->args->argv[i].sz) {
+width = n->args->argv[i].value[0];
+dup = (NULL != n->norm->Bl.width);
+break;
+			}
+			mdoc_nmsg(mdoc, n, MANDOCERR_IGNARGV);
 			break;
 		case (MDOC_Offset):
 			/* NB: this can be empty! */



CVS commit: src/external/bsd/mdocml

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 14:51:31 UTC 2013

Modified Files:
src/external/bsd/mdocml: prepare-import.sh

Log Message:
don't assume that what we are going to import lives in dist


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/mdocml/prepare-import.sh

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/mdocml/prepare-import.sh
diff -u src/external/bsd/mdocml/prepare-import.sh:1.4 src/external/bsd/mdocml/prepare-import.sh:1.5
--- src/external/bsd/mdocml/prepare-import.sh:1.4	Wed Jan 12 18:00:51 2011
+++ src/external/bsd/mdocml/prepare-import.sh	Wed Apr  3 10:51:31 2013
@@ -2,7 +2,6 @@
 
 set -e
 
-cd dist
 rm -rf ChangeLog.xsl style.css index.css *.sgml
 
 uuencode external.png < external.png > external.png.uu



CVS commit: src/doc

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 15:19:53 UTC 2013

Modified Files:
src/doc: 3RDPARTY CHANGES

Log Message:
update for mdocml


To generate a diff of this commit:
cvs rdiff -u -r1.1023 -r1.1024 src/doc/3RDPARTY
cvs rdiff -u -r1.1808 -r1.1809 src/doc/CHANGES

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

Modified files:

Index: src/doc/3RDPARTY
diff -u src/doc/3RDPARTY:1.1023 src/doc/3RDPARTY:1.1024
--- src/doc/3RDPARTY:1.1023	Fri Mar 29 14:32:34 2013
+++ src/doc/3RDPARTY	Wed Apr  3 11:19:52 2013
@@ -1,4 +1,4 @@
-#	$NetBSD: 3RDPARTY,v 1.1023 2013/03/29 18:32:34 wiz Exp $
+#	$NetBSD: 3RDPARTY,v 1.1024 2013/04/03 15:19:52 christos Exp $
 #
 # This file contains a list of the software that has been integrated into
 # NetBSD where we are not the primary maintainer.
@@ -762,7 +762,7 @@ Location:	external/apache2/mDNSResponder
 Notes:
 
 Package:	mdocml
-Version:	1.12.0
+Version:	1.12.1
 Current Vers:	1.12.1
 Maintainer:	Kristaps Džonsons
 Archive Site:	http://mdocml.bsd.lv/snapshots/

Index: src/doc/CHANGES
diff -u src/doc/CHANGES:1.1808 src/doc/CHANGES:1.1809
--- src/doc/CHANGES:1.1808	Fri Mar 29 12:21:59 2013
+++ src/doc/CHANGES	Wed Apr  3 11:19:52 2013
@@ -1,4 +1,4 @@
-# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.1808 $>
+# LIST OF CHANGES FROM LAST RELEASE:			<$Revision: 1.1809 $>
 #
 #
 # [Note: This file does not mention every change made to the NetBSD source tree.
@@ -219,3 +219,4 @@ Changes from NetBSD 6.0 to NetBSD 7.0:
 	vcaudio(4): Add support for Broadcom VideoCore IV audio service.
 		[jmcneill 20130325]
 	openssh: Import 6.2. [christos 20120329]
+	mdocml: Import 1.12.1 [christos 20120402]



CVS commit: src/lib/libpthread

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 15:45:21 UTC 2013

Modified Files:
src/lib/libpthread: shlib_version

Log Message:
bump for pthread_cond_setclock


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/lib/libpthread/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/libpthread/shlib_version
diff -u src/lib/libpthread/shlib_version:1.15 src/lib/libpthread/shlib_version:1.16
--- src/lib/libpthread/shlib_version:1.15	Thu Mar  8 16:59:28 2012
+++ src/lib/libpthread/shlib_version	Wed Apr  3 11:45:21 2013
@@ -1,4 +1,4 @@
-#	$NetBSD: shlib_version,v 1.15 2012/03/08 21:59:28 joerg Exp $
+#	$NetBSD: shlib_version,v 1.16 2013/04/03 15:45:21 christos Exp $
 #	Remember to update distrib/sets/lists/base/shl.* when changing
 #
 # Things to do when bumping major version:
@@ -16,4 +16,4 @@
 #	without compat_netbsd32 shims??
 #
 major=1
-minor=1
+minor=2



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

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 15:49:23 UTC 2013

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

Log Message:
remove commented out stuff


To generate a diff of this commit:
cvs rdiff -u -r1.657 -r1.658 src/distrib/sets/lists/base/shl.mi

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

Modified files:

Index: src/distrib/sets/lists/base/shl.mi
diff -u src/distrib/sets/lists/base/shl.mi:1.657 src/distrib/sets/lists/base/shl.mi:1.658
--- src/distrib/sets/lists/base/shl.mi:1.657	Fri Mar 29 17:59:52 2013
+++ src/distrib/sets/lists/base/shl.mi	Wed Apr  3 11:49:23 2013
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.657 2013/03/29 21:59:52 christos Exp $
+# $NetBSD: shl.mi,v 1.658 2013/04/03 15:49:23 christos Exp $
 #
 # Note:	Don't delete entries from here - mark them as "obsolete" instead,
 #	unless otherwise stated below.
@@ -34,9 +34,6 @@
 ./lib/libdevmapper.sobase-lvm-shlib		lvm,dynamicroot
 ./lib/libdevmapper.so.1base-lvm-shlib		lvm,dynamicroot
 ./lib/libdevmapper.so.1.0			base-lvm-shlib		lvm,dynamicroot
-#./lib/libdns.so	base-net-shlib		dynamicroot
-#./lib/libdns.so.6base-net-shlib		dynamicroot
-#./lib/libdns.so.6.0base-net-shlib		dynamicroot
 ./lib/libedit.sobase-sys-shlib		dynamicroot
 ./lib/libedit.so.3base-sys-shlib		dynamicroot
 ./lib/libedit.so.3.1base-sys-shlib		dynamicroot
@@ -49,9 +46,6 @@
 ./lib/libipsec.sobase-net-shlib		dynamicroot
 ./lib/libipsec.so.3base-net-shlib		dynamicroot
 ./lib/libipsec.so.3.0base-net-shlib		dynamicroot
-#./lib/libisc.so	base-net-shlib		dynamicroot
-#./lib/libisc.so.6base-net-shlib		dynamicroot
-#./lib/libisc.so.6.0base-net-shlib		dynamicroot
 ./lib/libkvm.so	base-sys-shlib		dynamicroot
 ./lib/libkvm.so.6base-sys-shlib		dynamicroot
 ./lib/libkvm.so.6.0base-sys-shlib		dynamicroot
@@ -67,18 +61,12 @@
 ./lib/libm.so	base-sys-shlib		dynamicroot
 ./lib/libm.so.0	base-sys-shlib		dynamicroot
 ./lib/libm.so.0.10base-sys-shlib		dynamicroot
-#./lib/libpcap.sobase-net-shlib		dynamicroot
-#./lib/libpcap.so.4base-net-shlib		dynamicroot
-#./lib/libpcap.so.4.0base-net-shlib		dynamicroot
 ./lib/libppath.sobase-sys-shlib		dynamicroot
 ./lib/libppath.so.0base-sys-shlib		dynamicroot
 ./lib/libppath.so.0.0base-sys-shlib		dynamicroot
 ./lib/libprop.sobase-sys-shlib		dynamicroot
 ./lib/libprop.so.1base-sys-shlib		dynamicroot
 ./lib/libprop.so.1.1base-sys-shlib		dynamicroot
-#./lib/libpthread.sobase-sys-shlib		dynamicroot
-#./lib/libpthread.so.1base-sys-shlib		dynamicroot
-#./lib/libpthread.so.1.1base-sys-shlib		dynamicroot
 ./lib/libradius.sobase-sys-shlib		dynamicroot
 ./lib/libradius.so.4base-sys-shlib		dynamicroot
 ./lib/libradius.so.4.0base-sys-shlib		dynamicroot



CVS commit: src/distrib/sets/lists

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 15:50:38 UTC 2013

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

Log Message:
bump libpthread for pthread_cond_setclock


To generate a diff of this commit:
cvs rdiff -u -r1.121 -r1.122 src/distrib/sets/lists/base/ad.mips64eb \
src/distrib/sets/lists/base/ad.mips64el
cvs rdiff -u -r1.199 -r1.200 src/distrib/sets/lists/base/md.amd64
cvs rdiff -u -r1.186 -r1.187 src/distrib/sets/lists/base/md.sparc64
cvs rdiff -u -r1.658 -r1.659 src/distrib/sets/lists/base/shl.mi
cvs rdiff -u -r1.13 -r1.14 src/distrib/sets/lists/debug/ad.mips64eb \
src/distrib/sets/lists/debug/md.amd64
cvs rdiff -u -r1.14 -r1.15 src/distrib/sets/lists/debug/ad.mips64el \
src/distrib/sets/lists/debug/md.sparc64 \
src/distrib/sets/lists/debug/shl.mi

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

Modified files:

Index: src/distrib/sets/lists/base/ad.mips64eb
diff -u src/distrib/sets/lists/base/ad.mips64eb:1.121 src/distrib/sets/lists/base/ad.mips64eb:1.122
--- src/distrib/sets/lists/base/ad.mips64eb:1.121	Fri Mar 29 17:59:51 2013
+++ src/distrib/sets/lists/base/ad.mips64eb	Wed Apr  3 11:50:37 2013
@@ -1,4 +1,4 @@
-# $NetBSD: ad.mips64eb,v 1.121 2013/03/29 21:59:51 christos Exp $
+# $NetBSD: ad.mips64eb,v 1.122 2013/04/03 15:50:37 christos Exp $
 ./lib/64	base-compat-shlib	compat
 ./lib/64/npf	base-npf-shlib		compat
 ./lib/64/npf/ext_log.sobase-npf-shlib		compat,pic
@@ -234,7 +234,7 @@
 ./usr/lib/64/libprop.so.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libprop.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libpthread.so.1			base-compat-shlib	compat,pic
-./usr/lib/64/libpthread.so.1.1			base-compat-shlib	compat,pic
+./usr/lib/64/libpthread.so.1.2			base-compat-shlib	compat,pic
 ./usr/lib/64/libpthread_dbg.so.2		base-compat-shlib	compat,pic
 ./usr/lib/64/libpthread_dbg.so.2.0		base-compat-shlib	compat,pic
 ./usr/lib/64/libpuffs.so.2			base-compat-shlib	compat,pic
@@ -550,7 +550,7 @@
 ./usr/lib/o32/libprop.so.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libprop.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libpthread.so.1			base-compat-shlib	compat,pic
-./usr/lib/o32/libpthread.so.1.1			base-compat-shlib	compat,pic
+./usr/lib/o32/libpthread.so.1.2			base-compat-shlib	compat,pic
 ./usr/lib/o32/libpthread_dbg.so.2		base-compat-shlib	compat,pic
 ./usr/lib/o32/libpthread_dbg.so.2.0		base-compat-shlib	compat,pic
 ./usr/lib/o32/libpuffs.so.2			base-compat-shlib	compat,pic
Index: src/distrib/sets/lists/base/ad.mips64el
diff -u src/distrib/sets/lists/base/ad.mips64el:1.121 src/distrib/sets/lists/base/ad.mips64el:1.122
--- src/distrib/sets/lists/base/ad.mips64el:1.121	Fri Mar 29 17:59:51 2013
+++ src/distrib/sets/lists/base/ad.mips64el	Wed Apr  3 11:50:37 2013
@@ -1,4 +1,4 @@
-# $NetBSD: ad.mips64el,v 1.121 2013/03/29 21:59:51 christos Exp $
+# $NetBSD: ad.mips64el,v 1.122 2013/04/03 15:50:37 christos Exp $
 ./lib/64	base-compat-shlib	compat
 ./lib/64/npf	base-npf-shlib		compat
 ./lib/64/npf/ext_log.sobase-npf-shlib		compat,pic
@@ -232,7 +232,7 @@
 ./usr/lib/64/libprop.so.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libprop.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/64/libpthread.so.1			base-compat-shlib	compat,pic
-./usr/lib/64/libpthread.so.1.1			base-compat-shlib	compat,pic
+./usr/lib/64/libpthread.so.1.2			base-compat-shlib	compat,pic
 ./usr/lib/64/libpthread_dbg.so.2		base-compat-shlib	compat,pic
 ./usr/lib/64/libpthread_dbg.so.2.0		base-compat-shlib	compat,pic
 ./usr/lib/64/libpuffs.so.2			base-compat-shlib	compat,pic
@@ -550,7 +550,7 @@
 ./usr/lib/o32/libprop.so.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libprop.so.1.1			base-compat-shlib	compat,pic
 ./usr/lib/o32/libpthread.so.1			base-compat-shlib	compat,pic
-./usr/lib/o32/libpthread.so.1.1			base-compat-shlib	compat,pic
+./usr/lib/o32/libpthread.so.1.2			base-compat-shlib	compat,pic
 ./usr/lib/o32/libpthread_dbg.so.2		base-compat-shlib	compat,pic
 ./usr/lib/o32/libpthread_dbg.so.2.0		base-compat-shlib	compat,pic
 ./usr/lib/o32/libpuffs.so.2			base-compat-shlib	compat,pic

Index: src/distrib/sets/lists/base/md.amd64
diff -u src/distrib/sets/lists/base/md.amd64:1.199 src/distrib/sets/lists/base/md.amd64:1.200
--- src/distrib/sets/lists/base/md.amd64:1.199	Fri Mar 29 17:59:51 2013
+++ src/distrib/sets/lists/base/md.amd64	Wed Apr  3 11:50:37 2013
@@ -1,4 +1,4 @@
-# $NetBSD: md.amd64,v 1.199 2013/03/29 21:59:51 christos Exp $
+# $NetBSD: md.amd64,v 1.200 2013/04/03 15:50:37 christos Exp $
 ./dev/lms0	base-obsolete		obsolete
 ./dev/mms0	base-obsolete		obsolete
 ./lib/i386	base-compat-shlib		compat
@@ -231,7 +231,7 @@
 ./usr/lib/i386/libprop.so.1			base-compat-shlib	compat,pic
 ./usr/lib/i386/libprop.so.1.1			base-co

CVS commit: src/sys/dev/usb

2013-04-03 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Apr  3 15:57:45 UTC 2013

Modified Files:
src/sys/dev/usb: if_smscreg.h

Log Message:
KNF and whitespace. No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/dev/usb/if_smscreg.h

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

Modified files:

Index: src/sys/dev/usb/if_smscreg.h
diff -u src/sys/dev/usb/if_smscreg.h:1.2 src/sys/dev/usb/if_smscreg.h:1.3
--- src/sys/dev/usb/if_smscreg.h:1.2	Sat Feb  9 16:42:45 2013
+++ src/sys/dev/usb/if_smscreg.h	Wed Apr  3 15:57:44 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_smscreg.h,v 1.2 2013/02/09 16:42:45 skrll Exp $	*/
+/*	$NetBSD: if_smscreg.h,v 1.3 2013/04/03 15:57:44 skrll Exp $	*/
 
 /*	$OpenBSD: if_smscreg.h,v 1.2 2012/09/27 12:38:11 jsg Exp $	*/
 /*-
@@ -40,7 +40,7 @@
  *
  */
 
-/**
+/*
  * TRANSMIT FRAMES
  * ---
  *   Tx frames are prefixed with an 8-byte header which describes the frame
@@ -63,17 +63,17 @@
  *  TX_CTRL_1 <10:0>   Packet byte length
  *
  */
-#define SMSC_TX_CTRL_0_OFFSET(x) (((x) & 0x1FUL) << 16)
-#define SMSC_TX_CTRL_0_FIRST_SEG (0x1UL << 13)
-#define SMSC_TX_CTRL_0_LAST_SEG  (0x1UL << 12)
-#define SMSC_TX_CTRL_0_BUF_SIZE(x)   ((x) & 0x07FFUL)
-
-#define SMSC_TX_CTRL_1_CSUM_ENABLE   (0x1UL << 14)
-#define SMSC_TX_CTRL_1_CRC_DISABLE   (0x1UL << 13)
-#define SMSC_TX_CTRL_1_PADDING_DISABLE   (0x1UL << 12)
-#define SMSC_TX_CTRL_1_PKT_LENGTH(x) ((x) & 0x07FFUL)
+#define SMSC_TX_CTRL_0_OFFSET(x)	(((x) & 0x1FUL) << 16)
+#define SMSC_TX_CTRL_0_FIRST_SEG	(0x1UL << 13)
+#define SMSC_TX_CTRL_0_LAST_SEG		(0x1UL << 12)
+#define SMSC_TX_CTRL_0_BUF_SIZE(x)	((x) & 0x07FFUL)
+
+#define SMSC_TX_CTRL_1_CSUM_ENABLE	(0x1UL << 14)
+#define SMSC_TX_CTRL_1_CRC_DISABLE	(0x1UL << 13)
+#define SMSC_TX_CTRL_1_PADDING_DISABLE	(0x1UL << 12)
+#define SMSC_TX_CTRL_1_PKT_LENGTH(x)	((x) & 0x07FFUL)
 
-/**
+/*
  * RECEIVE FRAMES
  * --
  *   Rx frames are prefixed with an 4-byte status header which describes any
@@ -102,143 +102,142 @@
  *  RX_STAT   <1>  CRC Error
  *
  */
-#define SMSC_RX_STAT_FILTER_FAIL (0x1UL << 30)
-#define SMSC_RX_STAT_FRM_LENGTH(x)   (((x) >> 16) & 0x3FFFUL)
-#define SMSC_RX_STAT_ERROR   (0x1UL << 15)
-#define SMSC_RX_STAT_BROADCAST   (0x1UL << 13)
-#define SMSC_RX_STAT_LENGTH_ERROR(0x1UL << 12)
-#define SMSC_RX_STAT_RUNT(0x1UL << 11)
-#define SMSC_RX_STAT_MULTICAST   (0x1UL << 10)
-#define SMSC_RX_STAT_FRM_TO_LONG (0x1UL << 7)
-#define SMSC_RX_STAT_COLLISION   (0x1UL << 6)
-#define SMSC_RX_STAT_FRM_TYPE(0x1UL << 5)
-#define SMSC_RX_STAT_WATCHDOG(0x1UL << 4)
-#define SMSC_RX_STAT_MII_ERROR   (0x1UL << 3)
-#define SMSC_RX_STAT_DRIBBLING   (0x1UL << 2)
-#define SMSC_RX_STAT_CRC_ERROR   (0x1UL << 1)
+#define SMSC_RX_STAT_FILTER_FAIL	(0x1UL << 30)
+#define SMSC_RX_STAT_FRM_LENGTH(x)	(((x) >> 16) & 0x3FFFUL)
+#define SMSC_RX_STAT_ERROR		(0x1UL << 15)
+#define SMSC_RX_STAT_BROADCAST		(0x1UL << 13)
+#define SMSC_RX_STAT_LENGTH_ERROR	(0x1UL << 12)
+#define SMSC_RX_STAT_RUNT		(0x1UL << 11)
+#define SMSC_RX_STAT_MULTICAST		(0x1UL << 10)
+#define SMSC_RX_STAT_FRM_TOO_LONG	(0x1UL << 7)
+#define SMSC_RX_STAT_COLLISION		(0x1UL << 6)
+#define SMSC_RX_STAT_FRM_TYPE		(0x1UL << 5)
+#define SMSC_RX_STAT_WATCHDOG		(0x1UL << 4)
+#define SMSC_RX_STAT_MII_ERROR		(0x1UL << 3)
+#define SMSC_RX_STAT_DRIBBLING		(0x1UL << 2)
+#define SMSC_RX_STAT_CRC_ERROR		(0x1UL << 1)
 
-/**
+/*
  * REGISTERS
- *
  */
-#define SMSC_ID_REV 0x000
-#define SMSC_INTR_STATUS0x008
-#define SMSC_RX_CFG 0x00C
-#define SMSC_TX_CFG 0x010
-#define SMSC_HW_CFG 0x014
-#define SMSC_PM_CTRL0x020
-#define SMSC_LED_GPIO_CFG   0x024
-#define SMSC_GPIO_CFG   0x028
-#define SMSC_AFC_CFG0x02C
-#define SMSC_EEPROM_CMD 0x030
-#define SMSC_EEPROM_DATA0x034
-#define SMSC_BURST_CAP  0x038
-#define SMSC_GPIO_WAKE  0x064
-#define SMSC_INTR_CFG   0x068
-#define SMSC_BULK_IN_DLY0x06C
-#define SMSC_MAC_CSR0x100
-#define SMSC_MAC_ADDRH  0x104
-#define SMSC_MAC_ADDRL  0x108
-#define SMSC_HASHH  0x10C
-#define SMSC_HASHL  0x110
-#define SMSC_MII_ADDR   0x114
-#define SMSC_MII_DATA   0x118
-#define SMSC_FLOW   0x11C
-#define SMSC_VLAN1  0x120
-#define SMSC_VLAN2  0x124
-#define SMSC_WUFF   0x128
-#define SMSC_WUCSR  0x12C
-#define SMSC_COE_CTRL   0x130
+#define SMSC_ID_REV		0x000
+#define SMSC_INTR_STATUS	0x008
+#define SMSC_RX_CFG		0x00C
+#define SMSC_TX_CFG		0x010

CVS commit: src/sys/dev

2013-04-03 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Wed Apr  3 17:15:07 UTC 2013

Modified Files:
src/sys/dev/ata: ata.c atavar.h sata_subr.c satavar.h
src/sys/dev/ic: ahcisata_core.c mvsata.c siisata.c wdc.c
src/sys/dev/usb: umass_isdata.c

Log Message:
Fix kernel dump on ahci controller, by making sure we won't sleep
while dumping:
- introduce ata_delay() which either use delay() or kpause()
  depending on flags. use it in sata_reset_interface() and
  some ahci functions
- kill ATA_NOSLEEP, it was tested but never set. use ATA_POLL instead.
- reduce delay while polling in ahci, to speed up the dump

Should fix PR kern/41095


To generate a diff of this commit:
cvs rdiff -u -r1.126 -r1.127 src/sys/dev/ata/ata.c
cvs rdiff -u -r1.90 -r1.91 src/sys/dev/ata/atavar.h
cvs rdiff -u -r1.20 -r1.21 src/sys/dev/ata/sata_subr.c
cvs rdiff -u -r1.8 -r1.9 src/sys/dev/ata/satavar.h
cvs rdiff -u -r1.46 -r1.47 src/sys/dev/ic/ahcisata_core.c
cvs rdiff -u -r1.29 -r1.30 src/sys/dev/ic/mvsata.c
cvs rdiff -u -r1.23 -r1.24 src/sys/dev/ic/siisata.c
cvs rdiff -u -r1.277 -r1.278 src/sys/dev/ic/wdc.c
cvs rdiff -u -r1.27 -r1.28 src/sys/dev/usb/umass_isdata.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/ata/ata.c
diff -u src/sys/dev/ata/ata.c:1.126 src/sys/dev/ata/ata.c:1.127
--- src/sys/dev/ata/ata.c:1.126	Thu Nov  1 13:46:52 2012
+++ src/sys/dev/ata/ata.c	Wed Apr  3 17:15:07 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: ata.c,v 1.126 2012/11/01 13:46:52 abs Exp $	*/
+/*	$NetBSD: ata.c,v 1.127 2013/04/03 17:15:07 bouyer Exp $	*/
 
 /*
  * Copyright (c) 1998, 2001 Manuel Bouyer.  All rights reserved.
@@ -25,7 +25,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ata.c,v 1.126 2012/11/01 13:46:52 abs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ata.c,v 1.127 2013/04/03 17:15:07 bouyer Exp $");
 
 #include "opt_ata.h"
 
@@ -1719,3 +1719,17 @@ atabus_rescan(device_t self, const char 
 
 	return 0;
 }
+
+void
+ata_delay(int ms, const char *msg, int flags)
+{
+	if ((flags & (AT_WAIT | AT_POLL)) == AT_POLL) {
+		/*
+		 * can't use tsleep(), we may be in interrupt context
+		 * or taking a crash dump
+		 */
+		delay(ms * 1000);
+	} else {
+		kpause(msg, false, mstohz(ms), NULL);
+	}
+}

Index: src/sys/dev/ata/atavar.h
diff -u src/sys/dev/ata/atavar.h:1.90 src/sys/dev/ata/atavar.h:1.91
--- src/sys/dev/ata/atavar.h:1.90	Tue Jul 31 15:50:34 2012
+++ src/sys/dev/ata/atavar.h	Wed Apr  3 17:15:07 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: atavar.h,v 1.90 2012/07/31 15:50:34 bouyer Exp $	*/
+/*	$NetBSD: atavar.h,v 1.91 2013/04/03 17:15:07 bouyer Exp $	*/
 
 /*
  * Copyright (c) 1998, 2001 Manuel Bouyer.
@@ -193,7 +193,7 @@ struct ata_drive_datas {
  */
 struct ata_bio {
 	volatile u_int16_t flags;/* cmd flags */
-#define	ATA_NOSLEEP	0x0001	/* Can't sleep */
+/* 			0x0001	free, was ATA_NOSLEEP */
 #define	ATA_POLL	0x0002	/* poll for completion */
 #define	ATA_ITSDONE	0x0004	/* the transfer is as done as it gets */
 #define	ATA_SINGLE	0x0008	/* transfer must be done in singlesector mode */
@@ -464,6 +464,7 @@ void	ata_probe_caps(struct ata_drive_dat
 void	ata_dmaerr(struct ata_drive_datas *, int);
 #endif
 void	ata_queue_idle(struct ata_queue *);
+void	ata_delay(int, const char *, int);
 #endif /* _KERNEL */
 
 #endif /* _DEV_ATA_ATAVAR_H_ */

Index: src/sys/dev/ata/sata_subr.c
diff -u src/sys/dev/ata/sata_subr.c:1.20 src/sys/dev/ata/sata_subr.c:1.21
--- src/sys/dev/ata/sata_subr.c:1.20	Tue Jul 31 15:50:34 2012
+++ src/sys/dev/ata/sata_subr.c	Wed Apr  3 17:15:07 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: sata_subr.c,v 1.20 2012/07/31 15:50:34 bouyer Exp $	*/
+/*	$NetBSD: sata_subr.c,v 1.21 2013/04/03 17:15:07 bouyer Exp $	*/
 
 /*-
  * Copyright (c) 2004 The NetBSD Foundation, Inc.
@@ -33,7 +33,7 @@
  * Common functions for Serial ATA.
  */
 #include 
-__KERNEL_RCSID(0, "$NetBSD: sata_subr.c,v 1.20 2012/07/31 15:50:34 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sata_subr.c,v 1.21 2013/04/03 17:15:07 bouyer Exp $");
 
 #include 
 #include 
@@ -80,7 +80,7 @@ sata_speed(uint32_t sstatus)
  */
 uint32_t
 sata_reset_interface(struct ata_channel *chp, bus_space_tag_t sata_t,
-bus_space_handle_t scontrol_r, bus_space_handle_t sstatus_r)
+bus_space_handle_t scontrol_r, bus_space_handle_t sstatus_r, int flags)
 {
 	uint32_t scontrol, sstatus;
 	int i;
@@ -94,17 +94,17 @@ sata_reset_interface(struct ata_channel 
 	scontrol = SControl_IPM_NONE | SControl_SPD_ANY | SControl_DET_INIT;
 	bus_space_write_4 (sata_t, scontrol_r, 0, scontrol);
 
-	tsleep(chp, PRIBIO, "sataup", mstohz(50));
+	ata_delay(50, "sataup", flags);
 	scontrol &= ~SControl_DET_INIT;
 	bus_space_write_4(sata_t, scontrol_r, 0, scontrol);
 
-	tsleep(chp, PRIBIO, "sataup", mstohz(50));
+	ata_delay(50, "sataup", flags);
 	/* wait up to 1s for device to come up */
 	for (i = 0; i < 100; i++) {
 		sstatus = bus_space_read_4(sata_t, sstatus_r, 0);
 		if ((sstatus & SStatus_DET_mask) == SStatus_D

CVS commit: src/bin/csh

2013-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 17:32:25 UTC 2013

Modified Files:
src/bin/csh: set.c

Log Message:
Make shifting variables reflect their environment counterparts. Makes
"shift path" work as expected.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/bin/csh/set.c

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

Modified files:

Index: src/bin/csh/set.c
diff -u src/bin/csh/set.c:1.31 src/bin/csh/set.c:1.32
--- src/bin/csh/set.c:1.31	Wed Jan 23 11:39:03 2013
+++ src/bin/csh/set.c	Wed Apr  3 13:32:24 2013
@@ -1,4 +1,4 @@
-/* $NetBSD: set.c,v 1.31 2013/01/23 16:39:03 christos Exp $ */
+/* $NetBSD: set.c,v 1.32 2013/04/03 17:32:24 christos Exp $ */
 
 /*-
  * Copyright (c) 1980, 1991, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)set.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: set.c,v 1.31 2013/01/23 16:39:03 christos Exp $");
+__RCSID("$NetBSD: set.c,v 1.32 2013/04/03 17:32:24 christos Exp $");
 #endif
 #endif /* not lint */
 
@@ -65,6 +65,71 @@ static void balance(struct varent *, int
  * C Shell
  */
 
+static void
+update_vars(Char *vp)
+{
+if (eq(vp, STRpath)) {
+	struct varent *pt = adrof(STRpath); 
+	if (pt == NULL)
+	stderror(ERR_NAME | ERR_UNDVAR);
+	else {
+	exportpath(pt->vec);
+	dohash(NULL, NULL);
+	}
+}
+else if (eq(vp, STRhistchars)) {
+	Char *pn = value(STRhistchars);
+
+	HIST = *pn++;
+	HISTSUB = *pn;
+}
+else if (eq(vp, STRuser)) {
+	Setenv(STRUSER, value(vp));
+	Setenv(STRLOGNAME, value(vp));
+}
+else if (eq(vp, STRwordchars)) {
+	word_chars = value(vp);
+}
+else if (eq(vp, STRterm))
+	Setenv(STRTERM, value(vp));
+else if (eq(vp, STRhome)) {
+	Char *cp;
+
+	cp = Strsave(value(vp));	/* get the old value back */
+
+	/*
+	 * convert to canonical pathname (possibly resolving symlinks)
+	 */
+	cp = dcanon(cp, cp);
+
+	set(vp, Strsave(cp));	/* have to save the new val */
+
+	/* and now mirror home with HOME */
+	Setenv(STRHOME, cp);
+	/* fix directory stack for new tilde home */
+	dtilde();
+	xfree((ptr_t)cp);
+}
+#ifdef FILEC
+else if (eq(vp, STRfilec))
+	filec = 1;
+#endif
+#ifdef EDIT
+else if (eq(vp, STRedit)) {
+	HistEvent ev;
+	editing = 1;
+	el = el_init_fd(getprogname(), cshin, cshout, csherr,
+	SHIN, SHOUT, SHERR);
+	el_set(el, EL_EDITOR, "emacs");
+	el_set(el, EL_PROMPT, printpromptstr);
+	hi = history_init();
+	history(hi, &ev, H_SETSIZE, getn(value(STRhistory)));
+	loadhist(Histlist.Hnext);
+	el_set(el, EL_HIST, history, hi);
+}
+#endif
+}
+
 void
 /*ARGSUSED*/
 doset(Char **v, struct command *t)
@@ -128,66 +193,7 @@ doset(Char **v, struct command *t)
 	asx(vp, subscr, Strsave(p));
 	else
 	set(vp, Strsave(p));
-	if (eq(vp, STRpath)) {
-	struct varent *pt = adrof(STRpath); 
-	if (pt == NULL)
-		stderror(ERR_NAME | ERR_UNDVAR);
-	else {
-		exportpath(pt->vec);
-		dohash(NULL, NULL);
-	}
-	}
-	else if (eq(vp, STRhistchars)) {
-	Char *pn = value(STRhistchars);
-
-	HIST = *pn++;
-	HISTSUB = *pn;
-	}
-	else if (eq(vp, STRuser)) {
-	Setenv(STRUSER, value(vp));
-	Setenv(STRLOGNAME, value(vp));
-	}
-	else if (eq(vp, STRwordchars)) {
-	word_chars = value(vp);
-	}
-	else if (eq(vp, STRterm))
-	Setenv(STRTERM, value(vp));
-	else if (eq(vp, STRhome)) {
-	Char *cp;
-
-	cp = Strsave(value(vp));	/* get the old value back */
-
-	/*
-	 * convert to canonical pathname (possibly resolving symlinks)
-	 */
-	cp = dcanon(cp, cp);
-
-	set(vp, Strsave(cp));	/* have to save the new val */
-
-	/* and now mirror home with HOME */
-	Setenv(STRHOME, cp);
-	/* fix directory stack for new tilde home */
-	dtilde();
-	xfree((ptr_t)cp);
-	}
-#ifdef FILEC
-	else if (eq(vp, STRfilec))
-	filec = 1;
-#endif
-#ifdef EDIT
-	else if (eq(vp, STRedit)) {
-	HistEvent ev;
-	editing = 1;
-	el = el_init_fd(getprogname(), cshin, cshout, csherr,
-		SHIN, SHOUT, SHERR);
-	el_set(el, EL_EDITOR, "emacs");
-	el_set(el, EL_PROMPT, printpromptstr);
-	hi = history_init();
-	history(hi, &ev, H_SETSIZE, getn(value(STRhistory)));
-	loadhist(Histlist.Hnext);
-	el_set(el, EL_HIST, history, hi);
-	}
-#endif
+	update_vars(vp);
 } while ((p = *v++) != NULL);
 }
 
@@ -621,6 +627,7 @@ shift(Char **v, struct command *t)
 if (argv->vec[0] == 0)
 	stderror(ERR_NAME | ERR_NOMORE);
 lshift(argv->vec, 1);
+update_vars(name);
 }
 
 static void



CVS commit: src/sys/dev/usb

2013-04-03 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Apr  3 19:02:13 UTC 2013

Modified Files:
src/sys/dev/usb: ohci.c

Log Message:
Don't leak memory if ohci_alloc_std_chain fails.


To generate a diff of this commit:
cvs rdiff -u -r1.235 -r1.236 src/sys/dev/usb/ohci.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/usb/ohci.c
diff -u src/sys/dev/usb/ohci.c:1.235 src/sys/dev/usb/ohci.c:1.236
--- src/sys/dev/usb/ohci.c:1.235	Fri Mar 22 13:28:11 2013
+++ src/sys/dev/usb/ohci.c	Wed Apr  3 19:02:12 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: ohci.c,v 1.235 2013/03/22 13:28:11 skrll Exp $	*/
+/*	$NetBSD: ohci.c,v 1.236 2013/04/03 19:02:12 skrll Exp $	*/
 
 /*
  * Copyright (c) 1998, 2004, 2005, 2012 The NetBSD Foundation, Inc.
@@ -41,7 +41,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.235 2013/03/22 13:28:11 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.236 2013/04/03 19:02:12 skrll Exp $");
 
 #include 
 #include 
@@ -98,10 +98,8 @@ Static void		ohci_free_std(ohci_softc_t 
 Static ohci_soft_itd_t *ohci_alloc_sitd(ohci_softc_t *);
 Static void		ohci_free_sitd(ohci_softc_t *,ohci_soft_itd_t *);
 
-#if 0
 Static void		ohci_free_std_chain(ohci_softc_t *, ohci_soft_td_t *,
 	ohci_soft_td_t *);
-#endif
 Static usbd_status	ohci_alloc_std_chain(struct ohci_pipe *,
 			ohci_softc_t *, int, int, usbd_xfer_handle,
 			ohci_soft_td_t *, ohci_soft_td_t **);
@@ -565,11 +563,13 @@ ohci_alloc_std_chain(struct ohci_pipe *o
 	return (USBD_NORMAL_COMPLETION);
 
  nomem:
-	/* XXX free chain */
+
+	/* Don't free sp - let the caller do that */
+	ohci_free_std_chain(sc, sp->nexttd, NULL);
+
 	return (USBD_NOMEM);
 }
 
-#if 0
 Static void
 ohci_free_std_chain(ohci_softc_t *sc, ohci_soft_td_t *std,
 		ohci_soft_td_t *stdend)
@@ -581,7 +581,6 @@ ohci_free_std_chain(ohci_softc_t *sc, oh
 		ohci_free_std(sc, std);
 	}
 }
-#endif
 
 ohci_soft_itd_t *
 ohci_alloc_sitd(ohci_softc_t *sc)
@@ -1757,9 +1756,12 @@ ohci_device_request(usbd_xfer_handle xfe
 
 		err = ohci_alloc_std_chain(opipe, sc, len, isread, xfer,
 			  std, &stat);
-		stat = stat->nexttd; /* point at free TD */
-		if (err)
+		if (err) {
+			/* stat is unchanged if error */
 			goto bad3;
+		}
+		stat = stat->nexttd; /* point at free TD */
+
 		/* Start toggle at 1 and then use the carried toggle. */
 		std->td.td_flags &= HTOO32(~OHCI_TD_TOGGLE_MASK);
 		std->td.td_flags |= HTOO32(OHCI_TD_TOGGLE_1);
@@ -3044,6 +3046,9 @@ ohci_device_bulk_start(usbd_xfer_handle 
 	data = opipe->tail.td;
 	err = ohci_alloc_std_chain(opipe, sc, len, isread, xfer,
 		  data, &tail);
+	if (err)
+		return err;
+	
 	/* We want interrupt at the end of the transfer. */
 	tail->td.td_flags &= HTOO32(~OHCI_TD_INTR_MASK);
 	tail->td.td_flags |= HTOO32(OHCI_TD_SET_DI(1));



CVS commit: src/distrib/utils/embedded

2013-04-03 Thread Hisashi T Fujinaka
Module Name:src
Committed By:   htodd
Date:   Wed Apr  3 19:37:43 UTC 2013

Modified Files:
src/distrib/utils/embedded: mkimage

Log Message:
Fix build.


To generate a diff of this commit:
cvs rdiff -u -r1.37 -r1.38 src/distrib/utils/embedded/mkimage

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

Modified files:

Index: src/distrib/utils/embedded/mkimage
diff -u src/distrib/utils/embedded/mkimage:1.37 src/distrib/utils/embedded/mkimage:1.38
--- src/distrib/utils/embedded/mkimage:1.37	Thu Mar 28 00:20:02 2013
+++ src/distrib/utils/embedded/mkimage	Wed Apr  3 19:37:43 2013
@@ -1,5 +1,5 @@
 #!/bin/sh
-# $NetBSD: mkimage,v 1.37 2013/03/28 00:20:02 jmcneill Exp $
+# $NetBSD: mkimage,v 1.38 2013/04/03 19:37:43 htodd Exp $
 #
 # Copyright (c) 2013 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -156,8 +156,8 @@ if [ -z "$bootonly" ]; then
 	echo ${bar} Populating ffs filesystem ${bar}
 	${MAKEFS} -N ${release}/etc -t ffs -rx \
 	-O $(((${init} + ${boot} + ${swap}) / 2))m \
-	-b $((${extra} / 2))m \
-	-o d=4096 \
+		-o d=4096 \
+	-b $((${extra}))m \
 	-F "$tmp/selected_sets" ${image} "${release}" "${mnt}"
 fi
 



CVS commit: src/sys/external/bsd/vchiq/dist/interface/vchiq_arm

2013-04-03 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Apr  3 20:21:38 UTC 2013

Removed Files:
src/sys/external/bsd/vchiq/dist/interface/vchiq_arm:
vchiq_kmod_freebsd.c

Log Message:
Remove unnecessary freebsd code.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r0 \
src/sys/external/bsd/vchiq/dist/interface/vchiq_arm/vchiq_kmod_freebsd.c

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



CVS commit: src/sys/rump/librump/rumpvfs

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Apr  3 20:23:02 UTC 2013

Modified Files:
src/sys/rump/librump/rumpvfs: rump_vfs.c

Log Message:
Don't create a huge number of unnecessary device nodes automatically.
Creating them takes 70-or-so ms on a RPi, and can almost double the
bootstrap time of a rump kernel on that hardware.


To generate a diff of this commit:
cvs rdiff -u -r1.71 -r1.72 src/sys/rump/librump/rumpvfs/rump_vfs.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/rump/librump/rumpvfs/rump_vfs.c
diff -u src/sys/rump/librump/rumpvfs/rump_vfs.c:1.71 src/sys/rump/librump/rumpvfs/rump_vfs.c:1.72
--- src/sys/rump/librump/rumpvfs/rump_vfs.c:1.71	Mon Jan 14 16:45:47 2013
+++ src/sys/rump/librump/rumpvfs/rump_vfs.c	Wed Apr  3 20:23:01 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump_vfs.c,v 1.71 2013/01/14 16:45:47 pooka Exp $	*/
+/*	$NetBSD: rump_vfs.c,v 1.72 2013/04/03 20:23:01 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -29,7 +29,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: rump_vfs.c,v 1.71 2013/01/14 16:45:47 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rump_vfs.c,v 1.72 2013/04/03 20:23:01 pooka Exp $");
 
 #include 
 #include 
@@ -91,8 +91,6 @@ drainbufs(int npages)
 
 RUMP_COMPONENT(RUMP__FACTION_VFS)
 {
-	extern struct devsw_conv devsw_conv0[];
-	extern int max_devsw_convs;
 	extern struct vfsops rumpfs_vfsops;
 	char buf[64];
 	int error;
@@ -180,7 +178,22 @@ RUMP_COMPONENT(RUMP__FACTION_VFS)
 
 	module_init_class(MODULE_CLASS_VFS);
 
+	/*
+	 * Don't build device names for a large set of devices by
+	 * default.  While the pseudo-devfs is a fun experiment,
+	 * creating many many device nodes may increase rump kernel
+	 * bootstrap time by ~40%.  Device nodes should be created
+	 * per-demand in the component constructors.
+	 */
+#if 0
+	{
+	extern struct devsw_conv devsw_conv0[];
+	extern int max_devsw_convs;
 	rump_vfs_builddevs(devsw_conv0, max_devsw_convs);
+	}
+#else
+	rump_vfs_builddevs(NULL, 0);
+#endif
 
 	rump_component_init(RUMP_COMPONENT_VFS);
 }



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

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Apr  3 22:43:56 UTC 2013

Modified Files:
src/sys/rump/kern/lib/libsys_linux: component.c

Log Message:
add a few arch-specific stubs to make this link on arm


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/rump/kern/lib/libsys_linux/component.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/rump/kern/lib/libsys_linux/component.c
diff -u src/sys/rump/kern/lib/libsys_linux/component.c:1.6 src/sys/rump/kern/lib/libsys_linux/component.c:1.7
--- src/sys/rump/kern/lib/libsys_linux/component.c:1.6	Thu Mar  7 19:10:59 2013
+++ src/sys/rump/kern/lib/libsys_linux/component.c	Wed Apr  3 22:43:56 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: component.c,v 1.6 2013/03/07 19:10:59 pooka Exp $	*/
+/*	$NetBSD: component.c,v 1.7 2013/04/03 22:43:56 pooka Exp $	*/
 
 #include 
 #include 
@@ -79,3 +79,7 @@ __weak_alias(oss_ioctl_sequencer,rumplin
 __weak_alias(oss_ioctl_audio,rumplinux__stub);
 __weak_alias(rusage_to_rusage50,rumplinux__stub);
 __weak_alias(do_sys_wait,rumplinux__stub);
+
+/* arch-specific */
+__weak_alias(compat_offseterr,rumplinux__stub);
+__weak_alias(linux_sys_ptrace_arch,rumplinux__stub);



CVS commit: [agc-symver] src/lib/libc/sys

2013-04-03 Thread Alistair G. Crooks
Module Name:src
Committed By:   agc
Date:   Wed Apr  3 23:36:26 UTC 2013

Modified Files:
src/lib/libc/sys [agc-symver]: select.2

Log Message:
correct a typo


To generate a diff of this commit:
cvs rdiff -u -r1.38 -r1.38.18.1 src/lib/libc/sys/select.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/select.2
diff -u src/lib/libc/sys/select.2:1.38 src/lib/libc/sys/select.2:1.38.18.1
--- src/lib/libc/sys/select.2:1.38	Mon Apr  5 21:25:56 2010
+++ src/lib/libc/sys/select.2	Wed Apr  3 23:36:25 2013
@@ -1,4 +1,4 @@
-.\"	$NetBSD: select.2,v 1.38 2010/04/05 21:25:56 joerg Exp $
+.\"	$NetBSD: select.2,v 1.38.18.1 2013/04/03 23:36:25 agc Exp $
 .\"
 .\" Copyright (c) 1983, 1991, 1993
 .\"	The Regents of the University of California.  All rights reserved.
@@ -192,7 +192,7 @@ main(int argc, char **argv)
 	FD_SET(fd, \*[Am]read_set);
 
 	/*
-	 * Check if data is ready to be readen on
+	 * Check if data is ready to be read on
 	 * file descriptor 1, give up after 10 seconds.
 	 */
 	ret = select(fd + 1, \*[Am]read_set, NULL, NULL, \*[Am]timeout);



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

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Wed Apr  3 23:51:20 UTC 2013

Modified Files:
src/sys/rump/kern/lib/libsys_linux: component.c

Log Message:
i386 has a special way to handle uname.  We don't really care about
satisfying uname in a rump kernel, but attempt to return something
sane anyway.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/rump/kern/lib/libsys_linux/component.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/rump/kern/lib/libsys_linux/component.c
diff -u src/sys/rump/kern/lib/libsys_linux/component.c:1.7 src/sys/rump/kern/lib/libsys_linux/component.c:1.8
--- src/sys/rump/kern/lib/libsys_linux/component.c:1.7	Wed Apr  3 22:43:56 2013
+++ src/sys/rump/kern/lib/libsys_linux/component.c	Wed Apr  3 23:51:20 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: component.c,v 1.7 2013/04/03 22:43:56 pooka Exp $	*/
+/*	$NetBSD: component.c,v 1.8 2013/04/03 23:51:20 pooka Exp $	*/
 
 #include 
 #include 
@@ -83,3 +83,12 @@ __weak_alias(do_sys_wait,rumplinux__stub
 /* arch-specific */
 __weak_alias(compat_offseterr,rumplinux__stub);
 __weak_alias(linux_sys_ptrace_arch,rumplinux__stub);
+
+#ifdef __i386__
+const char *
+linux_get_uname_arch(void)
+{
+
+	return MACHINE_ARCH;
+}
+#endif /* __i386__ */



CVS commit: src/sys/rump/librump/rumpvfs

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Apr  4 01:29:55 UTC 2013

Modified Files:
src/sys/rump/librump/rumpvfs: devnull.c

Log Message:
create null devices


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/rump/librump/rumpvfs/devnull.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/rump/librump/rumpvfs/devnull.c
diff -u src/sys/rump/librump/rumpvfs/devnull.c:1.3 src/sys/rump/librump/rumpvfs/devnull.c:1.4
--- src/sys/rump/librump/rumpvfs/devnull.c:1.3	Thu Feb 10 11:01:31 2011
+++ src/sys/rump/librump/rumpvfs/devnull.c	Thu Apr  4 01:29:55 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: devnull.c,v 1.3 2011/02/10 11:01:31 pooka Exp $	*/
+/*	$NetBSD: devnull.c,v 1.4 2013/04/04 01:29:55 pooka Exp $	*/
 
 /*
  * Copyright (c) 2009 Antti Kantee.  All Rights Reserved.
@@ -33,7 +33,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: devnull.c,v 1.3 2011/02/10 11:01:31 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: devnull.c,v 1.4 2013/04/04 01:29:55 pooka Exp $");
 
 #include 
 #include 
@@ -60,7 +60,12 @@ rump_devnull_init()
 	error = devsw_attach("null", NULL, &null_bmaj, &null_cdevsw,&null_cmaj);
 	KASSERT(error || null_cmaj == 2);
 
-	return error;
+	error = rump_vfs_makeonedevnode(S_IFCHR,
+	"/dev/null", null_cmaj, DEV_NULL);
+	if (error)
+		return error;
+	return rump_vfs_makeonedevnode(S_IFCHR,
+	"/dev/zero", null_cmaj, DEV_ZERO);
 }
 
 static int



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

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Apr  4 01:33:53 UTC 2013

Modified Files:
src/sys/rump/dev/lib/libputter: Makefile
Added Files:
src/sys/rump/dev/lib/libputter: component.c

Log Message:
create /dev/putter device node in component attach


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/rump/dev/lib/libputter/Makefile
cvs rdiff -u -r0 -r1.3 src/sys/rump/dev/lib/libputter/component.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/rump/dev/lib/libputter/Makefile
diff -u src/sys/rump/dev/lib/libputter/Makefile:1.3 src/sys/rump/dev/lib/libputter/Makefile:1.4
--- src/sys/rump/dev/lib/libputter/Makefile:1.3	Thu Mar 31 08:36:25 2011
+++ src/sys/rump/dev/lib/libputter/Makefile	Thu Apr  4 01:33:53 2013
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.3 2011/03/31 08:36:25 pooka Exp $
+#	$NetBSD: Makefile,v 1.4 2013/04/04 01:33:53 pooka Exp $
 #
 
 .PATH:	${.CURDIR}/../../../../dev/putter
@@ -6,6 +6,7 @@
 LIB=	rumpdev_putter
 
 SRCS=	putter.c
+SRCS+=	component.c
 
 .include 
 .include 

Added files:

Index: src/sys/rump/dev/lib/libputter/component.c
diff -u /dev/null src/sys/rump/dev/lib/libputter/component.c:1.3
--- /dev/null	Thu Apr  4 01:33:53 2013
+++ src/sys/rump/dev/lib/libputter/component.c	Thu Apr  4 01:33:53 2013
@@ -0,0 +1,46 @@
+/*	$NetBSD: component.c,v 1.3 2013/04/04 01:33:53 pooka 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.3 2013/04/04 01:33:53 pooka Exp $");
+
+#include 
+#include 
+#include 
+#include 
+
+#include "rump_private.h"
+#include "rump_vfs_private.h"
+
+RUMP_COMPONENT(RUMP_COMPONENT_DEV)
+{
+	int error;
+
+	if ((error = rump_vfs_makeonedevnode(S_IFCHR,
+	"/dev/putter", 178, 0)) != 0)
+		panic("cannot create /dev/putter: %d", error);
+}



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

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Apr  4 01:38:47 UTC 2013

Modified Files:
src/sys/rump/dev/lib/libmd: component.c

Log Message:
create device nodes


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/rump/dev/lib/libmd/component.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/rump/dev/lib/libmd/component.c
diff -u src/sys/rump/dev/lib/libmd/component.c:1.2 src/sys/rump/dev/lib/libmd/component.c:1.3
--- src/sys/rump/dev/lib/libmd/component.c:1.2	Tue Apr 10 13:45:08 2012
+++ src/sys/rump/dev/lib/libmd/component.c	Thu Apr  4 01:38:47 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: component.c,v 1.2 2012/04/10 13:45:08 gson Exp $	*/
+/*	$NetBSD: component.c,v 1.3 2013/04/04 01:38:47 pooka Exp $	*/
 
 /*
  * Copyright (c) 2010 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: component.c,v 1.2 2012/04/10 13:45:08 gson Exp $");
+__KERNEL_RCSID(0, "$NetBSD: component.c,v 1.3 2013/04/04 01:38:47 pooka Exp $");
 
 #include 
 #include 
@@ -57,5 +57,12 @@ RUMP_COMPONENT(RUMP_COMPONENT_DEV)
 	&md_cdevsw, &cmaj)) != 0)
 		panic("md devsw attach failed: %d", error);
 
+if ((error = rump_vfs_makedevnodes(S_IFBLK, "/dev/md0", 'a',
+bmaj, 0, 7)) != 0)
+panic("cannot create cooked md dev nodes: %d", error);
+if ((error = rump_vfs_makedevnodes(S_IFCHR, "/dev/rmd0", 'a',
+cmaj, 0, 7)) != 0)
+panic("cannot create raw md dev nodes: %d", error);
+
 	rump_pdev_add(mdattach, 0);
 }



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

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Apr  4 01:41:51 UTC 2013

Modified Files:
src/sys/rump/dev/lib/libpad: Makefile
Added Files:
src/sys/rump/dev/lib/libpad: component.c

Log Message:
create device nodes


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/rump/dev/lib/libpad/Makefile
cvs rdiff -u -r0 -r1.1 src/sys/rump/dev/lib/libpad/component.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/rump/dev/lib/libpad/Makefile
diff -u src/sys/rump/dev/lib/libpad/Makefile:1.1 src/sys/rump/dev/lib/libpad/Makefile:1.2
--- src/sys/rump/dev/lib/libpad/Makefile:1.1	Sat May  1 23:21:24 2010
+++ src/sys/rump/dev/lib/libpad/Makefile	Thu Apr  4 01:41:51 2013
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.1 2010/05/01 23:21:24 pooka Exp $
+#	$NetBSD: Makefile,v 1.2 2013/04/04 01:41:51 pooka Exp $
 #
 
 .PATH:	${.CURDIR}/../../../../dev/pad
@@ -6,6 +6,7 @@
 LIB=	rumpdev_pad
 
 SRCS=	pad.c padvol.c
+SRCS+=	component.c
 
 CPPFLAGS+=	-I${.CURDIR}/../../../librump/rumpvfs
 

Added files:

Index: src/sys/rump/dev/lib/libpad/component.c
diff -u /dev/null src/sys/rump/dev/lib/libpad/component.c:1.1
--- /dev/null	Thu Apr  4 01:41:51 2013
+++ src/sys/rump/dev/lib/libpad/component.c	Thu Apr  4 01:41:51 2013
@@ -0,0 +1,45 @@
+/*	$NetBSD: component.c,v 1.1 2013/04/04 01:41:51 pooka Exp $	*/
+
+/*-
+ * Copyright (c) 2010 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 2013/04/04 01:41:51 pooka Exp $");
+
+#include 
+#include 
+#include 
+#include 
+
+#include "rump_private.h"
+#include "rump_vfs_private.h"
+
+RUMP_COMPONENT(RUMP_COMPONENT_DEV)
+{
+	int error;
+
+	if ((error = rump_vfs_makeonedevnode(S_IFCHR, "/dev/pad", 189, 0)) != 0)
+		panic("cannot create pad device: %d", error);
+}



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

2013-04-03 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Apr  4 01:48:20 UTC 2013

Modified Files:
src/sys/rump/dev/lib/libputter: Makefile

Log Message:
set correct include path


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/rump/dev/lib/libputter/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/dev/lib/libputter/Makefile
diff -u src/sys/rump/dev/lib/libputter/Makefile:1.4 src/sys/rump/dev/lib/libputter/Makefile:1.5
--- src/sys/rump/dev/lib/libputter/Makefile:1.4	Thu Apr  4 01:33:53 2013
+++ src/sys/rump/dev/lib/libputter/Makefile	Thu Apr  4 01:48:19 2013
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.4 2013/04/04 01:33:53 pooka Exp $
+#	$NetBSD: Makefile,v 1.5 2013/04/04 01:48:19 pooka Exp $
 #
 
 .PATH:	${.CURDIR}/../../../../dev/putter
@@ -8,5 +8,7 @@ LIB=	rumpdev_putter
 SRCS=	putter.c
 SRCS+=	component.c
 
+CPPFLAGS+=	-I${RUMPTOP}/librump/rumpvfs
+
 .include 
 .include