CVS commit: src/distrib/common

2011-05-31 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue May 31 06:19:11 UTC 2011

Modified Files:
src/distrib/common: list.dhcpcd

Log Message:
SRCDIRS is not the way to do this; some testing would have been nice.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/distrib/common/list.dhcpcd

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

Modified files:

Index: src/distrib/common/list.dhcpcd
diff -u src/distrib/common/list.dhcpcd:1.1 src/distrib/common/list.dhcpcd:1.2
--- src/distrib/common/list.dhcpcd:1.1	Tue Apr  7 07:49:17 2009
+++ src/distrib/common/list.dhcpcd	Tue May 31 02:19:11 2011
@@ -1,10 +1,10 @@
-#	$NetBSD: list.dhcpcd,v 1.1 2009/04/07 11:49:17 joerg Exp $
+#	$NetBSD: list.dhcpcd,v 1.2 2011/05/31 06:19:11 christos Exp $
 #
 # list file (c.f. parselist.awk) for DHCP-enabled install media.
 #
 
-SRCDIRS	external/bsd/dhcpcd/sbin
 PROG	sbin/dhcpcd
+SPECIAL	dhcpcd srcdir external/bsd/dhcpcd/sbin/dhcpcd
 
 COPY	${DESTDIR}/etc/dhcpcd.conf etc/dhcpcd.conf
 COPY	${DESTDIR}/libexec/dhcpcd-run-hooks libexec/dhcpcd-run-hooks 555



CVS commit: src/lib/libc/net

2011-05-31 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue May 31 06:49:27 UTC 2011

Modified Files:
src/lib/libc/net: rcmd.c

Log Message:
PR/45007: rcmd_af(3) and thusly rsh(1) ignore requested address family
Pass in the address family to rshrcmd and DTRT.
While here KNF.


To generate a diff of this commit:
cvs rdiff -u -r1.65 -r1.66 src/lib/libc/net/rcmd.c

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

Modified files:

Index: src/lib/libc/net/rcmd.c
diff -u src/lib/libc/net/rcmd.c:1.65 src/lib/libc/net/rcmd.c:1.66
--- src/lib/libc/net/rcmd.c:1.65	Wed Jan  3 06:46:22 2007
+++ src/lib/libc/net/rcmd.c	Tue May 31 02:49:26 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: rcmd.c,v 1.65 2007/01/03 11:46:22 ws Exp $	*/
+/*	$NetBSD: rcmd.c,v 1.66 2011/05/31 06:49:26 christos Exp $	*/
 
 /*
  * Copyright (c) 1983, 1993, 1994
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = @(#)rcmd.c	8.3 (Berkeley) 3/26/94;
 #else
-__RCSID($NetBSD: rcmd.c,v 1.65 2007/01/03 11:46:22 ws Exp $);
+__RCSID($NetBSD: rcmd.c,v 1.66 2011/05/31 06:49:26 christos Exp $);
 #endif
 #endif /* LIBC_SCCS and not lint */
 
@@ -70,39 +70,31 @@
 
 #include pathnames.h
 
-int	orcmd __P((char **, u_int, const char *, const char *, const char *,
-	int *));
-int	orcmd_af __P((char **, u_int, const char *, const char *, const char *,
-	int *, int));
-int	__ivaliduser __P((FILE *, u_int32_t, const char *, const char *));
-int	__ivaliduser_sa __P((FILE *, const struct sockaddr *, socklen_t,
-	const char *, const char *));
-static	int rshrcmd __P((char **, u_int32_t, const char *, const char *,
-	const char *, int *, const char *));
-static	int resrcmd __P((struct addrinfo *, char **, u_int32_t, const char *,
-	const char *, const char *, int *));
-static	int __icheckhost __P((const struct sockaddr *, socklen_t,
-	const char *));
-static	char *__gethostloop __P((const struct sockaddr *, socklen_t));
+int	orcmd(char **, u_int, const char *, const char *, const char *, int *);
+int	orcmd_af(char **, u_int, const char *, const char *, const char *,
+int *, int);
+int	__ivaliduser(FILE *, u_int32_t, const char *, const char *);
+int	__ivaliduser_sa(FILE *, const struct sockaddr *, socklen_t,
+const char *, const char *);
+static	int rshrcmd(int, char **, u_int32_t, const char *,
+const char *, const char *, int *, const char *);
+static	int resrcmd(struct addrinfo *, char **, u_int32_t, const char *,
+const char *, const char *, int *);
+static	int __icheckhost(const struct sockaddr *, socklen_t,
+const char *);
+static	char *__gethostloop(const struct sockaddr *, socklen_t);
 
 int
-rcmd(ahost, rport, locuser, remuser, cmd, fd2p)
-	char **ahost;
-	u_short rport;
-	const char *locuser, *remuser, *cmd;
-	int *fd2p;
+rcmd(char **ahost, int rport, const char *locuser, const char *remuser,
+const char *cmd, int *fd2p)
 {
 
 	return rcmd_af(ahost, rport, locuser, remuser, cmd, fd2p, AF_INET);
 }
 
 int
