CVS commit: src/usr.sbin/ldpd

2010-12-30 Thread Mihai Chelaru
Module Name:src
Committed By:   kefren
Date:   Thu Dec 30 11:29:22 UTC 2010

Modified Files:
src/usr.sbin/ldpd: Makefile TODO label.c ldp.h ldp_command.c ldp_peer.c
ldpd.8 main.c socketops.c
Added Files:
src/usr.sbin/ldpd: conffile.c conffile.h

Log Message:
* add config file so one can control id, timers and label assignment and
  use neighbour specific options - XXX: needs documentation
* add peer authentication using TCP_MD5SIG. Interoperability tested with
  Cisco IOS
* use SLIST_FOREACH_SAFE when deleting labels instead of re-looping.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/usr.sbin/ldpd/Makefile src/usr.sbin/ldpd/label.c \
src/usr.sbin/ldpd/ldp_command.c src/usr.sbin/ldpd/ldp_peer.c \
src/usr.sbin/ldpd/ldpd.8 src/usr.sbin/ldpd/main.c \
src/usr.sbin/ldpd/socketops.c
cvs rdiff -u -r1.1 -r1.2 src/usr.sbin/ldpd/TODO src/usr.sbin/ldpd/ldp.h
cvs rdiff -u -r0 -r1.1 src/usr.sbin/ldpd/conffile.c \
src/usr.sbin/ldpd/conffile.h

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

Modified files:

Index: src/usr.sbin/ldpd/Makefile
diff -u src/usr.sbin/ldpd/Makefile:1.2 src/usr.sbin/ldpd/Makefile:1.3
--- src/usr.sbin/ldpd/Makefile:1.2	Sat Dec 18 04:25:37 2010
+++ src/usr.sbin/ldpd/Makefile	Thu Dec 30 11:29:21 2010
@@ -1,11 +1,12 @@
-# $NetBSD: Makefile,v 1.2 2010/12/18 04:25:37 joerg Exp $
+# $NetBSD: Makefile,v 1.3 2010/12/30 11:29:21 kefren Exp $
 
 .include bsd.own.mk
 
 PROG=   ldpd
 MAN=ldpd.8
 
-SRCS=   fsm.c \
+SRCS=   conffile.c \
+	fsm.c \
 	label.c \
 	ldp_command.c \
 	ldp_errors.c \
Index: src/usr.sbin/ldpd/label.c
diff -u src/usr.sbin/ldpd/label.c:1.2 src/usr.sbin/ldpd/label.c:1.3
--- src/usr.sbin/ldpd/label.c:1.2	Thu Dec  9 00:10:59 2010
+++ src/usr.sbin/ldpd/label.c	Thu Dec 30 11:29:21 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: label.c,v 1.2 2010/12/09 00:10:59 christos Exp $ */
+/* $NetBSD: label.c,v 1.3 2010/12/30 11:29:21 kefren Exp $ */
 
 /*-
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -41,6 +41,8 @@
 #include label.h
 #include ldp_errors.h
 
+int	min_label = MIN_LABEL, max_label = MAX_LABEL;
+
 void 
 label_init()
 {
@@ -146,7 +148,7 @@
 	l-label = 0;
 
 	/* Deletes pure MPLS route */
-	if (oldbinding = MIN_LABEL) {
+	if (oldbinding = min_label) {
 		u = make_mpls_union(oldbinding);
 		delete_route(u, NULL, FREESO);
 	}
@@ -189,22 +191,15 @@
 void 
 del_all_peer_labels(struct ldp_peer * p, int readd)
 {
-	struct label   *l;
-	int		do_remove = 1;
+	struct label   *l, *lnext;
 
-	while(do_remove == 1) {
-		do_remove = 0;
-		SLIST_FOREACH(l, label_head, labels) {
-			if(l-p != p)
-continue;
-			label_reattach_route(l, readd);
-			label_del(l);
-			/* remove must not interact with foreach */
-			SLIST_REMOVE(label_head, l, label, labels);
-			do_remove = 1;
-			break;		/* XXX: suboptimal */
-		}
-	} // while
+	SLIST_FOREACH_SAFE(l, label_head, labels, lnext) {
+		if(l-p != p)
+			continue;
+		label_reattach_route(l, readd);
+		label_del(l);
+		SLIST_REMOVE(label_head, l, label, labels);
+	}
 }
 
 /*
@@ -251,11 +246,11 @@
 get_free_local_label()
 {
 	struct label *l;
-	uint32_t lbl;
+	int lbl;
  
-	for (lbl = MIN_LABEL; lbl = MAX_LABEL; lbl++) {
+	for (lbl = min_label; lbl = max_label; lbl++) {
 		SLIST_FOREACH(l, label_head, labels)
-			if ((uint32_t)l-binding == lbl)
+			if (l-binding == lbl)
 break;
 		if (l == NULL)
 			return lbl;
Index: src/usr.sbin/ldpd/ldp_command.c
diff -u src/usr.sbin/ldpd/ldp_command.c:1.2 src/usr.sbin/ldpd/ldp_command.c:1.3
--- src/usr.sbin/ldpd/ldp_command.c:1.2	Tue Dec 14 21:32:43 2010
+++ src/usr.sbin/ldpd/ldp_command.c	Thu Dec 30 11:29:21 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: ldp_command.c,v 1.2 2010/12/14 21:32:43 christos Exp $ */
+/* $NetBSD: ldp_command.c,v 1.3 2010/12/30 11:29:21 kefren Exp $ */
 
 /*-
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -51,7 +51,8 @@
 #include socketops.h
 
 struct com_sock csockets[MAX_COMMAND_SOCKETS];
-extern int ldp_hello_time, debug_f, warn_f;
+extern int ldp_hello_time, ldp_keepalive_time, ldp_holddown_time,
+	min_label, max_label, debug_f, warn_f;
 
 #define	writestr(soc, str) write(soc, str, strlen(str))
 
@@ -62,7 +63,7 @@
 static void	echo_on(int s);
 static void	echo_off(int s);
 
-struct com_func main_commands[] = {
+static struct com_func main_commands[] = {
 	{ show, show_func },
 	{ set, set_func },
 	{ quit, exit_func },
@@ -70,7 +71,7 @@
 	{ , NULL }
 };
 
-struct com_func show_commands[] = {
+static struct com_func show_commands[] = {
 	{ neighbours, show_neighbours },
 	{ bindings, show_bindings },
 	{ debug, show_debug },
@@ -494,10 +495,10 @@
 		my_ldp_id,
 		LDP_VERSION,
 		ldp_hello_time,
-		LDP_KEEPALIVE_TIME,
-		LDP_HOLDTIME,
-		MIN_LABEL,
-		MAX_LABEL);
+		ldp_keepalive_time,
+		ldp_holddown_time,
+		min_label,
+		max_label);
 	writestr(s, sendspace);
 	return 1;
 }
Index: src/usr.sbin/ldpd/ldp_peer.c
diff -u src/usr.sbin/ldpd/ldp_peer.c:1.2 

CVS commit: src/sys/kern

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 11:42:53 UTC 2010

Modified Files:
src/sys/kern: makesyscalls.sh

Log Message:
Fill syscallnames up to nsysent so that nnsysent has a non-hyperspace
string mapping.


To generate a diff of this commit:
cvs rdiff -u -r1.103 -r1.104 src/sys/kern/makesyscalls.sh

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/makesyscalls.sh
diff -u src/sys/kern/makesyscalls.sh:1.103 src/sys/kern/makesyscalls.sh:1.104
--- src/sys/kern/makesyscalls.sh:1.103	Wed Nov 17 21:47:11 2010
+++ src/sys/kern/makesyscalls.sh	Thu Dec 30 11:42:53 2010
@@ -1,5 +1,5 @@
 #! /bin/sh -
-#	$NetBSD: makesyscalls.sh,v 1.103 2010/11/17 21:47:11 pooka Exp $
+#	$NetBSD: makesyscalls.sh,v 1.104 2010/12/30 11:42:53 pooka Exp $
 #
 # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou
 # All rights reserved.
@@ -817,6 +817,7 @@
 			sys_nosys, syscall)  sysent
 			printf(\t{ 0, 0, 0,\n\t%s },\t\t\t/* %d = filler */\n, \
 			(sy_call_t *)rump_enosys, syscall)  rumpsysent
+			printf(\t/* %3d */\t\# filler\,\n, syscall, syscall)  sysnamesbottom
 			syscall++
 		}
 	}



CVS commit: src/share/man/man4

2010-12-30 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Thu Dec 30 12:06:53 UTC 2010

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

Log Message:
Update.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/share/man/man4/acpicpu.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/acpicpu.4
diff -u src/share/man/man4/acpicpu.4:1.20 src/share/man/man4/acpicpu.4:1.21
--- src/share/man/man4/acpicpu.4:1.20	Mon Dec 20 09:11:37 2010
+++ src/share/man/man4/acpicpu.4	Thu Dec 30 12:06:53 2010
@@ -1,4 +1,4 @@
-.\ $NetBSD: acpicpu.4,v 1.20 2010/12/20 09:11:37 wiz Exp $
+.\ $NetBSD: acpicpu.4,v 1.21 2010/12/30 12:06:53 jruoho Exp $
 .\
 .\ Copyright (c) 2010 Jukka Ruohonen jruoho...@iki.fi
 .\ All rights reserved.
@@ -24,7 +24,7 @@
 .\ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\ POSSIBILITY OF SUCH DAMAGE.
 .\
-.Dd December 20, 2010
+.Dd December 30, 2010
 .Dt ACPICPU 4
 .Os
 .Sh NAME
@@ -185,11 +185,11 @@
 For example, if
 .Xr acpiacad 4
 is disconnected, the maximum available frequency may be lowered.
-Currently the
+By default,
+the
 .Nx
-implementation reacts to these events by imposing the dynamic maximum, but
-.Nm
-does not take any actions to manipulate the frequencies by itself.
+implementation may manipulate the frequencies
+according to the notifications from the firmware.
 .Ss T-states
 Processor T-states, or
 .Dq throttling states ,
@@ -250,17 +250,6 @@
 a high temperature situation exists.
 After the temperatures have returned to non-critical levels,
 the modulation ceases.
-.Ss Statistics
-The
-.Nm
-driver uses event counters to track the times
-a processor has entered a given state.
-It is possible to view the statistics by using
-.Xr vmstat 1
-(with the
-.Fl e
-flag).
-Note that valid per-CPU data is available only for C-states.
 .Ss System Control Variables
 The
 .Nm
@@ -277,7 +266,30 @@
 .Ic machdep.powernow .
 Please note that future versions of
 .Nm
-may however remove the system control variables without further notice.
+may however remove these system control variables without further notice.
+.Pp
+In addition, the following two variables are available.
+.Bl -tag -width hw.acpi.cpu.dynamic -offset indent
+.It Ic hw.acpi.cpu.dynamic
+A boolean that controls whether the states are allowed to change dynamically.
+When enabled, C-, P-, and T-states may all change at runtime, and
+.Nm
+may also take actions based on requests from the firmware.
+.It Ic hw.acpi.cpu.passive
+A boolean that enables or disables automatic processor thermal management via
+.Xr acpitz 4 .
+.El
+.Ss Statistics
+The
+.Nm
+driver uses event counters to track the times
+a processor has entered a given state.
+It is possible to view the statistics by using
+.Xr vmstat 1
+(with the
+.Fl e
+flag).
+Note that valid per-CPU data is available only for C-states.
 .Sh COMPATIBILITY
 The
 .Nm



CVS commit: src/sys/sys

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 12:46:34 UTC 2010

Modified Files:
src/sys/sys: systm.h

Log Message:
update comment


To generate a diff of this commit:
cvs rdiff -u -r1.243 -r1.244 src/sys/sys/systm.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/sys/systm.h
diff -u src/sys/sys/systm.h:1.243 src/sys/sys/systm.h:1.244
--- src/sys/sys/systm.h:1.243	Sat Dec 11 22:27:53 2010
+++ src/sys/sys/systm.h	Thu Dec 30 12:46:34 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: systm.h,v 1.243 2010/12/11 22:27:53 matt Exp $	*/
+/*	$NetBSD: systm.h,v 1.244 2010/12/30 12:46:34 pooka Exp $	*/
 
 /*-
  * Copyright (c) 1982, 1988, 1991, 1993
@@ -98,8 +98,8 @@
 extern bool mp_online;		/* secondary processors are started */
 #endif /* defined(_KERNEL) */
 
-extern const char hexdigits[];	/* 0123456789abcdef in subr_prf2.c */
-extern const char HEXDIGITS[];	/* 0123456789ABCDEF in subr_prf2.c */
+extern const char hexdigits[];	/* 0123456789abcdef in subr_prf.c */
+extern const char HEXDIGITS[];	/* 0123456789ABCDEF in subr_prf.c */
 
 /*
  * These represent the swap pseudo-device (`sw').  This device



CVS commit: src/sys/kern

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 13:38:10 UTC 2010

Modified Files:
src/sys/kern: makesyscalls.sh

Log Message:
whitespace polish in rump_syscalls.c


To generate a diff of this commit:
cvs rdiff -u -r1.105 -r1.106 src/sys/kern/makesyscalls.sh

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/makesyscalls.sh
diff -u src/sys/kern/makesyscalls.sh:1.105 src/sys/kern/makesyscalls.sh:1.106
--- src/sys/kern/makesyscalls.sh:1.105	Thu Dec 30 11:54:50 2010
+++ src/sys/kern/makesyscalls.sh	Thu Dec 30 13:38:10 2010
@@ -1,5 +1,5 @@
 #! /bin/sh -
-#	$NetBSD: makesyscalls.sh,v 1.105 2010/12/30 11:54:50 pooka Exp $
+#	$NetBSD: makesyscalls.sh,v 1.106 2010/12/30 13:38:10 pooka Exp $
 #
 # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou
 # All rights reserved.
@@ -591,7 +591,7 @@
 	if (!insysent) {
 		eno[0] = rump_enosys
 		eno[1] = sys_nomodule
-		printf(\t{ 0, 0, 0,\n\t(sy_call_t *)%s }, \t\t	\
+		printf(\t{ 0, 0, 0,\n\t(sy_call_t *)%s }, \t	\
 		/* %d = unrumped */\n,\
 		eno[modular], syscall)  rumpsysent
 		return
@@ -604,7 +604,7 @@
 		printf(ns(struct sys_%s%s_args), , compatwrap_, funcalias)  rumpsysent
 	}
 	printf(0,\n\t%s },, wfn)  rumpsysent
-	for (i = 0; i  (41 - length(wfn)) / 8; i++)
+	for (i = 0; i  (33 - length(wfn)) / 8; i++)
 		printf(\t)  rumpsysent
 	printf(/* %d = %s%s */\n, syscall, compatwrap_, funcalias)  rumpsysent
 }
@@ -768,7 +768,7 @@
 
 	printf(\t{ 0, 0, 0,\n\t%s },\t\t\t/* %d = %s */\n, \
 	sys_stub, syscall, comment)  sysent