-rcmd_af(ahost, rport, locuser, remuser, cmd, fd2p, af)
-	char **ahost;
-	u_short rport;
-	const char *locuser, *remuser, *cmd;
-	int *fd2p;
-	int af;
+rcmd_af(char **ahost, int rport, const char *locuser, const char *remuser,
+const char *cmd, int *fd2p, int af)
 {
 	static char hbuf[MAXHOSTNAMELEN];
 	char pbuf[NI_MAXSERV];
@@ -124,7 +116,7 @@
 	error = getaddrinfo(*ahost, pbuf, hints, res);
 	if (error) {
 		warnx(%s: %s, *ahost, gai_strerror(error));	/*XXX*/
-		return (-1);
+		return -1;
 	}
 	if (res-ai_canonname) {
 		/*
@@ -142,33 +134,26 @@
 	 */
 	sp = getservbyname(shell, tcp);
 	if (sp != NULL  sp-s_port == rport)
-		error = rshrcmd(ahost, (u_int32_t)rport,
+		error = rshrcmd(af, ahost, (u_int32_t)rport,
 		locuser, remuser, cmd, fd2p, getenv(RCMD_CMD));
 	else
 		error = resrcmd(res, ahost, (u_int32_t)rport,
 		locuser, remuser, cmd, fd2p);
 	freeaddrinfo(res);
-	return (error);
+	return error;
 }
 
 /* this is simply a wrapper around hprcmd() that handles ahost first */
 int
-orcmd(ahost, rport, locuser, remuser, cmd, fd2p)
-	char **ahost;
-	u_int rport;
-	const char *locuser, *remuser, *cmd;
-	int *fd2p;
+orcmd(char **ahost, u_int rport, const char *locuser, const char *remuser,
+const char *cmd, int *fd2p)
 {
 	return orcmd_af(ahost, rport, locuser, remuser, cmd, fd2p, AF_INET);
 }
 
 int
-orcmd_af(ahost, rport, locuser, remuser, cmd, fd2p, af)
-	char **ahost;
-	u_int rport;
-	const char *locuser, *remuser, *cmd;
-	int *fd2p;
-	int af;
+orcmd_af(char **ahost, u_int rport, const char *locuser, const char *remuser,
+const char *cmd, int *fd2p, int af)
 {
 	static char hbuf[MAXHOSTNAMELEN];
 	char pbuf[NI_MAXSERV];
@@ -189,7 +174,7 @@
 	error = getaddrinfo(*ahost, pbuf, hints, res);
 	if (error) {
 		warnx(%s: %s, *ahost, gai_strerror(error));	/*XXX*/
-		return (-1);
+		return -1;
 	}
 	if (res-ai_canonname) {
 		strlcpy(hbuf, res-ai_canonname, sizeof(hbuf));
@@ -198,17 +183,13 @@
 	
 	error = resrcmd(res, ahost, rport, 

CVS commit: src/bin/rcmd

2011-05-31 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue May 31 10:24:44 UTC 2011

Modified Files:
src/bin/rcmd: rcmd.1

Log Message:
PR/45008: Martin Neitzel: document all rcmd(1) options. -46p were missing,
and -d was not in the synopsis.


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/bin/rcmd/rcmd.1

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

Modified files:

Index: src/bin/rcmd/rcmd.1
diff -u src/bin/rcmd/rcmd.1:1.19 src/bin/rcmd/rcmd.1:1.20
--- src/bin/rcmd/rcmd.1:1.19	Thu May 29 22:29:37 2008
+++ src/bin/rcmd/rcmd.1	Tue May 31 06:24:43 2011
@@ -1,4 +1,4 @@
-.\	$NetBSD: rcmd.1,v 1.19 2008/05/30 02:29:37 mrg Exp $
+.\	$NetBSD: rcmd.1,v 1.20 2011/05/31 10:24:43 christos Exp $
 .\
 .\ Copyright (c) 1997 Matthew R. Green.
 .\ All rights reserved.
@@ -63,6 +63,8 @@
 .Xr rcmd 3
 .Sh SYNOPSIS
 .Nm
+.Op Fl 46dn
+.Op Fl p Ar port
 .Op Fl l Ar username
 .Op Fl u Ar localusername
 .Ar host
@@ -84,6 +86,10 @@
 normally terminates when the remote command does.
 The options are as follows:
 .Bl -tag -width flag
+.It Fl 4
+Use IPv4 addresses only.
+.It Fl 6
+Use IPv6 addresses only.
 .It Fl d
 The
 .Fl d
@@ -97,6 +103,9 @@
 The
 .Fl l
 option allows the remote name to be specified.
+Another possible way to specify the remote username
+is the notation
+.Ar user@host .
 .It Fl u
 The
 .Fl u
@@ -110,6 +119,12 @@
 (see the
 .Sx BUGS
 section of this manual page).
+.It Fl p Ar port
+Uses the given
+.Pa port
+instead of the one assigned to the service
+.Dq shell .
+May be given either as symbolic name or as number.
 .El
 .Pp
 Shell metacharacters which are not quoted are interpreted on local machine,



CVS commit: src/bin/rcmd

2011-05-31 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Tue May 31 11:31:10 UTC 2011

Modified Files:
src/bin/rcmd: rcmd.1

Log Message:
Sort options in SYNOPSIS, sort option descriptions, remove some extra
space, bump date for previous.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/bin/rcmd/rcmd.1

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

Modified files:

Index: src/bin/rcmd/rcmd.1
diff -u src/bin/rcmd/rcmd.1:1.20 src/bin/rcmd/rcmd.1:1.21
--- src/bin/rcmd/rcmd.1:1.20	Tue May 31 10:24:43 2011
+++ src/bin/rcmd/rcmd.1	Tue May 31 11:31:10 2011
@@ -1,4 +1,4 @@
-.\	$NetBSD: rcmd.1,v 1.20 2011/05/31 10:24:43 christos Exp $
+.\	$NetBSD: rcmd.1,v 1.21 2011/05/31 11:31:10 wiz Exp $
 .\
 .\ Copyright (c) 1997 Matthew R. Green.
 .\ All rights reserved.
@@ -54,7 +54,7 @@
 .\	from: @(#)rsh.1	6.10 (Berkeley) 7/24/91
 .\	from: NetBSD: rsh.1,v 1.3 1997/01/09 20:21:14 tls Exp
 .\
-.Dd September 5, 2004
+.Dd May 31, 2011
 .Dt RCMD 1
 .Os
 .Sh NAME
@@ -64,8 +64,8 @@
 .Sh SYNOPSIS
 .Nm
 .Op Fl 46dn
-.Op Fl p Ar port
 .Op Fl l Ar username
+.Op Fl p Ar port
 .Op Fl u Ar localusername
 .Ar host
 .Ar command
@@ -74,7 +74,7 @@
 executes
 .Ar command
 on
-.Ar host  .
+.Ar host .
 .Pp
 .Nm
 copies its standard input to the remote command, the standard
@@ -94,7 +94,7 @@
 The
 .Fl d
 option turns on socket debugging (using
-.Xr setsockopt  2  )
+.Xr setsockopt 2 )
 on the
 .Tn TCP
 sockets used for communication with the remote host.
@@ -106,11 +106,6 @@
 Another possible way to specify the remote username
 is the notation
 .Ar user@host .
-.It Fl u
-The
-.Fl u
-option allows the local username to be specified.
-Only the superuser is allowed to use this option.
 .It Fl n
 The
 .Fl n
@@ -125,6 +120,11 @@
 instead of the one assigned to the service
 .Dq shell .
 May be given either as symbolic name or as number.
+.It Fl u
+The
+.Fl u
+option allows the local username to be specified.
+Only the superuser is allowed to use this option.
 .El
 .Pp
 Shell metacharacters which are not quoted are interpreted on local machine,
@@ -167,7 +167,7 @@
 to no longer require super-user privileges.
 .Sh BUGS
 If you are using
-.Xr csh  1
+.Xr csh 1
 and put a
 .Nm
 in the background without redirecting its input away from the terminal,
@@ -183,11 +183,11 @@
 You cannot use
 .Nm rcmd
 to run an interactive command (like
-.Xr rogue  6
+.Xr rogue 6
 or
-.Xr vi  1 ) .
+.Xr vi 1 ) .
 Use
-.Xr rlogin  1
+.Xr rlogin 1
 instead.
 .Pp
 The stop signal,



CVS commit: src/lib/librmt

2011-05-31 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue May 31 12:24:33 UTC 2011

Modified Files:
src/lib/librmt: rmtlib.c

Log Message:
PR/38413: Takahiro Kambe: mt(1) print some junk output when using remote tape
Not all fields are valid in the ioctl to get tape info in the rmt protocol.
Zero out the struct so that we don't print junk.
While here, KNF.


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/lib/librmt/rmtlib.c

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

Modified files:

Index: src/lib/librmt/rmtlib.c
diff -u src/lib/librmt/rmtlib.c:1.23 src/lib/librmt/rmtlib.c:1.24
--- src/lib/librmt/rmtlib.c:1.23	Fri Feb 18 11:10:09 2011
+++ src/lib/librmt/rmtlib.c	Tue May 31 08:24:33 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: rmtlib.c,v 1.23 2011/02/18 16:10:09 pooka Exp $	*/
+/*	$NetBSD: rmtlib.c,v 1.24 2011/05/31 12:24:33 christos Exp $	*/
 
 /*
  *	rmt --- remote tape emulator subroutines
@@ -28,7 +28,7 @@
  */
 
 #include sys/cdefs.h
-__RCSID($NetBSD: rmtlib.c,v 1.23 2011/02/18 16:10:09 pooka Exp $);
+__RCSID($NetBSD: rmtlib.c,v 1.24 2011/05/31 12:24:33 christos Exp $);
 
 #define RMTIOCTL	1
 /* #define USE_REXEC	1 */	/* rexec code courtesy of Dan Kegel, srs!dan */
@@ -50,6 +50,7 @@
 #include stdlib.h
 #include string.h
 #include unistd.h
+#include err.h
 
 #ifdef USE_REXEC
 #include netdb.h
@@ -66,7 +67,7 @@
 static	int	_rmt_open(const char *, int, int);
 static	ssize_t	_rmt_read(int, void *, size_t);
 static	ssize_t	_rmt_write(int, const void *, size_t);
-static	int	command(int, char *);
+static	int	command(int, const char *);
 static	int	remdev(const char *);
 static	void	rmtabort(int);
 static	int	status(int);
@@ -100,10 +101,10 @@
  *	command --- attempt to perform a remote tape command
  */
 static int
-command(int fildes, char *buf)
+command(int fildes, const char *buf)
 {
 	size_t blen;
-	void (*pstat)(int);
+	sig_t pstat;
 
 	_DIAGASSERT(buf != NULL);
 
@@ -115,7 +116,7 @@
 	pstat = signal(SIGPIPE, SIG_IGN);
 	if (write(WRITE(fildes), buf, blen) == blen) {
 		signal(SIGPIPE, pstat);
-		return (0);
+		return 0;
 	}
 
 /*
@@ -126,7 +127,7 @@
 	rmtabort(fildes);
 
 	errno = EIO;
-	return (-1);
+	return -1;
 }
 
 
@@ -148,7 +149,7 @@
 		if (read(READ(fildes), cp, 1) != 1) {
 			rmtabort(fildes);
 			errno = EIO;
-			return (-1);
+			return -1;
 		}
 		if (*cp == '\n') {
 			*cp = 0;
@@ -159,7 +160,7 @@
 	if (i == BUFMAGIC) {
 		rmtabort(fildes);
 		errno = EIO;
-		return (-1);
+		return -1;
 	}
 
 /*
@@ -179,7 +180,7 @@
 		if (*cp == 'F')
 			rmtabort(fildes);
 
-		return (-1);
+		return -1;
 	}
 
 /*
@@ -189,10 +190,10 @@
 	if (*cp != 'A') {
 		rmtabort(fildes);
 		errno = EIO;
-		return (-1);
+		return -1;
 	}
 
-	return (atoi(cp + 1));
+	return atoi(cp + 1);
 }
 
 
@@ -222,14 +223,12 @@
 	/* user may be NULL */
 
 	rexecserv = getservbyname(exec, tcp);
-	if (rexecserv == NULL) {
-		fprintf(stderr, ? exec/tcp: service not available.);
-		exit(1);
-	}
+	if (rexecserv == NULL)
+		errx(1, exec/tcp: service not available.);
 	if ((user != NULL)  *user == '\0')
 		user = NULL;
-	return (rexec(host, rexecserv-s_port, user, NULL,
-	/etc/rmt, NULL));
+	return rexec(host, rexecserv-s_port, user, NULL,
+	/etc/rmt, NULL);
 }
 #endif /* USE_REXEC */
 
@@ -249,12 +248,13 @@
 /*ARGSUSED*/
 _rmt_open(const char *path, int oflag, int mode)
 {
-	int i, rc;
+	int i;
 	char buffer[BUFMAGIC];
 	char host[MAXHOSTLEN];
 	char device[BUFMAGIC];
 	char login[BUFMAGIC];
 	char *sys, *dev, *user;
+	char *rshpath, *rsh;
 
 	_DIAGASSERT(path != NULL);
 
@@ -272,7 +272,7 @@
 
 	if (i == MAXUNIT) {
 		errno = EMFILE;
-		return (-1);
+		return -1;
 	}
 
 /*
@@ -324,21 +324,20 @@
  */
 	READ(i) = WRITE(i) = _rmt_rexec(host, login);
 	if (READ(i)  0)
-		return (-1);
+		return -1;
 #else
 /*
  *	setup the pipes for the 'rsh' command and fork
  */
 
 	if (pipe(Ptc[i]) == -1 || pipe(Ctp[i]) == -1)
-		return (-1);
-
-	if ((rc = fork()) == -1)
-		return (-1);
+		return -1;
 
-	if (rc == 0) {
-		char	*rshpath, *rsh;
+	switch (fork()) {
+	case -1:
+		return -1;
 
+	case 0:
 		close(0);
 		dup(Ptc[i][0]);
 		close(Ptc[i][0]); close(Ptc[i][1]);
@@ -356,19 +355,19 @@
 			rsh++;
 
 		if (*login) {
-			execl(rshpath, rsh, host, -l, login,
-			_PATH_RMT, NULL);
+			execl(rshpath, rsh, host, -l, login, _PATH_RMT, NULL);
 		} else {
-			execl(rshpath, rsh, host,
-			_PATH_RMT, NULL);
+			execl(rshpath, rsh, host, _PATH_RMT, NULL);
 		}
 
 /*
  *	bad problems if we get here
  */
 
-		perror(exec);
-		exit(1);
+		err(1, Cannnot exec %s, rshpath);
+		/*FALLTHROUGH*/
+	default:
+		break;
 	}
 
 	close(Ptc[i][0]); close(Ctp[i][1]);
@@ -380,9 +379,9 @@
 
 	(void)snprintf(buffer, sizeof(buffer), O%s\n%d\n, device, oflag);
 	if (command(i, buffer) == -1 || status(i) == -1)
-		return (-1);
+		return -1;
 
-	return (i);
+	return i;
 }
 
 
@@ -398,10 +397,10 @@
 		rc = status(fildes);
 
 		rmtabort(fildes);
-		return (rc);
+		return rc;
 	}
 
-	

CVS commit: src/tests/usr.bin/mkdep

2011-05-31 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Tue May 31 13:22:56 UTC 2011

Modified Files:
src/tests/usr.bin/mkdep: t_mkdep.sh

Log Message:
Adjust testcase for recent changes.
- suffixes output order is now reversed.
- remove expected failure for empty list.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/tests/usr.bin/mkdep/t_mkdep.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/usr.bin/mkdep/t_mkdep.sh
diff -u src/tests/usr.bin/mkdep/t_mkdep.sh:1.1 src/tests/usr.bin/mkdep/t_mkdep.sh:1.2
--- src/tests/usr.bin/mkdep/t_mkdep.sh:1.1	Mon May 30 18:14:11 2011
+++ src/tests/usr.bin/mkdep/t_mkdep.sh	Tue May 31 13:22:56 2011
@@ -1,4 +1,4 @@
-# $NetBSD: t_mkdep.sh,v 1.1 2011/05/30 18:14:11 njoly Exp $
+# $NetBSD: t_mkdep.sh,v 1.2 2011/05/31 13:22:56 njoly Exp $
 #
 # Copyright (c) 2011 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -43,13 +43,11 @@
 
 	# Suffix list
 	atf_check mkdep -f sample.d -s '.a .b' sample.c
-	atf_check -o ignore grep '^sample.a sample.b:' sample.d
+	atf_check -o ignore grep '^sample.b sample.a:' sample.d
 
 	# Empty list
-	atf_expect_fail PR bin/45004
 	atf_check mkdep -f sample.d -s '' sample.c
 	atf_check -o ignore grep '^sample:' sample.d
-	atf_expect_pass
 }
 
 atf_init_test_cases() {



CVS commit: src/sys/dev/acpi

2011-05-31 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Tue May 31 14:27:44 UTC 2011

Modified Files:
src/sys/dev/acpi: acpi.c

Log Message:
Fix a bug where the S1 state was exited via AcpiLeaveSleepState() with
interrupts being off at machine-level. Also add some comments.


To generate a diff of this commit:
cvs rdiff -u -r1.240 -r1.241 src/sys/dev/acpi/acpi.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/acpi/acpi.c
diff -u src/sys/dev/acpi/acpi.c:1.240 src/sys/dev/acpi/acpi.c:1.241
--- src/sys/dev/acpi/acpi.c:1.240	Sun Feb 27 17:10:33 2011
+++ src/sys/dev/acpi/acpi.c	Tue May 31 14:27:44 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi.c,v 1.240 2011/02/27 17:10:33 jruoho Exp $	*/
+/*	$NetBSD: acpi.c,v 1.241 2011/05/31 14:27:44 jruoho Exp $	*/
 
 /*-
  * Copyright (c) 2003, 2007 The NetBSD Foundation, Inc.
@@ -100,7 +100,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: acpi.c,v 1.240 2011/02/27 17:10:33 jruoho Exp $);
+__KERNEL_RCSID(0, $NetBSD: acpi.c,v 1.241 2011/05/31 14:27:44 jruoho Exp $);
 
 #include opt_acpi.h
 #include opt_pcifixup.h
@@ -1300,7 +1300,12 @@
 
 		if (state == ACPI_STATE_S1) {
 
-			/* Just enter the state. */
+			/*
+			 * Enter the state. Note that interrupts must
+			 * be off before calling AcpiEnterSleepState().
+			 * Conversely, AcpiLeaveSleepState() should
+			 * always be called with interrupts enabled.
+			 */
 			acpi_md_OsDisableInterrupt();
 			rv = AcpiEnterSleepState(state);
 
@@ -1308,7 +1313,8 @@
 aprint_error_dev(sc-sc_dev, failed to 
 enter S1: %s\n, AcpiFormatException(rv));
 
-			(void)AcpiLeaveSleepState(state);
+			acpi_md_OsEnableInterrupt();
+			rv = AcpiLeaveSleepState(state);
 
 		} else {
 
@@ -1323,6 +1329,9 @@
 			(void)pmf_system_resume(PMF_Q_NONE);
 		}
 
+		/*
+		 * No wake GPEs should be enabled at runtime.
+		 */
 		acpi_wakedev_commit(sc, ACPI_STATE_S0);
 		break;
 



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

2011-05-31 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Tue May 31 14:45:37 UTC 2011

Modified Files:
src/sys/arch/x86/acpi: acpi_cpu_md.c

Log Message:
Remove the sanity check that tested the internal consistency of the FID/VID
algorithm used by K8. Tested by cegger@. The check is still included in the
original powernow(4) (where possible failures have probably gone unnoticed
because the driver is less noisy).


To generate a diff of this commit:
cvs rdiff -u -r1.58 -r1.59 src/sys/arch/x86/acpi/acpi_cpu_md.c

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

Modified files:

Index: src/sys/arch/x86/acpi/acpi_cpu_md.c
diff -u src/sys/arch/x86/acpi/acpi_cpu_md.c:1.58 src/sys/arch/x86/acpi/acpi_cpu_md.c:1.59
--- src/sys/arch/x86/acpi/acpi_cpu_md.c:1.58	Mon Apr  4 20:37:55 2011
+++ src/sys/arch/x86/acpi/acpi_cpu_md.c	Tue May 31 14:45:36 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: acpi_cpu_md.c,v 1.58 2011/04/04 20:37:55 dyoung Exp $ */
+/* $NetBSD: acpi_cpu_md.c,v 1.59 2011/05/31 14:45:36 jruoho Exp $ */
 
 /*-
  * Copyright (c) 2010, 2011 Jukka Ruohonen jruoho...@iki.fi
@@ -27,7 +27,7 @@
  * SUCH DAMAGE.
  */
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: acpi_cpu_md.c,v 1.58 2011/04/04 20:37:55 dyoung Exp $);
+__KERNEL_RCSID(0, $NetBSD: acpi_cpu_md.c,v 1.59 2011/05/31 14:45:36 jruoho Exp $);
 
 #include sys/param.h
 #include sys/bus.h
@@ -917,9 +917,6 @@
 			return rv;
 	}
 
-	if (cfid != fid || cvid != vid)
-		return EIO;
-
 	return 0;
 }
 