-	printf(\t{ 0, 0, 0,\n\t%s },\t\t\t/* %d = %s */\n, \
+	printf(\t{ 0, 0, 0,\n\t%s },\t\t/* %d = %s */\n, \
 	(sy_call_t *)rump_enosys, syscall, comment)  rumpsysent
 	printf(\t/* %3d */\t\#%d (%s)\,\n, syscall, syscall, comment) \
 	 sysnamesbottom
@@ -815,7 +815,7 @@
 		while (syscall  nsysent) {
 			printf(\t{ 0, 0, 0,\n\t%s },\t\t\t/* %d = filler */\n, \
 			sys_nosys, syscall)  sysent
-			printf(\t{ 0, 0, 0,\n\t%s },\t\t\t/* %d = filler */\n, \
+			printf(\t{ 0, 0, 0,\n\t%s },\t\t/* %d = filler */\n, \
 			(sy_call_t *)rump_enosys, syscall)  rumpsysent
 			printf(\t/* %3d */\t\# filler\,\n, syscall) \
 			 sysnamesbottom



CVS commit: src

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 15:47:31 UTC 2010

Modified Files:
src/lib/librumpuser: rumpuser_dl.c
src/sys/rump/include/rump: rumpuser.h

Log Message:
Allow rump kernel to call dlsym(RTLD_DEFAULT).


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/lib/librumpuser/rumpuser_dl.c
cvs rdiff -u -r1.59 -r1.60 src/sys/rump/include/rump/rumpuser.h

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

Modified files:

Index: src/lib/librumpuser/rumpuser_dl.c
diff -u src/lib/librumpuser/rumpuser_dl.c:1.4 src/lib/librumpuser/rumpuser_dl.c:1.5
--- src/lib/librumpuser/rumpuser_dl.c:1.4	Tue Jun  8 15:32:55 2010
+++ src/lib/librumpuser/rumpuser_dl.c	Thu Dec 30 15:47:30 2010
@@ -1,4 +1,4 @@
-/*  $NetBSD: rumpuser_dl.c,v 1.4 2010/06/08 15:32:55 pooka Exp $	*/
+/*  $NetBSD: rumpuser_dl.c,v 1.5 2010/12/30 15:47:30 pooka Exp $	*/
 
 /*
  * Copyright (c) 2009 Antti Kantee.  All Rights Reserved.
@@ -31,7 +31,7 @@
  */
 
 #include sys/cdefs.h
-__RCSID($NetBSD: rumpuser_dl.c,v 1.4 2010/06/08 15:32:55 pooka Exp $);
+__RCSID($NetBSD: rumpuser_dl.c,v 1.5 2010/12/30 15:47:30 pooka Exp $);
 
 #include sys/types.h
 #include sys/time.h
@@ -428,3 +428,10 @@
 	fprintf(stderr, Warning, dlinfo() unsupported on host?\n);
 }
 #endif
+
+void *
+rumpuser_dl_globalsym(const char *symname)
+{
+
+	return dlsym(RTLD_DEFAULT, symname);
+}

Index: src/sys/rump/include/rump/rumpuser.h
diff -u src/sys/rump/include/rump/rumpuser.h:1.59 src/sys/rump/include/rump/rumpuser.h:1.60
--- src/sys/rump/include/rump/rumpuser.h:1.59	Thu Dec 16 12:38:20 2010
+++ src/sys/rump/include/rump/rumpuser.h	Thu Dec 30 15:47:30 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: rumpuser.h,v 1.59 2010/12/16 12:38:20 pooka Exp $	*/
+/*	$NetBSD: rumpuser.h,v 1.60 2010/12/30 15:47:30 pooka Exp $	*/
 
 /*
  * Copyright (c) 2007 Antti Kantee.  All Rights Reserved.
@@ -204,6 +204,7 @@
 typedef void (*rump_component_init_fn)(struct rump_component *, int);
 void rumpuser_dl_bootstrap(rump_modinit_fn, rump_symload_fn);
 void rumpuser_dl_component_init(int, rump_component_init_fn);
+void *rumpuser_dl_globalsym(const char *);
 
 /* syscall proxy routines */
 



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

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 16:19:39 UTC 2010

Modified Files:
src/sys/rump/librump/rumpnet: netisr.c

Log Message:
Refetch netisr function pointers with dlsym().  This gives the
desired values in case the components containing the netisr handlers
were not linked in but dlopen()'d before calling rump_init().

(could simplify a little in case static linking is declared dead)


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/rump/librump/rumpnet/netisr.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/rumpnet/netisr.c
diff -u src/sys/rump/librump/rumpnet/netisr.c:1.4 src/sys/rump/librump/rumpnet/netisr.c:1.5
--- src/sys/rump/librump/rumpnet/netisr.c:1.4	Tue May 26 23:43:39 2009
+++ src/sys/rump/librump/rumpnet/netisr.c	Thu Dec 30 16:19:39 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: netisr.c,v 1.4 2009/05/26 23:43:39 pooka Exp $	*/
+/*	$NetBSD: netisr.c,v 1.5 2010/12/30 16:19:39 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: netisr.c,v 1.4 2009/05/26 23:43:39 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: netisr.c,v 1.5 2010/12/30 16:19:39 pooka Exp $);
 
 #include sys/param.h
 #include sys/intr.h
@@ -38,6 +38,8 @@
 #include netinet6/ip6_var.h
 #include net/netisr.h
 
+#include rump/rumpuser.h
+
 #include rump_net_private.h
 
 static void *netisrs[NETISR_MAX];
@@ -49,44 +51,40 @@
 }
 
 /*
- * Provide weak aliases purely for linkage in case the real
- * networking stack isn't used
+ * Aliases are needed only for static linking (dlsym() is not supported).
  */
-void __ipintr_stub(void);
-void
-__ipintr_stub(void)
-{
-
-	panic(ipintr called but networking stack missing);
-}
-__weak_alias(ipintr,__ipintr_stub);
-
-void __arpintr_stub(void);
-void
-__arpintr_stub(void)
-{
-
-	panic(arpintr called but networking stack missing);
-}
-__weak_alias(arpintr,__arpintr_stub);
-
-void __ip6intr_stub(void);
+void __netisr_stub(void);
 void
-__ip6intr_stub(void)
+__netisr_stub(void)
 {
 
-	panic(ip6intr called but networking stack missing);
+	panic(netisr called but networking stack missing);
 }
-__weak_alias(ip6intr,__ip6intr_stub);
+__weak_alias(ipintr,__netisr_stub);
+__weak_alias(arpintr,__netisr_stub);
+__weak_alias(ip6intr,__netisr_stub);
 
 void
 rump_netisr_init(void)
 {
+	void *iphand, *arphand, *ip6hand, *sym;
 
+	iphand = ipintr;
+	if ((sym = rumpuser_dl_globalsym(rumpns_ipintr)) != NULL)
+		iphand = sym;
+
+	arphand = arpintr;
+	if ((sym = rumpuser_dl_globalsym(rumpns_arpintr)) != NULL)
+		arphand = sym;
+
+	ip6hand = ip6intr;
+	if ((sym = rumpuser_dl_globalsym(rumpns_ip6intr)) != NULL)
+		ip6hand = sym;
+		
 	netisrs[NETISR_IP] = softint_establish(SOFTINT_NET | SOFTINT_MPSAFE,
-	(void (*)(void *))ipintr, NULL);
+	(void (*)(void *))iphand, NULL);
 	netisrs[NETISR_ARP] = softint_establish(SOFTINT_NET | SOFTINT_MPSAFE,
-	(void (*)(void *))arpintr, NULL);
+	(void (*)(void *))arphand, NULL);
 	netisrs[NETISR_IPV6] = softint_establish(SOFTINT_NET | SOFTINT_MPSAFE,
-	(void (*)(void *))ip6intr, NULL);
+	(void (*)(void *))ip6hand, NULL);
 }



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

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 16:46:32 UTC 2010

Modified Files:
src/sys/rump/librump/rumpkern: rump.c

Log Message:
Requery syscall handlers during rump kernel init.  This fixes
syscalls provided by a rump faction such as rumpvfs when the library
is not linked into the binary, but is dlopen()'d before calling
rump_init().
(it is illegal to dlopen() a faction after rump_init(), but syscalls
maybe be added the usual way with modules)

rump_server(1) -lstuff works now.


To generate a diff of this commit:
cvs rdiff -u -r1.212 -r1.213 src/sys/rump/librump/rumpkern/rump.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/rumpkern/rump.c
diff -u src/sys/rump/librump/rumpkern/rump.c:1.212 src/sys/rump/librump/rumpkern/rump.c:1.213
--- src/sys/rump/librump/rumpkern/rump.c:1.212	Thu Dec 16 12:38:20 2010
+++ src/sys/rump/librump/rumpkern/rump.c	Thu Dec 30 16:46:32 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump.c,v 1.212 2010/12/16 12:38:20 pooka Exp $	*/
+/*	$NetBSD: rump.c,v 1.213 2010/12/30 16:46:32 pooka Exp $	*/
 
 /*
  * Copyright (c) 2007 Antti Kantee.  All Rights Reserved.
@@ -28,7 +28,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rump.c,v 1.212 2010/12/16 12:38:20 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: rump.c,v 1.213 2010/12/30 16:46:32 pooka Exp $);
 
 #include sys/systm.h
 #define ELFSIZE ARCH_ELFSIZE
@@ -440,6 +440,35 @@
 	if (initproc == NULL)
 		panic(where in the world is initproc?);
 
+	/*
+	 * Adjust syscall vector in case factions were dlopen()'d
+	 * before calling rump_init().
+	 * (modules will handle dynamic syscalls the usual way)
+	 *
+	 * Note: this will adjust the function vectors of
+	 * syscalls which use a funcalias (getpid etc.), but
+	 * it makes no difference.
+	 */
+	for (i = 0; i  SYS_NSYSENT; i++) {
+		void *sym;
+
+		if (rump_sysent[i].sy_flags  SYCALL_NOSYS ||
+		*syscallnames[i] == '#' ||
+		rump_sysent[i].sy_call == sys_nomodule)
+			continue;
+
+		/* if present, adjust symbol value */
+		sprintf(buf, rumpns_sys_%s, syscallnames[i]);
+		if ((sym = rumpuser_dl_globalsym(buf)) != NULL
+		 sym != rump_sysent[i].sy_call) {
+#if 0
+			rumpuser_dprintf(adjusting %s: %p (old %p)\n,
+			syscallnames[i], sym, rump_sysent[i].sy_call);
+#endif
+			rump_sysent[i].sy_call = sym;
+		}
+	}
+
 	/* release cpu */
 	rump_unschedule();
 



CVS commit: src/sys

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 16:49:25 UTC 2010

Modified Files:
src/sys/kern: makesyscalls.sh
src/sys/sys: systm.h

Log Message:
Mark syscalls not supported by a rump kernel with SYCALL_NOSYS, as
pure function pointer comparison brings weak alias confusion (weak
aliases are necessary for static linkage).


To generate a diff of this commit:
cvs rdiff -u -r1.106 -r1.107 src/sys/kern/makesyscalls.sh
cvs rdiff -u -r1.244 -r1.245 src/sys/sys/systm.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/kern/makesyscalls.sh
diff -u src/sys/kern/makesyscalls.sh:1.106 src/sys/kern/makesyscalls.sh:1.107
--- src/sys/kern/makesyscalls.sh:1.106	Thu Dec 30 13:38:10 2010
+++ src/sys/kern/makesyscalls.sh	Thu Dec 30 16:49:24 2010
@@ -1,5 +1,5 @@
 #! /bin/sh -
-#	$NetBSD: makesyscalls.sh,v 1.106 2010/12/30 13:38:10 pooka Exp $
+#	$NetBSD: makesyscalls.sh,v 1.107 2010/12/30 16:49:24 pooka Exp $
 #
 # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou
 # All rights reserved.
@@ -591,9 +591,11 @@
 	if (!insysent) {
 		eno[0] = rump_enosys
 		eno[1] = sys_nomodule
-		printf(\t{ 0, 0, 0,\n\t(sy_call_t *)%s }, \t	\
+		flags[0] = SYCALL_NOSYS
+		flags[1] = 0
+		printf(\t{ 0, 0, %s,\n\t(sy_call_t *)%s }, \t	\
 		/* %d = unrumped */\n,\
-		eno[modular], syscall)  rumpsysent
+		flags[modular], eno[modular], syscall)  rumpsysent
 		return
 	}
 
@@ -768,7 +770,7 @@
 
 	printf(\t{ 0, 0, 0,\n\t%s },\t\t\t/* %d = %s */\n, \
 	sys_stub, syscall, comment)  sysent
-	printf(\t{ 0, 0, 0,\n\t%s },\t\t/* %d = %s */\n, \
+	printf(\t{ 0, 0, SYCALL_NOSYS,\n\t%s },\t\t/* %d = %s */\n, \
 	(sy_call_t *)rump_enosys, syscall, comment)  rumpsysent
 	printf(\t/* %3d */\t\#%d (%s)\,\n, syscall, syscall, comment) \
 	 sysnamesbottom
@@ -815,7 +817,7 @@
 		while (syscall  nsysent) {
 			printf(\t{ 0, 0, 0,\n\t%s },\t\t\t/* %d = filler */\n, \
 			sys_nosys, syscall)  sysent
-			printf(\t{ 0, 0, 0,\n\t%s },\t\t/* %d = filler */\n, \
+			printf(\t{ 0, 0, SYCALL_NOSYS,\n\t%s },\t\t/* %d = filler */\n, \
 			(sy_call_t *)rump_enosys, syscall)  rumpsysent
 			printf(\t/* %3d */\t\# filler\,\n, syscall) \
 			 sysnamesbottom

Index: src/sys/sys/systm.h
diff -u src/sys/sys/systm.h:1.244 src/sys/sys/systm.h:1.245
--- src/sys/sys/systm.h:1.244	Thu Dec 30 12:46:34 2010
+++ src/sys/sys/systm.h	Thu Dec 30 16:49:25 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: systm.h,v 1.244 2010/12/30 12:46:34 pooka Exp $	*/
+/*	$NetBSD: systm.h,v 1.245 2010/12/30 16:49:25 pooka Exp $	*/
 
 /*-
  * Copyright (c) 1982, 1988, 1991, 1993
@@ -139,6 +139,7 @@
 #define SYCALL_ARG5_64  0x040
 #define SYCALL_ARG6_64  0x080
 #define SYCALL_ARG7_64  0x100
+#define SYCALL_NOSYS0x200 /* permanent nosys in sysent[] */
 #define SYCALL_RET_64_P(sy)	((sy)-sy_flags  SYCALL_RET_64)
 #define SYCALL_ARG_64_P(sy, n)	((sy)-sy_flags  (SYCALL_ARG0_64  (n)))
 #define	SYCALL_ARG_64_MASK(sy)	(((sy)-sy_flags  17)  0xff)



CVS commit: src/sys/rump

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 16:51:28 UTC 2010

Modified Files:
src/sys/rump/include/rump: rump_syscalls.h
src/sys/rump/librump/rumpkern: rump_syscalls.c

Log Message:
regen: SYCALL_NOSYS in rump_sysent[]


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/sys/rump/include/rump/rump_syscalls.h
cvs rdiff -u -r1.56 -r1.57 src/sys/rump/librump/rumpkern/rump_syscalls.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/include/rump/rump_syscalls.h
diff -u src/sys/rump/include/rump/rump_syscalls.h:1.34 src/sys/rump/include/rump/rump_syscalls.h:1.35
--- src/sys/rump/include/rump/rump_syscalls.h:1.34	Wed Nov 17 21:48:07 2010
+++ src/sys/rump/include/rump/rump_syscalls.h	Thu Dec 30 16:51:28 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: rump_syscalls.h,v 1.34 2010/11/17 21:48:07 pooka Exp $ */
+/* $NetBSD: rump_syscalls.h,v 1.35 2010/12/30 16:51:28 pooka Exp $ */
 
 /*
  * System call protos in rump namespace.

Index: src/sys/rump/librump/rumpkern/rump_syscalls.c
diff -u src/sys/rump/librump/rumpkern/rump_syscalls.c:1.56 src/sys/rump/librump/rumpkern/rump_syscalls.c:1.57
--- src/sys/rump/librump/rumpkern/rump_syscalls.c:1.56	Thu Dec 30 13:38:56 2010
+++ src/sys/rump/librump/rumpkern/rump_syscalls.c	Thu Dec 30 16:51:28 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: rump_syscalls.c,v 1.56 2010/12/30 13:38:56 pooka Exp $ */
+/* $NetBSD: rump_syscalls.c,v 1.57 2010/12/30 16:51:28 pooka Exp $ */
 
 /*
  * System call vector and marshalling for rump.
@@ -8,7 +8,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rump_syscalls.c,v 1.56 2010/12/30 13:38:56 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: rump_syscalls.c,v 1.57 2010/12/30 16:51:28 pooka Exp $);
 
 #include sys/param.h
 #include sys/fstypes.h
@@ -3109,11 +3109,11 @@
 #define	ns(type)	n(type), s(type)
 
 struct sysent rump_sysent[] = {
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 0 = unrumped */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 1 = unrumped */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 2 = unrumped */
 	{ ns(struct sys_read_args), 0,
 	(sy_call_t *)sys_read },		/* 3 = read */
@@ -3131,7 +3131,7 @@
 	(sy_call_t *)sys_link },		/* 9 = link */
 	{ ns(struct sys_unlink_args), 0,
 	(sy_call_t *)sys_unlink },		/* 10 = unlink */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys },		/* 11 = obsolete execv */
 	{ ns(struct sys_chdir_args), 0,
 	(sy_call_t *)sys_chdir },		/* 12 = chdir */
@@ -3143,7 +3143,7 @@
 	(sy_call_t *)sys_chmod },		/* 15 = chmod */
 	{ ns(struct sys_chown_args), 0,
 	(sy_call_t *)sys_chown },		/* 16 = chown */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 17 = unrumped */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_nomodule }, 	/* 18 = unrumped */
@@ -3161,7 +3161,7 @@
 	(sy_call_t *)sys_getuid_with_euid },/* 24 = getuid */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_geteuid },		/* 25 = geteuid */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 26 = unrumped */
 	{ ns(struct sys_recvmsg_args), 0,
 	(sy_call_t *)sys_recvmsg },		/* 27 = recvmsg */