CVS commit: src/sbin/ifconfig

2011-05-31 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue May 31 16:17:30 UTC 2011

Modified Files:
src/sbin/ifconfig: ifconfig.8

Log Message:
Fix typo: `symbolically' takes three l's, not two.


To generate a diff of this commit:
cvs rdiff -u -r1.102 -r1.103 src/sbin/ifconfig/ifconfig.8

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

Modified files:

Index: src/sbin/ifconfig/ifconfig.8
diff -u src/sbin/ifconfig/ifconfig.8:1.102 src/sbin/ifconfig/ifconfig.8:1.103
--- src/sbin/ifconfig/ifconfig.8:1.102	Mon Nov 15 22:42:37 2010
+++ src/sbin/ifconfig/ifconfig.8	Tue May 31 16:17:30 2011
@@ -1,4 +1,4 @@
-.\	$NetBSD: ifconfig.8,v 1.102 2010/11/15 22:42:37 pooka Exp $
+.\	$NetBSD: ifconfig.8,v 1.103 2011/05/31 16:17:30 riastradh Exp $
 .\
 .\ Copyright (c) 1983, 1991, 1993
 .\	The Regents of the University of California.  All rights reserved.
@@ -502,7 +502,7 @@
 .Fl v
 flag may be used to display long SSIDs.
 .Fl v
-also causes received information elements to be displayed symbolicaly.
+also causes received information elements to be displayed symbolically.
 Only the super-user can use this command.
 .It Cm tunnel Ar src_addr Ns Op Ar ,src_port
 .Ar dest_addr Ns Op Ar ,dest_port



CVS commit: src/tests/lib

2011-05-31 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Tue May 31 20:17:37 UTC 2011

Modified Files:
src/tests/lib/libc/stdlib: t_strtod.c
src/tests/lib/libm: t_infinity.c

Log Message:
Mark the following tests as expected failures on qemu/amd64: 'strtod_inf',
'strtod_round', and 'infinity_long_double'. None of these fail on any known
native host. Use the tracker PR misc/44767 as the reference point.


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/tests/lib/libc/stdlib/t_strtod.c
cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libm/t_infinity.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/stdlib/t_strtod.c
diff -u src/tests/lib/libc/stdlib/t_strtod.c:1.11 src/tests/lib/libc/stdlib/t_strtod.c:1.12
--- src/tests/lib/libc/stdlib/t_strtod.c:1.11	Fri May 20 21:42:49 2011
+++ src/tests/lib/libc/stdlib/t_strtod.c	Tue May 31 20:17:36 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: t_strtod.c,v 1.11 2011/05/20 21:42:49 nakayama Exp $ */
+/*	$NetBSD: t_strtod.c,v 1.12 2011/05/31 20:17:36 jruoho Exp $ */
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -32,7 +32,7 @@
 /* Public domain, Otto Moerbeek o...@drijf.net, 2006. */
 
 #include sys/cdefs.h
-__RCSID($NetBSD: t_strtod.c,v 1.11 2011/05/20 21:42:49 nakayama Exp $);
+__RCSID($NetBSD: t_strtod.c,v 1.12 2011/05/31 20:17:36 jruoho Exp $);
 
 #include errno.h
 #include math.h
@@ -115,8 +115,13 @@
 	float f;
 
 	/*
-	 * See old PR lib/33262.
+	 * See the closed PR lib/33262.
+	 *
+	 * This may also fail under QEMU; cf. PR misc/44767.
 	 */
+	if (system(cpuctl identify 0 | grep -q QEMU) == 0)
+		atf_tc_expect_fail(PR misc/44767);
+
 	d = strtod(INF, NULL);
 	ATF_REQUIRE(isinf(d) != 0);
 
@@ -143,9 +148,13 @@
 
 	/*
 	 * Test that strtod(3) honors the current rounding mode.
-	 *
 	 * The used value is somewhere near 1 + DBL_EPSILON + FLT_EPSILON.
+	 *
+	 * May fail under QEMU; cf. PR misc/44767.
 	 */
+	if (system(cpuctl identify 0 | grep -q QEMU) == 0)
+		atf_tc_expect_fail(PR misc/44767);
+
 	val = 1.0011920928977282585492503130808472633361816406;
 
 	(void)fesetround(FE_UPWARD);

Index: src/tests/lib/libm/t_infinity.c
diff -u src/tests/lib/libm/t_infinity.c:1.1 src/tests/lib/libm/t_infinity.c:1.2
--- src/tests/lib/libm/t_infinity.c:1.1	Mon Apr 11 10:51:36 2011
+++ src/tests/lib/libm/t_infinity.c	Tue May 31 20:17:36 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: t_infinity.c,v 1.1 2011/04/11 10:51:36 martin Exp $ */
+/* $NetBSD: t_infinity.c,v 1.2 2011/05/31 20:17:36 jruoho Exp $ */
 
 /*-
  * Copyright (c) 2002, 2008 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include sys/cdefs.h
-__RCSID($NetBSD: t_infinity.c,v 1.1 2011/04/11 10:51:36 martin Exp $);
+__RCSID($NetBSD: t_infinity.c,v 1.2 2011/05/31 20:17:36 jruoho Exp $);
 
 #include atf-c.h
 #include math.h
@@ -88,6 +88,14 @@
 
 ATF_TC_BODY(infinity_long_double, tc)
 {
+
+	/*
+	 * May fail under QEMU; cf. PR misc/44767.
+	 */
+	if (system(cpuctl identify 0 | grep -q QEMU) == 0)
+		atf_tc_expect_fail(PR misc/44767);
+
+
 #ifndef LDBL_MAX
 	atf_tc_skip(no long double support on this architecture);
 	return;



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

2011-05-31 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Tue May 31 20:53:13 UTC 2011

Modified Files:
src/sys/compat/linux/arch/alpha: files.linux_alpha

Log Message:
Add needed linux_fadvise64.c


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/compat/linux/arch/alpha/files.linux_alpha

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

Modified files:

Index: src/sys/compat/linux/arch/alpha/files.linux_alpha
diff -u src/sys/compat/linux/arch/alpha/files.linux_alpha:1.8 src/sys/compat/linux/arch/alpha/files.linux_alpha:1.9
--- src/sys/compat/linux/arch/alpha/files.linux_alpha:1.8	Wed Jul  7 01:30:33 2010
+++ src/sys/compat/linux/arch/alpha/files.linux_alpha	Tue May 31 20:53:13 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: files.linux_alpha,v 1.8 2010/07/07 01:30:33 chs Exp $
+#	$NetBSD: files.linux_alpha,v 1.9 2011/05/31 20:53:13 njoly Exp $
 #
 # Config file description for alpha-dependent Linux compat code.
 
@@ -6,6 +6,7 @@
 file	compat/linux/arch/alpha/linux_pipe.c		compat_linux
 file	compat/linux/arch/alpha/linux_syscalls.c	compat_linux
 file	compat/linux/arch/alpha/linux_sysent.c		compat_linux
+file	compat/linux/common/linux_fadvise64.c		compat_linux
 file	compat/linux/common/linux_file64.c		compat_linux
 file	compat/linux/common/linux_futex.c		compat_linux
 file	compat/linux/common/linux_olduname.c		compat_linux



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

2011-05-31 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Tue May 31 21:38:00 UTC 2011

Modified Files:
src/sys/compat/linux/arch/powerpc: syscalls.master

Log Message:
Small typo in fadvise64_64 args (advise - advice).


To generate a diff of this commit:
cvs rdiff -u -r1.47 -r1.48 src/sys/compat/linux/arch/powerpc/syscalls.master

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

Modified files:

Index: src/sys/compat/linux/arch/powerpc/syscalls.master
diff -u src/sys/compat/linux/arch/powerpc/syscalls.master:1.47 src/sys/compat/linux/arch/powerpc/syscalls.master:1.48
--- src/sys/compat/linux/arch/powerpc/syscalls.master:1.47	Mon May 30 17:50:32 2011
+++ src/sys/compat/linux/arch/powerpc/syscalls.master	Tue May 31 21:38:00 2011
@@ -1,4 +1,4 @@
-	$NetBSD: syscalls.master,v 1.47 2011/05/30 17:50:32 alnsn Exp $  
+	$NetBSD: syscalls.master,v 1.48 2011/05/31 21:38:00 njoly Exp $  
 
 ;	@(#)syscalls.master	8.1 (Berkeley) 7/19/93
 
@@ -446,7 +446,7 @@
 253	STD		{ int|linux_sys||fstatfs64(int fd, \
 			size_t sz, struct linux_statfs64 *sp); }
 254	STD		{ int|linux_sys||fadvise64_64(int fd, \
-			linux_off_t offset, linux_off_t len, int advise); }
+			linux_off_t offset, linux_off_t len, int advice); }
 255	UNIMPL		rtas
 256	UNIMPL		/* reserved for sys_debug_setcontext */
 257	UNIMPL		/* reserved for vserver */



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

2011-05-31 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Tue May 31 21:39:00 UTC 2011

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

Log Message:
Regen for fadvise64_64 typo fix.


To generate a diff of this commit:
cvs rdiff -u -r1.54 -r1.55 src/sys/compat/linux/arch/powerpc/linux_syscall.h \
src/sys/compat/linux/arch/powerpc/linux_sysent.c
cvs rdiff -u -r1.53 -r1.54 \
src/sys/compat/linux/arch/powerpc/linux_syscallargs.h \
src/sys/compat/linux/arch/powerpc/linux_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/compat/linux/arch/powerpc/linux_syscall.h
diff -u src/sys/compat/linux/arch/powerpc/linux_syscall.h:1.54 src/sys/compat/linux/arch/powerpc/linux_syscall.h:1.55
--- src/sys/compat/linux/arch/powerpc/linux_syscall.h:1.54	Mon May 30 21:37:40 2011
+++ src/sys/compat/linux/arch/powerpc/linux_syscall.h	Tue May 31 21:39:00 2011
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.54 2011/05/30 21:37:40 alnsn Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.55 2011/05/31 21:39:00 njoly Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.47 2011/05/30 17:50:32 alnsn Exp  
+ * created from	NetBSD: syscalls.master,v 1.48 2011/05/31 21:38:00 njoly Exp  
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
Index: src/sys/compat/linux/arch/powerpc/linux_sysent.c
diff -u src/sys/compat/linux/arch/powerpc/linux_sysent.c:1.54 src/sys/compat/linux/arch/powerpc/linux_sysent.c:1.55
--- src/sys/compat/linux/arch/powerpc/linux_sysent.c:1.54	Mon May 30 21:37:40 2011
+++ src/sys/compat/linux/arch/powerpc/linux_sysent.c	Tue May 31 21:39:00 2011
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.54 2011/05/30 21:37:40 alnsn Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.55 2011/05/31 21:39:00 njoly Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.47 2011/05/30 17:50:32 alnsn Exp  
+ * created from	NetBSD: syscalls.master,v 1.48 2011/05/31 21:38:00 njoly Exp  
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: linux_sysent.c,v 1.54 2011/05/30 21:37:40 alnsn Exp $);
+__KERNEL_RCSID(0, $NetBSD: linux_sysent.c,v 1.55 2011/05/31 21:39:00 njoly Exp $);
 
 #include sys/param.h
 #include sys/poll.h

Index: src/sys/compat/linux/arch/powerpc/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/powerpc/linux_syscallargs.h:1.53 src/sys/compat/linux/arch/powerpc/linux_syscallargs.h:1.54
--- src/sys/compat/linux/arch/powerpc/linux_syscallargs.h:1.53	Mon May 30 21:37:40 2011
+++ src/sys/compat/linux/arch/powerpc/linux_syscallargs.h	Tue May 31 21:39:00 2011
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.53 2011/05/30 21:37:40 alnsn Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.54 2011/05/31 21:39:00 njoly Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.47 2011/05/30 17:50:32 alnsn Exp  
+ * created from	NetBSD: syscalls.master,v 1.48 2011/05/31 21:38:00 njoly Exp  
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -888,7 +888,7 @@
 	syscallarg(int) fd;
 	syscallarg(linux_off_t) offset;
 	syscallarg(linux_off_t) len;
-	syscallarg(int) advise;
+	syscallarg(int) advice;
 };
 check_syscall_args(linux_sys_fadvise64_64)
 
Index: src/sys/compat/linux/arch/powerpc/linux_syscalls.c
diff -u src/sys/compat/linux/arch/powerpc/linux_syscalls.c:1.53 src/sys/compat/linux/arch/powerpc/linux_syscalls.c:1.54
--- src/sys/compat/linux/arch/powerpc/linux_syscalls.c:1.53	Mon May 30 21:37:40 2011
+++ src/sys/compat/linux/arch/powerpc/linux_syscalls.c	Tue May 31 21:39:00 2011
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.53 2011/05/30 21:37:40 alnsn Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.54 2011/05/31 21:39:00 njoly Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.47 2011/05/30 17:50:32 alnsn Exp  
+ * created from	NetBSD: syscalls.master,v 1.48 2011/05/31 21:38:00 njoly Exp  
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: linux_syscalls.c,v 1.53 2011/05/30 21:37:40 alnsn Exp $);
+__KERNEL_RCSID(0, $NetBSD: linux_syscalls.c,v 1.54 2011/05/31 21:39:00 njoly Exp $);
 
 #if defined(_KERNEL_OPT)
 #include sys/param.h



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

2011-05-31 Thread Nicolas Joly
Module Name:src
Committed By:   njoly
Date:   Tue May 31 22:35:22 UTC 2011

Modified Files:
src/sys/compat/linux/arch/arm: linux_commons.c
src/sys/compat/linux/arch/i386: linux_commons.c

Log Message:
Fix path for fadvise64 files.


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/sys/compat/linux/arch/arm/linux_commons.c
cvs rdiff -u -r1.15 -r1.16 src/sys/compat/linux/arch/i386/linux_commons.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/compat/linux/arch/arm/linux_commons.c
diff -u src/sys/compat/linux/arch/arm/linux_commons.c:1.11 src/sys/compat/linux/arch/arm/linux_commons.c:1.12
--- src/sys/compat/linux/arch/arm/linux_commons.c:1.11	Mon May 30 17:50:31 2011
+++ src/sys/compat/linux/arch/arm/linux_commons.c	Tue May 31 22:35:22 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux_commons.c,v 1.11 2011/05/30 17:50:31 alnsn Exp $	*/
+/*	$NetBSD: linux_commons.c,v 1.12 2011/05/31 22:35:22 njoly Exp $	*/
 
 /*
  * This file includes C files from the common
@@ -13,7 +13,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(1, $NetBSD: linux_commons.c,v 1.11 2011/05/30 17:50:31 alnsn Exp $);
+__KERNEL_RCSID(1, $NetBSD: linux_commons.c,v 1.12 2011/05/31 22:35:22 njoly Exp $);
 
 #if defined(_KERNEL_OPT)
 #include opt_sysv.h
@@ -39,4 +39,4 @@
 #include ../../common/linux_oldolduname.c
 #include ../../common/linux_uid16.c
 #include ../../common/linux_futex.c
-#include ../../compat/linux/common/linux_fadvise64_64.c
+#include ../../common/linux_fadvise64_64.c

Index: src/sys/compat/linux/arch/i386/linux_commons.c
diff -u src/sys/compat/linux/arch/i386/linux_commons.c:1.15 src/sys/compat/linux/arch/i386/linux_commons.c:1.16
--- src/sys/compat/linux/arch/i386/linux_commons.c:1.15	Mon May 30 17:50:31 2011
+++ src/sys/compat/linux/arch/i386/linux_commons.c	Tue May 31 22:35:22 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: linux_commons.c,v 1.15 2011/05/30 17:50:31 alnsn Exp $	*/
+/*	$NetBSD: linux_commons.c,v 1.16 2011/05/31 22:35:22 njoly Exp $	*/
 
 /*
  * This file includes C files from the common
@@ -13,7 +13,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(1, $NetBSD: linux_commons.c,v 1.15 2011/05/30 17:50:31 alnsn Exp $);
+__KERNEL_RCSID(1, $NetBSD: linux_commons.c,v 1.16 2011/05/31 22:35:22 njoly Exp $);
 
 #if defined(_KERNEL_OPT)
 #include opt_sysv.h
@@ -40,5 +40,5 @@
 #include ../../common/linux_olduname.c
 #include ../../common/linux_oldolduname.c
 #include ../../common/linux_uid16.c
-#include ../../compat/linux/common/linux_fadvise64.c
-#include ../../compat/linux/common/linux_fadvise64_64.c
+#include ../../common/linux_fadvise64.c
+#include ../../common/linux_fadvise64_64.c



CVS commit: src/tests/lib/libm

2011-05-31 Thread Alexander Nasonov
Module Name:src
Committed By:   alnsn
Date:   Tue May 31 22:40:35 UTC 2011

Modified Files:
src/tests/lib/libm: t_infinity.c

Log Message:
Add stdlib.h for system(3).


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/tests/lib/libm/t_infinity.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/libm/t_infinity.c
diff -u src/tests/lib/libm/t_infinity.c:1.2 src/tests/lib/libm/t_infinity.c:1.3
--- src/tests/lib/libm/t_infinity.c:1.2	Tue May 31 20:17:36 2011
+++ src/tests/lib/libm/t_infinity.c	Tue May 31 22:40:35 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: t_infinity.c,v 1.2 2011/05/31 20:17:36 jruoho Exp $ */
+/* $NetBSD: t_infinity.c,v 1.3 2011/05/31 22:40:35 alnsn Exp $ */
 
 /*-
  * Copyright (c) 2002, 2008 The NetBSD Foundation, Inc.
@@ -29,11 +29,12 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include sys/cdefs.h
-__RCSID($NetBSD: t_infinity.c,v 1.2 2011/05/31 20:17:36 jruoho Exp $);
+__RCSID($NetBSD: t_infinity.c,v 1.3 2011/05/31 22:40:35 alnsn Exp $);
 
 #include atf-c.h
 #include math.h
 #include float.h
+#include stdlib.h
 
 ATF_TC(infinity_float);
 ATF_TC_HEAD(infinity_float, tc)



CVS commit: src/sys

2011-05-31 Thread David Young
Module Name:src
Committed By:   dyoung
Date:   Tue May 31 23:28:53 UTC 2011

Modified Files:
src/sys/arch/x86/conf: files.x86
src/sys/arch/x86/include: cpu.h
src/sys/arch/x86/x86: x86_machdep.c
src/sys/kern: init_main.c kern_stub.c subr_userconf.c
src/sys/sys: userconf.h
Added Files:
src/sys/arch/x86/x86: x86_userconf.c

Log Message:
Don't use the C preprocessor to configure USERCONF.  Instead, either do
or do not link in subr_userconf.c and x86_userconf.c.

Provide no-op stubs for userconf_bootinfo(), userconf_init(), and
userconf_prompt().

Delete all occurrences of #include opt_userconf.h as well as USERCONF
and __HAVE_USERCONF_BOOTINFO #ifdef'age.


To generate a diff of this commit:
cvs rdiff -u -r1.67 -r1.68 src/sys/arch/x86/conf/files.x86
cvs rdiff -u -r1.33 -r1.34 src/sys/arch/x86/include/cpu.h
cvs rdiff -u -r1.49 -r1.50 src/sys/arch/x86/x86/x86_machdep.c
cvs rdiff -u -r0 -r1.1 src/sys/arch/x86/x86/x86_userconf.c
cvs rdiff -u -r1.430 -r1.431 src/sys/kern/init_main.c
cvs rdiff -u -r1.31 -r1.32 src/sys/kern/kern_stub.c
cvs rdiff -u -r1.23 -r1.24 src/sys/kern/subr_userconf.c
cvs rdiff -u -r1.6 -r1.7 src/sys/sys/userconf.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/arch/x86/conf/files.x86
diff -u src/sys/arch/x86/conf/files.x86:1.67 src/sys/arch/x86/conf/files.x86:1.68
--- src/sys/arch/x86/conf/files.x86:1.67	Sun Apr 10 20:36:48 2011
+++ src/sys/arch/x86/conf/files.x86	Tue May 31 23:28:52 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: files.x86,v 1.67 2011/04/10 20:36:48 christos Exp $
+#	$NetBSD: files.x86,v 1.68 2011/05/31 23:28:52 dyoung Exp $
 
 # options for MP configuration through the MP spec
 defflag opt_mpbios.h MPBIOS MPVERBOSE MPDEBUG MPBIOS_SCANPCI
@@ -85,6 +85,7 @@
 file	arch/x86/x86/syscall.c
 file	arch/x86/x86/vm_machdep.c
 file	arch/x86/x86/x86_autoconf.c
+file	arch/x86/x86/x86_userconf.c		userconf
 file	arch/x86/x86/x86_machdep.c
 
 define	lapic

Index: src/sys/arch/x86/include/cpu.h
diff -u src/sys/arch/x86/include/cpu.h:1.33 src/sys/arch/x86/include/cpu.h:1.34
--- src/sys/arch/x86/include/cpu.h:1.33	Thu May 26 04:25:28 2011
+++ src/sys/arch/x86/include/cpu.h	Tue May 31 23:28:52 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: cpu.h,v 1.33 2011/05/26 04:25:28 uebayasi Exp $	*/
+/*	$NetBSD: cpu.h,v 1.34 2011/05/31 23:28:52 dyoung Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -439,8 +439,6 @@
 
 #include machine/psl.h	/* Must be after struct cpu_info declaration */
 
-#define __HAVE_USERCONF_BOOTINFO
-
 #endif /* _KERNEL || __KMEMUSER */
 
 /*

Index: src/sys/arch/x86/x86/x86_machdep.c
diff -u src/sys/arch/x86/x86/x86_machdep.c:1.49 src/sys/arch/x86/x86/x86_machdep.c:1.50
--- src/sys/arch/x86/x86/x86_machdep.c:1.49	Thu May 26 16:38:57 2011
+++ src/sys/arch/x86/x86/x86_machdep.c	Tue May 31 23:28:53 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: x86_machdep.c,v 1.49 2011/05/26 16:38:57 para Exp $	*/
+/*	$NetBSD: x86_machdep.c,v 1.50 2011/05/31 23:28:53 dyoung Exp $	*/
 
 /*-
  * Copyright (c) 2002, 2006, 2007 YAMAMOTO Takashi,
@@ -31,12 +31,11 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: x86_machdep.c,v 1.49 2011/05/26 16:38:57 para Exp $);
+__KERNEL_RCSID(0, $NetBSD: x86_machdep.c,v 1.50 2011/05/31 23:28:53 dyoung Exp $);
 
 #include opt_modular.h
 #include opt_physmem.h
 #include opt_splash.h
-#include opt_userconf.h
 
 #include sys/types.h
 #include sys/param.h
@@ -52,10 +51,6 @@
 #include sys/sysctl.h
 #include sys/extent.h
 
-#if defined(USERCONF)
-#include sys/userconf.h
-#endif /* defined(USERCONF) */
-
 #include x86/cpuvar.h
 #include x86/cputypes.h
 #include x86/machdep.h
@@ -182,28 +177,6 @@
 }
 #endif	/* MODULAR */
 
-#if defined(USERCONF)
-void
-userconf_bootinfo(void)
-{
-	struct btinfo_userconfcommands *biuc;
-	struct bi_userconfcommand *bi, *bimax;
-
-	biuc = lookup_bootinfo(BTINFO_USERCONFCOMMANDS);
-	if (biuc == NULL) {
-		aprint_debug(No bootinfo commands at boot\n);
-		return;
-	}
-
-	bi = (struct bi_userconfcommand *)((uint8_t *)biuc + sizeof(*biuc));
-	bimax = bi + biuc-num;
-	for (; bi  bimax; bi++) {
-		aprint_debug(Processing userconf command: %s\n, bi-text);
-		userconf_parse(bi-text);
-	}
-}
-#endif /* defined (USERCONF) */
-
 void
 cpu_need_resched(struct cpu_info *ci, int flags)
 {

Index: src/sys/kern/init_main.c
diff -u src/sys/kern/init_main.c:1.430 src/sys/kern/init_main.c:1.431
--- src/sys/kern/init_main.c:1.430	Thu May 26 04:25:26 2011
+++ src/sys/kern/init_main.c	Tue May 31 23:28:53 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: init_main.c,v 1.430 2011/05/26 04:25:26 uebayasi Exp $	*/
+/*	$NetBSD: init_main.c,v 1.431 2011/05/31 23:28:53 dyoung Exp $	*/
 
 /*-
  * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
@@ -97,7 +97,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: init_main.c,v 1.430 2011/05/26 04:25:26 uebayasi Exp $);
+__KERNEL_RCSID(0, $NetBSD: init_main.c,v 1.431 

CVS commit: src

2011-05-31 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Wed Jun  1 02:22:20 UTC 2011

Modified Files:
src/distrib/sets/lists/comp: mi
src/share/man/man9: Makefile uvm.9
Added Files:
src/share/man/man9: uvm_km.9 uvm_map.9

Log Message:
Split parts of uvm(9) into uvm_km(9) and uvm_map(9) man pages.

OK mrg@


To generate a diff of this commit:
cvs rdiff -u -r1.1626 -r1.1627 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.346 -r1.347 src/share/man/man9/Makefile
cvs rdiff -u -r1.105 -r1.106 src/share/man/man9/uvm.9
cvs rdiff -u -r0 -r1.1 src/share/man/man9/uvm_km.9 \
src/share/man/man9/uvm_map.9

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/comp/mi
diff -u src/distrib/sets/lists/comp/mi:1.1626 src/distrib/sets/lists/comp/mi:1.1627
--- src/distrib/sets/lists/comp/mi:1.1626	Mon May 30 02:10:25 2011
+++ src/distrib/sets/lists/comp/mi	Wed Jun  1 02:22:19 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: mi,v 1.1626 2011/05/30 02:10:25 christos Exp $
+#	$NetBSD: mi,v 1.1627 2011/06/01 02:22:19 rmind Exp $
 #
 # Note: don't delete entries from here - mark them as obsolete instead.
 #
@@ -10169,6 +10169,7 @@
 ./usr/share/man/cat9/uvm_init_limits.0		comp-sys-catman		.cat
 ./usr/share/man/cat9/uvm_io.0			comp-sys-catman		.cat
 ./usr/share/man/cat9/uvm_kernacc.0		comp-sys-catman		.cat
+./usr/share/man/cat9/uvm_km.0			comp-sys-catman		.cat
 ./usr/share/man/cat9/uvm_km_alloc.0		comp-sys-catman		.cat
 ./usr/share/man/cat9/uvm_km_alloc1.0		comp-obsolete		obsolete
 ./usr/share/man/cat9/uvm_km_free.0		comp-sys-catman		.cat
@@ -16106,6 +16107,7 @@
 ./usr/share/man/html9/uvm_init_limits.html	comp-sys-htmlman	html
 ./usr/share/man/html9/uvm_io.html		comp-sys-htmlman	html
 ./usr/share/man/html9/uvm_kernacc.html		comp-sys-htmlman	html
+./usr/share/man/html9/uvm_km.html		comp-sys-htmlman	html
 ./usr/share/man/html9/uvm_km_alloc.html		comp-sys-htmlman	html
 ./usr/share/man/html9/uvm_km_free.html		comp-sys-htmlman	html
 ./usr/share/man/html9/uvm_km_suballoc.html	comp-sys-htmlman	html
@@ -22259,6 +22261,7 @@
 ./usr/share/man/man9/uvm_init_limits.9		comp-sys-man		.man
 ./usr/share/man/man9/uvm_io.9			comp-sys-man		.man
 ./usr/share/man/man9/uvm_kernacc.9		comp-sys-man		.man
+./usr/share/man/man9/uvm_km.9			comp-sys-man		.man
 ./usr/share/man/man9/uvm_km_alloc.9		comp-sys-man		.man
 ./usr/share/man/man9/uvm_km_alloc1.9		comp-obsolete		obsolete
 ./usr/share/man/man9/uvm_km_free.9		comp-sys-man		.man

Index: src/share/man/man9/Makefile
diff -u src/share/man/man9/Makefile:1.346 src/share/man/man9/Makefile:1.347
--- src/share/man/man9/Makefile:1.346	Wed Apr  6 05:40:19 2011
+++ src/share/man/man9/Makefile	Wed Jun  1 02:22:18 2011
@@ -1,4 +1,4 @@
-#   $NetBSD: Makefile,v 1.346 2011/04/06 05:40:19 jruoho Exp $
+#   $NetBSD: Makefile,v 1.347 2011/06/01 02:22:18 rmind Exp $
 
 #	Makefile for section 9 (kernel function and variable) manual pages.
 
@@ -54,7 +54,7 @@
 	vattr.9 veriexec.9 vcons.9 vfs.9 vfs_hooks.9 vfsops.9 vfssubr.9 \
 	video.9 vme.9 \
 	vnfileops.9 vnode.9 vnodeops.9 vnsubr.9 \
-	ubc.9 usbdi.9 uvm.9 vmem.9 \
+	ubc.9 usbdi.9 uvm.9 uvm_km.9 uvm_map.9 vmem.9 \
 	wdc.9 workqueue.9 \
 	wscons.9 wsdisplay.9 wsfont.9 wskbd.9 wsmouse.9 \
 	xcall.9
@@ -734,18 +734,12 @@
 	tc.9 TC_PHYS_TO_UNCACHED.9
 MLINKS+=todr.9 todr_gettime.9 todr.9 todr_settime.9 \
 	todr.9 clock_ymdhms_to_secs.9 todr.9 clock_secs_to_ymdhms.9
+
 MLINKS+=ubc.9 ubc_alloc.9 ubc.9 ubc_release.9 ubc.9 ubc_uiomove.9
 MLINKS+=uvm.9 uvm_init.9 uvm.9 uvm_init_limits.9 uvm.9 uvm_setpagesize.9 \
-	uvm.9 uvm_swap_init.9 uvm.9 uvm_map.9 uvm.9 uvm_unmap.9 \
-	uvm.9 uvm_map_pageable.9 \
-	uvm.9 uvm_map_checkprot.9 uvm.9 uvm_map_protect.9 \
-	uvm.9 uvm_deallocate.9 uvm.9 uvmspace_alloc.9 uvm.9 uvmspace_exec.9 \
-	uvm.9 uvmspace_fork.9 uvm.9 uvmspace_free.9 uvm.9 uvmspace_share.9 \
-	uvm.9 uvmspace_unshare.9 uvm.9 uvm_fault.9 \
+	uvm.9 uvm_swap_init.9 uvm.9 uvm_fault.9 \
 	uvm.9 uvm_vnp_setsize.9 \
-	uvm.9 uvm_io.9 uvm.9 uvm_km_alloc.9 \
-	uvm.9 uvm_km_suballoc.9 uvm.9 uvm_km_free.9 \
-	uvm.9 uvm_pagealloc.9 \
+	uvm.9 uvm_io.9 uvm.9 uvm_pagealloc.9 \
 	uvm.9 uvm_pagerealloc.9 uvm.9 uvm_pagefree.9 uvm.9 uvm_pglistalloc.9 \
 	uvm.9 uvm_pglistfree.9 uvm.9 uvm_page_physload.9 uvm.9 uvm_pageout.9 \
 	uvm.9 uvm_scheduler.9 uvm.9 uvm_swapin.9 uvm.9 uao_create.9 \
@@ -755,6 +749,15 @@
 	uvm.9 uvm_fork.9 uvm.9 uvm_grow.9 \
 	uvm.9 uvn_findpages.9 \
 	uvm.9 uvm_loan.9 uvm.9 uvm_unloan.9
+MLINKS+=uvm_km.9 uvm_km_alloc.9 uvm_km.9 uvm_km_free.9 \
+	uvm_km.9 uvm_km_suballoc.9
+MLINKS+=uvm_map.9 uvm_unmap.9 uvm_map.9 uvm_map_pageable.9 \
+	uvm_map.9 uvm_map_checkprot.9 uvm_map.9 uvm_map_protect.9 \
+	uvm_map.9 uvm_deallocate.9 uvm_map.9 uvmspace_alloc.9 \
+	uvm_map.9 uvmspace_exec.9 uvm_map.9 uvmspace_fork.9 \
+	uvm_map.9 uvmspace_free.9 uvm_map.9 uvmspace_share.9 \
+	uvm_map.9 uvmspace_unshare.9
+
 MLINKS+=vme.9 vme_probe.9 \
 	vme.9 vme_space_map.9 \
 	vme.9 

CVS commit: src/sys/kern

2011-05-31 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Jun  1 02:43:33 UTC 2011

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

Log Message:
provide a diagnostic for unsplit drivers.


To generate a diff of this commit:
cvs rdiff -u -r1.215 -r1.216 src/sys/kern/subr_autoconf.c

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

Modified files:

Index: src/sys/kern/subr_autoconf.c
diff -u src/sys/kern/subr_autoconf.c:1.215 src/sys/kern/subr_autoconf.c:1.216
--- src/sys/kern/subr_autoconf.c:1.215	Sun Apr 24 14:46:22 2011
+++ src/sys/kern/subr_autoconf.c	Tue May 31 22:43:33 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: subr_autoconf.c,v 1.215 2011/04/24 18:46:22 rmind Exp $ */
+/* $NetBSD: subr_autoconf.c,v 1.216 2011/06/01 02:43:33 christos Exp $ */
 
 /*
  * Copyright (c) 1996, 2000 Christopher G. Demetriou
@@ -77,7 +77,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: subr_autoconf.c,v 1.215 2011/04/24 18:46:22 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: subr_autoconf.c,v 1.216 2011/06/01 02:43:33 christos Exp $);
 
 #ifdef _KERNEL_OPT
 #include opt_ddb.h
@@ -1330,6 +1330,9 @@
 		dev = kmem_zalloc(sizeof(*dev), KM_SLEEP);
 	} else {
 		dev = dev_private;
+#ifdef DIAGNOSTIC
+		printf(%s has not been converted to device_t\n, cd-cd_name);
+#endif
 	}
 	if (dev == NULL)
 		panic(config_devalloc: memory allocation for device_t failed);



CVS commit: src/tests/syscall

2011-05-31 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Wed Jun  1 03:39:45 UTC 2011

Modified Files:
src/tests/syscall: t_pollts.c

Log Message:
Check also basic EFAULT and EINVAL from bogus calls to pollts(2).


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/tests/syscall/t_pollts.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/syscall/t_pollts.c
diff -u src/tests/syscall/t_pollts.c:1.2 src/tests/syscall/t_pollts.c:1.3
--- src/tests/syscall/t_pollts.c:1.2	Sun May 29 12:57:14 2011
+++ src/tests/syscall/t_pollts.c	Wed Jun  1 03:39:45 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: t_pollts.c,v 1.2 2011/05/29 12:57:14 tron Exp $	*/
+/*	$NetBSD: t_pollts.c,v 1.3 2011/06/01 03:39:45 jruoho Exp $	*/
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -31,6 +31,7 @@
 
 #include sys/time.h
 
+#include errno.h
 #include fcntl.h
 #include paths.h
 #include poll.h
@@ -39,23 +40,15 @@
 
 #include atf-c.h
 
-ATF_TC(pollts);
-ATF_TC_HEAD(pollts, tc)
+ATF_TC(pollts_basic);
+ATF_TC_HEAD(pollts_basic, tc)
 {
 	atf_tc_set_md_var(tc, timeout, 10);
 	atf_tc_set_md_var(tc, descr,
 	Basis functionality test for pollts(2));
 }
 
-ATF_TC(pollts_sigmask);
-ATF_TC_HEAD(pollts_sigmask, tc)
-{
-	atf_tc_set_md_var(tc, timeout, 10);
-	atf_tc_set_md_var(tc, descr,
-	Check that pollts_sigmask(2) restores the signal mask);
-}
-
-ATF_TC_BODY(pollts, tc)
+ATF_TC_BODY(pollts_basic, tc)
 {
 	int fds[2];
 	struct pollfd pfds[2];
@@ -119,6 +112,42 @@
 	ATF_REQUIRE_EQ(close(fds[1]), 0);
 }
 
+ATF_TC(pollts_err);
+ATF_TC_HEAD(pollts_err, tc)
+{
+	atf_tc_set_md_var(tc, descr, Check errors from pollts(2));
+}
+
+ATF_TC_BODY(pollts_err, tc)
+{
+	struct timespec timeout;
+	struct pollfd pfd;
+	int fd = 0;
+
+	pfd.fd = fd;
+	pfd.events = POLLIN;
+
+	timeout.tv_sec = 1;
+	timeout.tv_nsec = 0;
+
+	errno = 0;
+	ATF_REQUIRE_ERRNO(EFAULT, pollts((void *)-1, 1, timeout, NULL) != 0);
+
+	timeout.tv_sec = -1;
+	timeout.tv_nsec = -1;
+
+	errno = 0;
+	ATF_REQUIRE_ERRNO(EINVAL, pollts(pfd, 1, timeout, NULL) != 0);
+}
+
+ATF_TC(pollts_sigmask);
+ATF_TC_HEAD(pollts_sigmask, tc)
+{
+	atf_tc_set_md_var(tc, timeout, 10);
+	atf_tc_set_md_var(tc, descr,
+	Check that pollts(2) restores the signal mask);
+}
+
 ATF_TC_BODY(pollts_sigmask, tc)
 {
 	int fd;
@@ -143,7 +172,7 @@
 	ATF_REQUIRE_EQ(sigfillset(mask), 0);
 	ATF_REQUIRE_EQ(sigprocmask(SIG_UNBLOCK, mask, NULL), 0);
 
-	/* 
+	/*
 	 * Check that pollts(2) immediately returns. We block *all*
 	 * signals during pollts(2).
 	 */
@@ -160,7 +189,9 @@
 
 ATF_TP_ADD_TCS(tp)
 {
-	ATF_TP_ADD_TC(tp, pollts);
+
+	ATF_TP_ADD_TC(tp, pollts_basic);
+	ATF_TP_ADD_TC(tp, pollts_err);
 	ATF_TP_ADD_TC(tp, pollts_sigmask);
 
 	return atf_no_error();



CVS commit: src/sys/dev/pci

2011-05-31 Thread Michael Lorenz
Module Name:src
Committed By:   macallan
Date:   Wed Jun  1 05:06:17 UTC 2011

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

Log Message:
move wsdisplay_accessops into the softc so multiple instances have a chance
to work without stepping on each other's toes


To generate a diff of this commit:
cvs rdiff -u -r1.66 -r1.67 src/sys/dev/pci/machfb.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/machfb.c
diff -u src/sys/dev/pci/machfb.c:1.66 src/sys/dev/pci/machfb.c:1.67
--- src/sys/dev/pci/machfb.c:1.66	Mon May 16 00:59:37 2011
+++ src/sys/dev/pci/machfb.c	Wed Jun  1 05:06:17 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: machfb.c,v 1.66 2011/05/16 00:59:37 macallan Exp $	*/
+/*	$NetBSD: machfb.c,v 1.67 2011/06/01 05:06:17 macallan Exp $	*/
 
 /*
  * Copyright (c) 2002 Bang Jun-Young
@@ -34,7 +34,7 @@
 
 #include sys/cdefs.h
 __KERNEL_RCSID(0, 
-	$NetBSD: machfb.c,v 1.66 2011/05/16 00:59:37 macallan Exp $);
+	$NetBSD: machfb.c,v 1.67 2011/06/01 05:06:17 macallan Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -152,6 +152,7 @@
 	u_char sc_cmap_blue[256];
 	int sc_dacw, sc_blanked, sc_console;
 	struct vcons_data vd;
+	struct wsdisplay_accessops sc_accessops;
 };
 
 struct mach64_crtcregs {
@@ -378,16 +379,6 @@
 static int	mach64_load_font(void *, void *, struct wsdisplay_font *);
 #endif
 
-static struct wsdisplay_accessops mach64_accessops = {
-	mach64_ioctl,
-	mach64_mmap,
-	NULL,			/* vcons_alloc_screen */
-	NULL,			/* vcons_free_screen */
-	NULL,			/* vcons_show_screen */
-	NULL,			/* load_font */
-	NULL,			/* polls */
-	NULL,			/* scroll */
-};
 
 static struct vcons_screen mach64_console_screen;
 
@@ -533,6 +524,8 @@
 	sc-sc_nfunc = pa-pa_function;
 	sc-sc_locked = 0;
 	sc-sc_iot = pa-pa_iot;
+	sc-sc_accessops.ioctl = mach64_ioctl;
+	sc-sc_accessops.mmap = mach64_mmap;
 
 	pci_devinfo(pa-pa_id, pa-pa_class, 0, devinfo, sizeof(devinfo));
 	aprint_normal(: %s (rev. 0x%02x)\n, devinfo, 
@@ -763,7 +756,7 @@
 	wsfont_init();
 	
 	sc-sc_bg = WS_DEFAULT_BG;
-	vcons_init(sc-vd, sc, mach64_defaultscreen, mach64_accessops);
+	vcons_init(sc-vd, sc, mach64_defaultscreen, sc-sc_accessops);
 	sc-vd.init_screen = mach64_init_screen;
 
 	mach64_init_lut(sc);
@@ -794,7 +787,7 @@
 		
 	aa.console = sc-sc_console;
 	aa.scrdata = mach64_screenlist;
-	aa.accessops = mach64_accessops;
+	aa.accessops = sc-sc_accessops;
 	aa.accesscookie = sc-vd;
 
 	config_found(self, aa, wsemuldisplaydevprint);



CVS commit: [matt-nb5-mips64] src/distrib/sets/lists/comp

2011-05-31 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Wed Jun  1 05:46:13 UTC 2011

Modified Files:
src/distrib/sets/lists/comp [matt-nb5-mips64]: ad.mips

Log Message:
if elf2aout is obsolete, it's debug file is too.


To generate a diff of this commit:
cvs rdiff -u -r1.34.8.1 -r1.34.8.2 src/distrib/sets/lists/comp/ad.mips

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/comp/ad.mips
diff -u src/distrib/sets/lists/comp/ad.mips:1.34.8.1 src/distrib/sets/lists/comp/ad.mips:1.34.8.2
--- src/distrib/sets/lists/comp/ad.mips:1.34.8.1	Wed Aug 26 03:43:23 2009
+++ src/distrib/sets/lists/comp/ad.mips	Wed Jun  1 05:46:13 2011
@@ -1,5 +1,5 @@
-# $NetBSD: ad.mips,v 1.34.8.1 2009/08/26 03:43:23 matt Exp $
-./usr/bin/elf2aoutcomp-sysutil-bin	obsolete
+# ad.mips,v 1.34.8.1 2009/08/26 03:43:23 matt Exp
+./usr/bin/elf2aoutcomp-obsolete		obsolete
 ./usr/bin/elf2ecoffcomp-sysutil-bin
 ./usr/include/mipscomp-c-include
 ./usr/include/mips/ansi.h			comp-c-include
@@ -59,5 +59,5 @@
 ./usr/include/mips/varargs.h			comp-c-include
 ./usr/include/mips/vmparam.h			comp-c-include
 ./usr/include/mips/wchar_limits.h		comp-c-include
-./usr/libdata/debug/usr/bin/elf2aout.debug	comp-sysutil-debug	debug
+./usr/libdata/debug/usr/bin/elf2aout.debug	comp-obsolete		obsolete
 ./usr/libdata/debug/usr/bin/elf2ecoff.debug	comp-sysutil-debug	debug