@@ -3183,7 +3183,7 @@
 	(sy_call_t *)sys_fchflags },	/* 35 = fchflags */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_sync },		/* 36 = sync */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 37 = unrumped */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_nomodule }, 	/* 38 = unrumped */
@@ -3197,9 +3197,9 @@
 	(sy_call_t *)sys_pipe },		/* 42 = pipe */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_getegid },		/* 43 = getegid */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 44 = unrumped */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 45 = unrumped */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_nomodule }, 	/* 46 = unrumped */
@@ -3211,7 +3211,7 @@
 	(sy_call_t *)sys___getlogin },	/* 49 = __getlogin */
 	{ ns(struct sys___setlogin_args), 0,
 	(sy_call_t *)sys___setlogin },	/* 50 = __setlogin */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 51 = unrumped */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_nomodule }, 	/* 52 = unrumped */
@@ -3227,7 +3227,7 @@
 	(sy_call_t *)sys_symlink },		/* 57 = symlink */
 	{ ns(struct sys_readlink_args), 0,
 	(sy_call_t *)sys_readlink },	/* 58 = readlink */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 59 = unrumped */
 	{ ns(struct sys_umask_args), 0,
 	(sy_call_t *)sys_umask },		/* 60 = umask */
@@ -3241,31 +3241,31 @@
 	(sy_call_t *)sys_nomodule }, 	/* 64 = unrumped */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_nomodule }, 	/* 65 = unrumped */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys }, 	/* 66 = unrumped */
-	{ 0, 0, 0,
+	{ 0, 0, SYCALL_NOSYS,
 	(sy_call_t *)rump_enosys },		/* 67 = 

CVS commit: src/sys/modules/acpicpu

2010-12-30 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Thu Dec 30 18:38:51 UTC 2010

Modified Files:
src/sys/modules/acpicpu: Makefile

Log Message:
Remove DIAGNOSTIC.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/modules/acpicpu/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/modules/acpicpu/Makefile
diff -u src/sys/modules/acpicpu/Makefile:1.4 src/sys/modules/acpicpu/Makefile:1.5
--- src/sys/modules/acpicpu/Makefile:1.4	Wed Aug 18 19:33:10 2010
+++ src/sys/modules/acpicpu/Makefile	Thu Dec 30 18:38:50 2010
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.4 2010/08/18 19:33:10 jruoho Exp $
+# $NetBSD: Makefile,v 1.5 2010/12/30 18:38:50 jruoho Exp $
 
 .include ../Makefile.inc
 
@@ -13,6 +13,5 @@
 	acpi_cpu_tstate.c
 
 WARNS=	 4
-CFLAGS+= -DDIAGNOSTIC
 
 .include bsd.kmodule.mk



CVS commit: src/sys/dev/pci

2010-12-30 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Thu Dec 30 19:27:28 UTC 2010

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

Log Message:
Use temperature rather than TEMP as the sensor name. No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.51 -r1.52 src/sys/dev/pci/if_iwn.c

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

Modified files:

Index: src/sys/dev/pci/if_iwn.c
diff -u src/sys/dev/pci/if_iwn.c:1.51 src/sys/dev/pci/if_iwn.c:1.52
--- src/sys/dev/pci/if_iwn.c:1.51	Thu Dec 30 18:27:01 2010
+++ src/sys/dev/pci/if_iwn.c	Thu Dec 30 19:27:27 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_iwn.c,v 1.51 2010/12/30 18:27:01 jruoho Exp $	*/
+/*	$NetBSD: if_iwn.c,v 1.52 2010/12/30 19:27:27 jruoho Exp $	*/
 /*	$OpenBSD: if_iwn.c,v 1.96 2010/05/13 09:25:03 damien Exp $	*/
 
 /*-
@@ -22,7 +22,7 @@
  * adapters.
  */
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: if_iwn.c,v 1.51 2010/12/30 18:27:01 jruoho Exp $);
+__KERNEL_RCSID(0, $NetBSD: if_iwn.c,v 1.52 2010/12/30 19:27:27 jruoho Exp $);
 
 #define IWN_USE_RBUF	/* Use local storage for RX */
 #undef IWN_HWCRYPTO	/* XXX does not even compile yet */
@@ -768,7 +768,8 @@
 	sc-sc_sensor.flags = ENVSYS_FMONLIMITS | ENVSYS_FMONNOTSUPP;
 	sc-sc_sensor.limits.sel_critmax = IWN_CTOK(110);
 #endif
-	strlcpy((sc-sc_sensor.desc), TEMP, sizeof(sc-sc_sensor.desc));
+	(void)strlcpy(sc-sc_sensor.desc,
+	temperature, sizeof(sc-sc_sensor.desc));
 
 	/* Temperature is not valid unless interface is up. */
 	sc-sc_sensor.value_cur = 0;



CVS commit: src/sys/dev/usb

2010-12-30 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu Dec 30 19:27:51 UTC 2010

Modified Files:
src/sys/dev/usb: usbdevs

Log Message:
Add HP v125w flash drive.


To generate a diff of this commit:
cvs rdiff -u -r1.572 -r1.573 src/sys/dev/usb/usbdevs

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/usbdevs
diff -u src/sys/dev/usb/usbdevs:1.572 src/sys/dev/usb/usbdevs:1.573
--- src/sys/dev/usb/usbdevs:1.572	Fri Dec 24 19:22:17 2010
+++ src/sys/dev/usb/usbdevs	Thu Dec 30 19:27:51 2010
@@ -1,4 +1,4 @@
-$NetBSD: usbdevs,v 1.572 2010/12/24 19:22:17 jmcneill Exp $
+$NetBSD: usbdevs,v 1.573 2010/12/30 19:27:51 jakllsch Exp $
 
 /*
  * Copyright (c) 1998-2004 The NetBSD Foundation, Inc.
@@ -1464,6 +1464,7 @@
 product HP 640C			0x2004	DeskJet 640c
 product HP 4670V		0x3005	ScanJet 4670v
 product HP P1100		0x3102	Photosmart P1100
+product HP V125W		0x3307	v125w
 product HP 6127			0x3504	Deskjet 6127
 product HP HN210E		0x811c	Ethernet HN210E
 



CVS commit: src/sys/dev/usb

2010-12-30 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu Dec 30 19:35:33 UTC 2010

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

Log Message:
HP v125w flash drive doesn't like PREVENT/ALLOW either.
Reported by Gary Duzan on current-users;
http://mail-index.netbsd.org/current-users/2010/12/30/msg015240.html


To generate a diff of this commit:
cvs rdiff -u -r1.83 -r1.84 src/sys/dev/usb/umass_quirks.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/umass_quirks.c
diff -u src/sys/dev/usb/umass_quirks.c:1.83 src/sys/dev/usb/umass_quirks.c:1.84
--- src/sys/dev/usb/umass_quirks.c:1.83	Wed Nov  3 22:34:24 2010
+++ src/sys/dev/usb/umass_quirks.c	Thu Dec 30 19:35:33 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: umass_quirks.c,v 1.83 2010/11/03 22:34:24 dyoung Exp $	*/
+/*	$NetBSD: umass_quirks.c,v 1.84 2010/12/30 19:35:33 jakllsch Exp $	*/
 
 /*
  * Copyright (c) 2001, 2004 The NetBSD Foundation, Inc.
@@ -32,7 +32,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: umass_quirks.c,v 1.83 2010/11/03 22:34:24 dyoung Exp $);
+__KERNEL_RCSID(0, $NetBSD: umass_quirks.c,v 1.84 2010/12/30 19:35:33 jakllsch Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -277,6 +277,15 @@
 	  UMATCH_VENDOR_PRODUCT,
 	  NULL, NULL
 	},
+
+	/* HP USB pendrives don't like being told to lock the door */
+	{ { USB_VENDOR_HP, USB_PRODUCT_HP_V125W },
+	  UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
+	  0,
+	  PQUIRK_NODOORLOCK,
+	  UMATCH_VENDOR_PRODUCT,
+	  NULL, NULL
+	},
 };
 
 const struct umass_quirk *



CVS commit: src/sys/kern

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 20:09:53 UTC 2010

Modified Files:
src/sys/kern: makesyscalls.sh

Log Message:
Include system call name in comment even for unimplemented syscalls
in rump_syscalls.c.


To generate a diff of this commit:
cvs rdiff -u -r1.107 -r1.108 src/sys/kern/makesyscalls.sh

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/makesyscalls.sh
diff -u src/sys/kern/makesyscalls.sh:1.107 src/sys/kern/makesyscalls.sh:1.108
--- src/sys/kern/makesyscalls.sh:1.107	Thu Dec 30 16:49:24 2010
+++ src/sys/kern/makesyscalls.sh	Thu Dec 30 20:09:53 2010
@@ -1,5 +1,5 @@
 #! /bin/sh -
-#	$NetBSD: makesyscalls.sh,v 1.107 2010/12/30 16:49:24 pooka Exp $
+#	$NetBSD: makesyscalls.sh,v 1.108 2010/12/30 20:09:53 pooka Exp $
 #
 # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou
 # All rights reserved.
@@ -594,8 +594,9 @@
 		flags[0] = SYCALL_NOSYS
 		flags[1] = 0
 		printf(\t{ 0, 0, %s,\n\t(sy_call_t *)%s }, \t	\
-		/* %d = unrumped */\n,\
-		flags[modular], eno[modular], syscall)  rumpsysent
+		/* %d = %s */\n,	\
+		flags[modular], eno[modular], syscall, funcalias)	\
+		 rumpsysent
 		return
 	}
 



CVS commit: src/sys/rump

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 20:11:08 UTC 2010

Modified Files:
src/sys/rump/include/rump: rump_syscalls.h
src/sys/rump/librump/rumpkern: rump_syscalls.c

Log Message:
regen for comments


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/sys/rump/include/rump/rump_syscalls.h
cvs rdiff -u -r1.57 -r1.58 src/sys/rump/librump/rumpkern/rump_syscalls.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/include/rump/rump_syscalls.h
diff -u src/sys/rump/include/rump/rump_syscalls.h:1.35 src/sys/rump/include/rump/rump_syscalls.h:1.36
--- src/sys/rump/include/rump/rump_syscalls.h:1.35	Thu Dec 30 16:51:28 2010
+++ src/sys/rump/include/rump/rump_syscalls.h	Thu Dec 30 20:11:07 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: rump_syscalls.h,v 1.35 2010/12/30 16:51:28 pooka Exp $ */
+/* $NetBSD: rump_syscalls.h,v 1.36 2010/12/30 20:11:07 pooka Exp $ */
 
 /*
  * System call protos in rump namespace.

Index: src/sys/rump/librump/rumpkern/rump_syscalls.c
diff -u src/sys/rump/librump/rumpkern/rump_syscalls.c:1.57 src/sys/rump/librump/rumpkern/rump_syscalls.c:1.58
--- src/sys/rump/librump/rumpkern/rump_syscalls.c:1.57	Thu Dec 30 16:51:28 2010
+++ src/sys/rump/librump/rumpkern/rump_syscalls.c	Thu Dec 30 20:11:07 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: rump_syscalls.c,v 1.57 2010/12/30 16:51:28 pooka Exp $ */
+/* $NetBSD: rump_syscalls.c,v 1.58 2010/12/30 20:11:07 pooka Exp $ */
 
 /*
  * System call vector and marshalling for rump.
@@ -8,7 +8,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rump_syscalls.c,v 1.57 2010/12/30 16:51:28 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: rump_syscalls.c,v 1.58 2010/12/30 20:11:07 pooka Exp $);
 
 #include sys/param.h
 #include sys/fstypes.h
@@ -3110,11 +3110,11 @@
 
 struct sysent rump_sysent[] = {
 	{ 0, 0, SYCALL_NOSYS,
-	(sy_call_t *)rump_enosys }, 	/* 0 = unrumped */
+	(sy_call_t *)rump_enosys }, 	/* 0 = syscall */
 	{ 0, 0, SYCALL_NOSYS,
-	(sy_call_t *)rump_enosys }, 	/* 1 = unrumped */
+	(sy_call_t *)rump_enosys }, 	/* 1 = exit */
 	{ 0, 0, SYCALL_NOSYS,
-	(sy_call_t *)rump_enosys }, 	/* 2 = unrumped */
+	(sy_call_t *)rump_enosys }, 	/* 2 = fork */
 	{ ns(struct sys_read_args), 0,
 	(sy_call_t *)sys_read },		/* 3 = read */
 	{ ns(struct sys_write_args), 0,
@@ -3124,9 +3124,9 @@
 	{ ns(struct sys_close_args), 0,
 	(sy_call_t *)sys_close },		/* 6 = close */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 7 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 7 = wait4 */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 8 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 8 = ocreat */
 	{ ns(struct sys_link_args), 0,
 	(sy_call_t *)sys_link },		/* 9 = link */
 	{ ns(struct sys_unlink_args), 0,
@@ -3138,21 +3138,21 @@
 	{ ns(struct sys_fchdir_args), 0,
 	(sy_call_t *)sys_fchdir },		/* 13 = fchdir */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 14 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 14 = mknod */
 	{ ns(struct sys_chmod_args), 0,
 	(sy_call_t *)sys_chmod },		/* 15 = chmod */
 	{ ns(struct sys_chown_args), 0,
 	(sy_call_t *)sys_chown },		/* 16 = chown */
 	{ 0, 0, SYCALL_NOSYS,
-	(sy_call_t *)rump_enosys }, 	/* 17 = unrumped */
+	(sy_call_t *)rump_enosys }, 	/* 17 = break */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 18 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 18 = getfsstat */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 19 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 19 = olseek */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_getpid_with_ppid },/* 20 = getpid */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 21 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 21 = mount */
 	{ ns(struct sys_unmount_args), 0,
 	(sy_call_t *)sys_unmount },		/* 22 = unmount */
 	{ ns(struct sys_setuid_args), 0,
@@ -3162,7 +3162,7 @@
 	{ 0, 0, 0,
 	(sy_call_t *)sys_geteuid },		/* 25 = geteuid */
 	{ 0, 0, SYCALL_NOSYS,
-	(sy_call_t *)rump_enosys }, 	/* 26 = unrumped */
+	(sy_call_t *)rump_enosys }, 	/* 26 = ptrace */
 	{ ns(struct sys_recvmsg_args), 0,
 	(sy_call_t *)sys_recvmsg },		/* 27 = recvmsg */
 	{ ns(struct sys_sendmsg_args), 0,
@@ -3184,13 +3184,13 @@
 	{ 0, 0, 0,
 	(sy_call_t *)sys_sync },		/* 36 = sync */
 	{ 0, 0, SYCALL_NOSYS,
-	(sy_call_t *)rump_enosys }, 	/* 37 = unrumped */
+	(sy_call_t *)rump_enosys }, 	/* 37 = kill */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 38 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 38 = stat43 */
 	{ 0, 0, 0,
 	(sy_call_t *)sys_getppid },		/* 39 = getppid */
 	{ 0, 0, 0,
-	(sy_call_t *)sys_nomodule }, 	/* 40 = unrumped */
+	(sy_call_t *)sys_nomodule }, 	/* 40 = lstat43 */
 	{ ns(struct sys_dup_args), 0,
 	(sy_call_t *)sys_dup },		/* 41 = dup */
 	{ 0, 0, 0,
@@ -3198,29 +3198,29 @@
 	{ 0, 0, 0,
 	(sy_call_t 

CVS commit: src/usr.sbin/ldpd

2010-12-30 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Thu Dec 30 21:26:00 UTC 2010

Modified Files:
src/usr.sbin/ldpd: conffile.c

Log Message:
- detect calloc failure
- int - size_t
- cache strlen
- proper cast for ctype macro


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/usr.sbin/ldpd/conffile.c

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

Modified files:

Index: src/usr.sbin/ldpd/conffile.c
diff -u src/usr.sbin/ldpd/conffile.c:1.1 src/usr.sbin/ldpd/conffile.c:1.2
--- src/usr.sbin/ldpd/conffile.c:1.1	Thu Dec 30 06:29:21 2010
+++ src/usr.sbin/ldpd/conffile.c	Thu Dec 30 16:26:00 2010
@@ -1,4 +1,4 @@
-/* $NetBSD: conffile.c,v 1.1 2010/12/30 11:29:21 kefren Exp $ */
+/* $NetBSD: conffile.c,v 1.2 2010/12/30 21:26:00 christos Exp $ */
 
 /*
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -50,7 +50,7 @@
 struct in_addr conf_ldp_id;
 
 static int conf_dispatch(char*);
-static int conf_readline(char*, int);
+static int conf_readline(char*, size_t);
 static int checkeol(char*);
 static int Fhellotime(char*);
 static int Fport(char*);
@@ -111,9 +111,9 @@
  * Reads a line from config file
  */
 int
-conf_readline(char *buf, int bufsize)
+conf_readline(char *buf, size_t bufsize)
 {
-	int i;
+	size_t i;
 
 	for (i = 0; i  bufsize; i++) {
 		if (read(confh, buf[i], 1) != 1) {
@@ -123,7 +123,7 @@
 		}
 		if (buf[i] == '\n')
 			break;
-		if (i == 0  isspace((int)buf[i]) != 0) {
+		if (i == 0  isspace((unsigned char)buf[i]) != 0) {
 			i--;
 			continue;
 		}
@@ -170,11 +170,12 @@
 int
 checkeol(char *line)
 {
-	if (line[strlen(line) - 1] == ';') {
-		line[strlen(line) - 1] = '\0';
+	size_t len = strlen(line);
+	if (len  0  line[len - 1] == ';') {
+		line[len - 1] = '\0';
 		return 0;
 	}
-	for (uint i = 0; i  strlen(line); i++)
+	for (size_t i = 0; i  len; i++)
 		if (line[i] == '{')
 			return 0;
 	return -1;
@@ -273,10 +274,12 @@
 		return E_CONF_PARAM;
 
 	nei = calloc(1, sizeof(*nei));
+	if (nei == NULL)
+		return E_CONF_MEM;
 	nei-address.s_addr = ad.s_addr;
 	SLIST_INSERT_HEAD(conei_head, nei, neilist);
 
-	while(conf_readline(buf, sizeof(buf)) = 0) {
+	while (conf_readline(buf, sizeof(buf)) = 0) {
 		if (buf[0] == '}')
 			return 0;
 		if (Gneighbour(nei, buf) == -1)



CVS commit: src/tests/lib/libc/gen

2010-12-30 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Thu Dec 30 22:21:53 UTC 2010

Modified Files:
src/tests/lib/libc/gen: t_syslog_pthread.c

Log Message:
Test is no longer expected to hang.

PR lib/44248 closed when test associate with PR fails == brick dholland


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libc/gen/t_syslog_pthread.c

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

Modified files:

Index: src/tests/lib/libc/gen/t_syslog_pthread.c
diff -u src/tests/lib/libc/gen/t_syslog_pthread.c:1.1 src/tests/lib/libc/gen/t_syslog_pthread.c:1.2
--- src/tests/lib/libc/gen/t_syslog_pthread.c:1.1	Fri Dec 17 19:12:30 2010
+++ src/tests/lib/libc/gen/t_syslog_pthread.c	Thu Dec 30 22:21:53 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: t_syslog_pthread.c,v 1.1 2010/12/17 19:12:30 pooka Exp $	*/
+/*	$NetBSD: t_syslog_pthread.c,v 1.2 2010/12/30 22:21:53 pooka Exp $	*/
 
 /*-
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -44,7 +44,7 @@
 ATF_TC_BODY(basic, tc)
 {
 
-	atf_tc_expect_timeout(PR lib/44248);
+	//atf_tc_expect_timeout(PR lib/44248);
 	syslog(LOG_DEBUG, from tests/lib/libc/gen/t_syslog_pthread);
 }
 



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

2010-12-30 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu Dec 30 22:27:43 UTC 2010

Modified Files:
src/sys/arch/i386/stand/lib: biosdisk_ll.c

Log Message:
Make this actually build with DISK_DEBUG.


To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/sys/arch/i386/stand/lib/biosdisk_ll.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/i386/stand/lib/biosdisk_ll.c
diff -u src/sys/arch/i386/stand/lib/biosdisk_ll.c:1.28 src/sys/arch/i386/stand/lib/biosdisk_ll.c:1.29
--- src/sys/arch/i386/stand/lib/biosdisk_ll.c:1.28	Sat Dec 25 01:19:33 2010
+++ src/sys/arch/i386/stand/lib/biosdisk_ll.c	Thu Dec 30 22:27:43 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: biosdisk_ll.c,v 1.28 2010/12/25 01:19:33 jakllsch Exp $	 */
+/*	$NetBSD: biosdisk_ll.c,v 1.29 2010/12/30 22:27:43 jakllsch Exp $	 */
 
 /*-
  * Copyright (c) 2005 The NetBSD Foundation, Inc.
@@ -69,6 +69,7 @@
  * needs lowlevel parts from bios_disk.S
  */
 
+#include lib/libkern/libkern.h
 #include lib/libsa/stand.h
 
 #include biosdisk_ll.h
@@ -264,7 +265,7 @@
 			while ((nsec = do_read(d, dblk, maxsecs, trbuf))  0) {
 #ifdef DISK_DEBUG
 if (!cold)
-	printf(read error dblk %PRId64-%PRId64\n,
+	printf(read error dblk %PRId64-%PRId64\n,
 	dblk, (dblk + maxsecs - 1));
 #endif
 if (--retries = 0)



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

2010-12-30 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Thu Dec 30 22:28:53 UTC 2010

Modified Files:
src/sys/arch/i386/stand/lib: biosdisk.c

Log Message:
Fix DISK_DEBUG build.


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/sys/arch/i386/stand/lib/biosdisk.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/i386/stand/lib/biosdisk.c
diff -u src/sys/arch/i386/stand/lib/biosdisk.c:1.33 src/sys/arch/i386/stand/lib/biosdisk.c:1.34
--- src/sys/arch/i386/stand/lib/biosdisk.c:1.33	Sat Dec 25 01:19:33 2010
+++ src/sys/arch/i386/stand/lib/biosdisk.c	Thu Dec 30 22:28:53 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: biosdisk.c,v 1.33 2010/12/25 01:19:33 jakllsch Exp $	*/
+/*	$NetBSD: biosdisk.c,v 1.34 2010/12/30 22:28:53 jakllsch Exp $	*/
 
 /*
  * Copyright (c) 1996, 1998
@@ -234,7 +234,7 @@
 continue;
 			sector = this_ext + mbr[i].mbrp_start;
 #ifdef DISK_DEBUG
-			printf(ptn type %d in sector %PRId64\n, typ, sector);
+			printf(ptn type %d in sector %d\n, typ, sector);
 #endif
 			if (typ == MBR_PTYPE_NETBSD) {
 error = check_label(d, sector);
@@ -485,7 +485,7 @@
 #endif /* NO_DISKLABEL */
 
 #ifdef DISK_DEBUG
-	printf(partition @%d\n, d-boff);
+	printf(partition @%PRId64\n, d-boff);
 #endif
 
 #ifdef _STANDALONE



CVS commit: src/tests/dev/sysmon

2010-12-30 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Fri Dec 31 00:35:42 UTC 2010

Modified Files:
src/tests/dev/sysmon: t_swsensor.sh

Log Message:
Now that 'rump_server -l stuff' works, use a less heavyweight rump_server
for this test.  Thanks, pooka!


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tests/dev/sysmon/t_swsensor.sh

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

Modified files:

Index: src/tests/dev/sysmon/t_swsensor.sh
diff -u src/tests/dev/sysmon/t_swsensor.sh:1.3 src/tests/dev/sysmon/t_swsensor.sh:1.4
--- src/tests/dev/sysmon/t_swsensor.sh:1.3	Thu Dec 30 04:01:59 2010
+++ src/tests/dev/sysmon/t_swsensor.sh	Fri Dec 31 00:35:42 2010
@@ -1,4 +1,4 @@
-# $NetBSD: t_swsensor.sh,v 1.3 2010/12/30 04:01:59 pgoyette Exp $
+# $NetBSD: t_swsensor.sh,v 1.4 2010/12/31 00:35:42 pgoyette Exp $
 
 get_sensor_info() {
 	rump.envstat -x | \
@@ -40,7 +40,7 @@
 # requested properties
 
 start_rump() {
-	rump_allserver ${RUMP_SERVER}
+	rump_server -l rumpvfs -l rumpdev -l rumpdev_sysmon ${RUMP_SERVER}
 	if [ $( get_sensor_info | wc -l ) -ne 0 ] ; then
 		rump.modunload swsensor
 		rump.modload -f $1 swsensor
@@ -53,8 +53,8 @@
 common_head() {
 	atf_set	descr		$1
 	atf_set	timeout		60
-	atf_set	require.progs	rump.powerd rump.envstat rump.modload   \
-rump.halt   rump.sysctl  rump_allserver \
+	atf_set	require.progs	rump.powerd rump.envstat rump.modload	\
+rump.halt   rump.sysctl  rump_server	\
 sed grep
 }
 



CVS commit: src

2010-12-30 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Fri Dec 31 04:08:33 UTC 2010

Modified Files:
src/distrib/sets/lists/tests: mi
src/tests/lib/libc: Makefile
Added Files:
src/tests/lib/libc: t_convfp.c t_gdtoa.c t_randomid.c

Log Message:
Migrate a few miscellaneous tests from the old regress to atf


To generate a diff of this commit:
cvs rdiff -u -r1.197 -r1.198 src/distrib/sets/lists/tests/mi
cvs rdiff -u -r1.12 -r1.13 src/tests/lib/libc/Makefile
cvs rdiff -u -r0 -r1.1 src/tests/lib/libc/t_convfp.c \
src/tests/lib/libc/t_gdtoa.c src/tests/lib/libc/t_randomid.c

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

Modified files:

Index: src/distrib/sets/lists/tests/mi
diff -u src/distrib/sets/lists/tests/mi:1.197 src/distrib/sets/lists/tests/mi:1.198
--- src/distrib/sets/lists/tests/mi:1.197	Tue Dec 28 16:57:00 2010
+++ src/distrib/sets/lists/tests/mi	Fri Dec 31 04:08:32 2010
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.197 2010/12/28 16:57:00 pgoyette Exp $
+# $NetBSD: mi,v 1.198 2010/12/31 04:08:32 pgoyette Exp $
 #
 # Note: don't delete entries from here - mark them as obsolete instead.
 #
@@ -367,6 +367,9 @@
 ./usr/libdata/debug/usr/tests/lib/libc/string/t_string.debug		tests-lib-debug		debug,atf
 ./usr/libdata/debug/usr/tests/lib/libc/string/t_stresep.debug		tests-lib-debug		debug,atf
 ./usr/libdata/debug/usr/tests/lib/libc/string/t_swab.debug		tests-lib-debug		debug,atf
+./usr/libdata/debug/usr/tests/lib/libc/t_convfp.debug			tests-lib-debug		debug,atf
+./usr/libdata/debug/usr/tests/lib/libc/t_gdtoa.debug			tests-lib-debug		debug,atf
+./usr/libdata/debug/usr/tests/lib/libc/t_randomid.debug			tests-lib-debug		debug,atf
 ./usr/libdata/debug/usr/tests/lib/libdestests-lib-debug
 ./usr/libdata/debug/usr/tests/lib/libdes/t_des.debug			tests-lib-debug		debug,atf,crypto
 ./usr/libdata/debug/usr/tests/lib/semaphoretests-lib-debug
@@ -1626,6 +1629,9 @@
 ./usr/tests/lib/libc/string/t_string		tests-lib-tests		atf
 ./usr/tests/lib/libc/string/t_stresep		tests-lib-tests		atf
 ./usr/tests/lib/libc/string/t_swab		tests-lib-tests		atf
+./usr/tests/lib/libc/t_convfp			tests-lib-tests		atf
+./usr/tests/lib/libc/t_gdtoa			tests-lib-tests		atf
+./usr/tests/lib/libc/t_randomid			tests-lib-tests		atf
 ./usr/tests/lib/libdestests-lib-tests
 ./usr/tests/lib/libdes/Atffile			tests-lib-tests		atf,crypto
 ./usr/tests/lib/libdes/t_des			tests-lib-tests		atf,crypto

Index: src/tests/lib/libc/Makefile
diff -u src/tests/lib/libc/Makefile:1.12 src/tests/lib/libc/Makefile:1.13
--- src/tests/lib/libc/Makefile:1.12	Mon Dec 27 19:35:30 2010
+++ src/tests/lib/libc/Makefile	Fri Dec 31 04:08:33 2010
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.12 2010/12/27 19:35:30 pgoyette Exp $
+# $NetBSD: Makefile,v 1.13 2010/12/31 04:08:33 pgoyette Exp $
 
 .include bsd.own.mk
 .include bsd.sys.mk
@@ -9,6 +9,14 @@
 TESTS_SUBDIRS+=	ssp
 .endif
 
+.if (${MACHINE_ARCH} != vax  ${MACHINE_ARCH} != m68000)
+SUBDIR+= ieeefp
+.endif
+
 TESTSDIR=	${TESTSBASE}/lib/libc
 
+TESTS_C+=	t_convfp
+TESTS_C+=	t_gdtoa
+TESTS_C+=	t_randomid
+
 .include bsd.test.mk

Added files:

Index: src/tests/lib/libc/t_convfp.c
diff -u /dev/null src/tests/lib/libc/t_convfp.c:1.1
--- /dev/null	Fri Dec 31 04:08:33 2010
+++ src/tests/lib/libc/t_convfp.c	Fri Dec 31 04:08:33 2010
@@ -0,0 +1,147 @@
+/*	$NetBSD: t_convfp.c,v 1.1 2010/12/31 04:08:33 pgoyette Exp $	*/
+
+/*-
+ * Copyright (c) 2003 The NetBSD Foundation, Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *notice, this list of conditions and the following disclaimer in the
+ *documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include atf-c.h
+
+#include limits.h
+#include stdio.h
+#include stdlib.h
+
+/*
+ * This value is representable as an unsigned int, but 

CVS commit: src/regress/lib/libc

2010-12-30 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Fri Dec 31 04:10:43 UTC 2010

Modified Files:
src/regress/lib/libc: Makefile
Removed Files:
src/regress/lib/libc/convfp: Makefile convfp.c
src/regress/lib/libc/gdtoa: Makefile gdtoa.c
src/regress/lib/libc/randomid: Makefile idtest.c

Log Message:
These tests have been atf-ified


To generate a diff of this commit:
cvs rdiff -u -r1.66 -r1.67 src/regress/lib/libc/Makefile
cvs rdiff -u -r1.2 -r0 src/regress/lib/libc/convfp/Makefile
cvs rdiff -u -r1.7 -r0 src/regress/lib/libc/convfp/convfp.c
cvs rdiff -u -r1.1 -r0 src/regress/lib/libc/gdtoa/Makefile \
src/regress/lib/libc/gdtoa/gdtoa.c
cvs rdiff -u -r1.1 -r0 src/regress/lib/libc/randomid/Makefile
cvs rdiff -u -r1.5 -r0 src/regress/lib/libc/randomid/idtest.c

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

Modified files:

Index: src/regress/lib/libc/Makefile
diff -u src/regress/lib/libc/Makefile:1.66 src/regress/lib/libc/Makefile:1.67
--- src/regress/lib/libc/Makefile:1.66	Tue Dec 28 17:35:25 2010
+++ src/regress/lib/libc/Makefile	Fri Dec 31 04:10:41 2010
@@ -1,8 +1,8 @@
-#	$NetBSD: Makefile,v 1.66 2010/12/28 17:35:25 pgoyette Exp $
+#	$NetBSD: Makefile,v 1.67 2010/12/31 04:10:41 pgoyette Exp $
 
-SUBDIR+= atexit citrus clone context convfp db \
-	divrem gdtoa getaddrinfo hsearch inet int_fmtio locale md5sha \
-	nsdispatch pty randomid regex rpc servent stdlib strptime sys time
+SUBDIR+= atexit citrus clone context db \
+	divrem getaddrinfo hsearch inet int_fmtio locale md5sha \
+	nsdispatch pty regex rpc servent stdlib strptime sys time
 
 .include bsd.own.mk
 .include bsd.sys.mk



CVS commit: src/tests/lib/libc

2010-12-30 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Fri Dec 31 05:05:44 UTC 2010

Modified Files:
src/tests/lib/libc: Makefile

Log Message:
Ooopppsss - ieefp tests have not been atf-ified, so remove the stuff
that got committed by mistake.


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

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

Modified files:

Index: src/tests/lib/libc/Makefile
diff -u src/tests/lib/libc/Makefile:1.13 src/tests/lib/libc/Makefile:1.14
--- src/tests/lib/libc/Makefile:1.13	Fri Dec 31 04:08:33 2010
+++ src/tests/lib/libc/Makefile	Fri Dec 31 05:05:43 2010
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.13 2010/12/31 04:08:33 pgoyette Exp $
+# $NetBSD: Makefile,v 1.14 2010/12/31 05:05:43 pgoyette Exp $
 
 .include bsd.own.mk
 .include bsd.sys.mk
@@ -9,10 +9,6 @@
 TESTS_SUBDIRS+=	ssp
 .endif
 
-.if (${MACHINE_ARCH} != vax  ${MACHINE_ARCH} != m68000)
-SUBDIR+= ieeefp
-.endif
-
 TESTSDIR=	${TESTSBASE}/lib/libc
 
 TESTS_C+=	t_convfp