CVS commit: src/sys/netinet

2009-06-06 Thread Takahiro Kambe
Module Name:src
Committed By:   taca
Date:   Sun Jun  7 06:11:18 UTC 2009

Modified Files:
src/sys/netinet: ip_carp.c

Log Message:
Make ip_carp.c compile, fixing usage of CARP_LOG().


To generate a diff of this commit:
cvs rdiff -u -r1.37 -r1.38 src/sys/netinet/ip_carp.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/netinet/ip_carp.c
diff -u src/sys/netinet/ip_carp.c:1.37 src/sys/netinet/ip_carp.c:1.38
--- src/sys/netinet/ip_carp.c:1.37	Wed May 27 21:32:31 2009
+++ src/sys/netinet/ip_carp.c	Sun Jun  7 06:11:18 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: ip_carp.c,v 1.37 2009/05/27 21:32:31 christos Exp $	*/
+/*	$NetBSD: ip_carp.c,v 1.38 2009/06/07 06:11:18 taca Exp $	*/
 /*	$OpenBSD: ip_carp.c,v 1.113 2005/11/04 08:11:54 mcbride Exp $	*/
 
 /*
@@ -28,7 +28,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ip_carp.c,v 1.37 2009/05/27 21:32:31 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ip_carp.c,v 1.38 2009/06/07 06:11:18 taca Exp $");
 
 /*
  * TODO:
@@ -697,7 +697,7 @@
 		if (timercmp(&sc_tv, &ch_tv, >) ||
 		timercmp(&sc_tv, &ch_tv, ==)) {
 			callout_stop(&sc->sc_ad_tmo);
-			CARP_LOG(sc, "MASTER -> BACKUP (more frequent advertisement received)");
+			CARP_LOG(sc, ("MASTER -> BACKUP (more frequent advertisement received)"));
 			carp_set_state(sc, BACKUP);
 			carp_setrun(sc, 0);
 			carp_setroute(sc, RTM_DELETE);
@@ -709,7 +709,7 @@
 		 * and this one claims to be slower, treat him as down.
 		 */
 		if (carp_opts[CARPCTL_PREEMPT] && timercmp(&sc_tv, &ch_tv, <)) {
-			CARP_LOG(sc, "BACKUP -> MASTER (preempting a slower master)");
+			CARP_LOG(sc, ("BACKUP -> MASTER (preempting a slower master)"));
 			carp_master_down(sc);
 			break;
 		}
@@ -721,7 +721,7 @@
 		 */
 		sc_tv.tv_sec = sc->sc_advbase * 3;
 		if (timercmp(&sc_tv, &ch_tv, <)) {
-			CARP_LOG(sc, "BACKUP -> MASTER (master timed out)")
+			CARP_LOG(sc, ("BACKUP -> MASTER (master timed out)"));
 			carp_master_down(sc);
 			break;
 		}
@@ -1391,7 +1391,7 @@
 	case MASTER:
 		break;
 	case BACKUP:
-		CARP_LOG(sc, "INIT -> MASTER (preempting)");
+		CARP_LOG(sc, ("INIT -> MASTER (preempting)"));
 		carp_set_state(sc, MASTER);
 		carp_send_ad(sc);
 		carp_send_arp(sc);



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

2009-06-06 Thread YAMAMOTO Takashi
Module Name:src
Committed By:   yamt
Date:   Sun Jun  7 03:12:40 UTC 2009

Modified Files:
src/common/lib/libc/gen: ptree.c

Log Message:
fix comment typos.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/common/lib/libc/gen/ptree.c

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

Modified files:

Index: src/common/lib/libc/gen/ptree.c
diff -u src/common/lib/libc/gen/ptree.c:1.4 src/common/lib/libc/gen/ptree.c:1.5
--- src/common/lib/libc/gen/ptree.c:1.4	Sun Jan 18 12:06:14 2009
+++ src/common/lib/libc/gen/ptree.c	Sun Jun  7 03:12:40 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: ptree.c,v 1.4 2009/01/18 12:06:14 lukem Exp $ */
+/* $NetBSD: ptree.c,v 1.5 2009/06/07 03:12:40 yamt Exp $ */
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -40,7 +40,7 @@
 #include 
 #include 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ptree.c,v 1.4 2009/01/18 12:06:14 lukem Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ptree.c,v 1.5 2009/06/07 03:12:40 yamt Exp $");
 #else
 #include 
 #include 
@@ -53,7 +53,7 @@
 #else
 #define	KASSERT(e)	do { } while (/*CONSTCOND*/ 0)
 #endif
-__RCSID("$NetBSD: ptree.c,v 1.4 2009/01/18 12:06:14 lukem Exp $");
+__RCSID("$NetBSD: ptree.c,v 1.5 2009/06/07 03:12:40 yamt Exp $");
 #endif /* _KERNEL || _STANDALONE */
 
 #ifdef _LIBC
@@ -82,7 +82,7 @@
  * Each is separate from the other.  Every branch is tagged as to whether
  * it points to a leaf or a branch.  This is not an attribute of the object
  * but of the pointer to the object.  The low bit of the pointer is used as
- * the tag to determine wether it points to a leaf or branch identity, with
+ * the tag to determine whether it points to a leaf or branch identity, with
  * branch identities having the low bit set.
  * 
  * A node's branch identity has one rule: when traversing the tree from the
@@ -100,7 +100,7 @@
  * match the first N bits) has children who first N bits match the mask nodes,
  * that mask node is converted from being a leaf node to being a one-way
  * branch-node.  The mask becomes fixed in position in the tree.  The mask
- * will alaways be the longest mask match for its descendants (unless they
+ * will always be the longest mask match for its descendants (unless they
  * traverse an even longer match).
  */
 



CVS commit: src/crypto/external/bsd/netpgp/dist

2009-06-06 Thread Alistair G. Crooks
Module Name:src
Committed By:   agc
Date:   Sun Jun  7 01:55:03 UTC 2009

Modified Files:
src/crypto/external/bsd/netpgp/dist: tst

Log Message:
Add a test for the null list-packets file.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/crypto/external/bsd/netpgp/dist/tst

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

Modified files:

Index: src/crypto/external/bsd/netpgp/dist/tst
diff -u src/crypto/external/bsd/netpgp/dist/tst:1.6 src/crypto/external/bsd/netpgp/dist/tst:1.7
--- src/crypto/external/bsd/netpgp/dist/tst:1.6	Mon May 25 06:43:31 2009
+++ src/crypto/external/bsd/netpgp/dist/tst	Sun Jun  7 01:55:02 2009
@@ -10,7 +10,7 @@
 	su root -c "make install"'
 
 passed=0
-total=8
+total=9
 echo "==> sign/verify 180938 file"
 cp configure a
 /usr/bin/netpgp --sign a
@@ -48,4 +48,7 @@
 echo "==> version information"
 /usr/bin/netpgp --version
 rm -f a a.gpg b b.gpg c c.gpg d d.gpg e f f.sig a2 a3
+echo "==> no list-packets file"
+/usr/bin/netpgp --list-packets || passed=$(expr $passed + 1)
+rm -f a a.gpg b b.gpg c c.gpg d d.gpg e f f.sig a2 a3
 echo "Passed ${passed}/${total} tests"



CVS commit: src/crypto/external/bsd/netpgp/dist/src/lib

2009-06-06 Thread Alistair G. Crooks
Module Name:src
Committed By:   agc
Date:   Sun Jun  7 01:52:48 UTC 2009

Modified Files:
src/crypto/external/bsd/netpgp/dist/src/lib: netpgp.c

Log Message:
Fix an core dump reported by Oliver Gould - if there is no file from which
to read packets to list, fail with a decent error message.


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 \
src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c

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

Modified files:

Index: src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c
diff -u src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c:1.19 src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c:1.20
--- src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c:1.19	Sun May 31 23:26:20 2009
+++ src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c	Sun Jun  7 01:52:48 2009
@@ -34,7 +34,7 @@
 
 #if defined(__NetBSD__)
 __COPYRIGHT("@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.");
-__RCSID("$NetBSD: netpgp.c,v 1.19 2009/05/31 23:26:20 agc Exp $");
+__RCSID("$NetBSD: netpgp.c,v 1.20 2009/06/07 01:52:48 agc Exp $");
 #endif
 
 #include 
@@ -607,6 +607,10 @@
 	char		*homedir;
 
 	io = netpgp->io;
+	if (f == NULL) {
+		(void) fprintf(io->errs, "No file containing packets\n");
+		return 0;
+	}
 	homedir = netpgp_getvar(netpgp, "homedir");
 	if (pubringname == NULL) {
 		(void) snprintf(ringname, sizeof(ringname),



CVS commit: [jym-xensuspend] src/sys/arch/xen/x86

2009-06-06 Thread Jean-Yves Migeon
Module Name:src
Committed By:   jym
Date:   Sat Jun  6 22:30:41 UTC 2009

Modified Files:
src/sys/arch/xen/x86 [jym-xensuspend]: intr.c

Log Message:
As requested by cegger@, apply the following patch to jym-xensuspend branch:

Interrupt handling in Xen 3.5 changed. There's no longer
a hardcoded upper limit. So *our* upper limit of 200 may be different from 
machine to machine now.
So just retry if the hypercall failed.


To generate a diff of this commit:
cvs rdiff -u -r1.21.8.1 -r1.21.8.2 src/sys/arch/xen/x86/intr.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/xen/x86/intr.c
diff -u src/sys/arch/xen/x86/intr.c:1.21.8.1 src/sys/arch/xen/x86/intr.c:1.21.8.2
--- src/sys/arch/xen/x86/intr.c:1.21.8.1	Wed May 13 17:18:50 2009
+++ src/sys/arch/xen/x86/intr.c	Sat Jun  6 22:30:41 2009
@@ -103,7 +103,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.21.8.1 2009/05/13 17:18:50 jym Exp $");
+__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.21.8.2 2009/06/06 22:30:41 jym Exp $");
 
 #include "opt_multiprocessor.h"
 #include "opt_xen.h"
@@ -257,6 +257,9 @@
 	 * of the next device if this one used this IRQ. The easiest is
 	 * to allocate IRQs top-down, starting with a high number.
 	 * 250 and 230 have been tried, but got rejected by Xen.
+	 *
+	 * Xen 3.5 also rejects 200. Try out all values until Xen accepts
+	 * or none is available.
 	 */
 	static int xen_next_irq = 200;
 	struct ioapic_softc *ioapic = ioapic_find(APIC_IRQ_APIC(*pirq));
@@ -271,11 +274,16 @@
 			irq = APIC_IRQ_LEGACY_IRQ(*pirq);
 			if (irq <= 0 || irq > 15)
 irq = xen_next_irq--;
+retry:
 			/* allocate vector and route interrupt */
 			op.cmd = PHYSDEVOP_ASSIGN_VECTOR;
 			op.u.irq_op.irq = irq;
-			if (HYPERVISOR_physdev_op(&op) < 0)
-panic("PHYSDEVOP_ASSIGN_VECTOR irq %d", irq);
+			if (HYPERVISOR_physdev_op(&op) < 0) {
+irq = xen_next_irq--;
+if (xen_next_irq == 15)
+	panic("PHYSDEVOP_ASSIGN_VECTOR irq %d", irq);
+goto retry;
+			}
 			irq2vect[irq] = op.u.irq_op.vector;
 			vect2irq[op.u.irq_op.vector] = irq;
 			pic->pic_addroute(pic, &phycpu_info_primary, pin,



CVS commit: [netbsd-5-0] src/doc

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:15:46 UTC 2009

Modified Files:
src/doc [netbsd-5-0]: CHANGES-5.0.1

Log Message:
tickets 790, 791


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.17 -r1.1.2.18 src/doc/CHANGES-5.0.1

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

Modified files:

Index: src/doc/CHANGES-5.0.1
diff -u src/doc/CHANGES-5.0.1:1.1.2.17 src/doc/CHANGES-5.0.1:1.1.2.18
--- src/doc/CHANGES-5.0.1:1.1.2.17	Fri Jun  5 18:58:54 2009
+++ src/doc/CHANGES-5.0.1	Sat Jun  6 22:15:46 2009
@@ -1,4 +1,4 @@
-# $NetBSD: CHANGES-5.0.1,v 1.1.2.17 2009/06/05 18:58:54 snj Exp $
+# $NetBSD: CHANGES-5.0.1,v 1.1.2.18 2009/06/06 22:15:46 bouyer Exp $
 
 A complete list of changes from the NetBSD 5.0 release to the NetBSD 5.0.1
 release:
@@ -318,3 +318,29 @@
 	setfunc_trampoline that does not call lwp_startup().
 	[skrll, ticket #793]
 
+distrib/common/parselist.awk			1.16
+distrib/sets/maketars1.66
+share/dict/Makefile1.17
+share/mk/bsd.README1.249
+share/mk/bsd.hostprog.mk			1.55
+share/mk/bsd.kmodule.mk1.19
+share/mk/bsd.lib.mk1.298
+share/mk/bsd.links.mk1.34
+share/mk/bsd.man.mk1.100
+share/mk/bsd.prog.mk1.241
+share/zoneinfo/Makefile1.43
+usr.bin/xinstall/xinstall.c			1.106 - 1.108 via patch
+
+	Various METALOG fixes, including entries sorting to
+	fix inconsistent shared sets among builds as seen in
+	/pub/NetBSD-daily/netbsd-5/20090401Z/shared/ and
+	/pub/NetBSD-daily/netbsd-5/200904010002Z/shared/ dirs.
+	Should fix PR 24457 and PR 41155.
+	[snj, ticket #790]
+
+sys/kern/sched_4bsd.c1.25
+
+	sched_pstats_hook: fix estcpu decay.
+	this makes my desktop usable when running "make -j4".
+	[rmind, ticket #791]
+



CVS commit: [netbsd-5] src/doc

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:15:22 UTC 2009

Modified Files:
src/doc [netbsd-5]: CHANGES-5.1

Log Message:
tickets 736, 769, 770, 790, 791, 794


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.26 -r1.1.2.27 src/doc/CHANGES-5.1

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

Modified files:

Index: src/doc/CHANGES-5.1
diff -u src/doc/CHANGES-5.1:1.1.2.26 src/doc/CHANGES-5.1:1.1.2.27
--- src/doc/CHANGES-5.1:1.1.2.26	Fri Jun  5 18:59:33 2009
+++ src/doc/CHANGES-5.1	Sat Jun  6 22:15:22 2009
@@ -1,4 +1,4 @@
-# $NetBSD: CHANGES-5.1,v 1.1.2.26 2009/06/05 18:59:33 snj Exp $
+# $NetBSD: CHANGES-5.1,v 1.1.2.27 2009/06/06 22:15:22 bouyer Exp $
 
 A complete list of changes from the NetBSD 5.0 release to the NetBSD 5.1
 release:
@@ -862,3 +862,54 @@
 	setfunc_trampoline that does not call lwp_startup().
 	[skrll, ticket #793]
 
+sbin/drvctl/drvctl.81.7 - 1.10
+sbin/drvctl/drvctl.c1.7, 1.9, 1.10 via patch
+
+	fix sign-compare issues
+	Add flag -n to suppress the first column of drvctl -l output.
+	[dyoung, ticket #736]
+
+sys/fs/udf/ecma167-udf.h			1.12
+
+	Make ecma167 header file compilable by pcc
+	[reinoud, ticket #769]
+
+sbin/newfs_udf/udf_create.c			1.16
+sys/fs/udf/udf_allocation.c			1.22, 1.23
+sys/fs/udf/udf_bswap.h1.6, 1.7
+sys/fs/udf/udf_subr.c1.88, 1.89
+
+	Various fixes for big endian machines.
+	[reinoud, ticket #770]
+
+distrib/common/parselist.awk			1.16
+distrib/sets/maketars1.66
+share/dict/Makefile1.17
+share/mk/bsd.README1.249
+share/mk/bsd.hostprog.mk			1.55
+share/mk/bsd.kmodule.mk1.19
+share/mk/bsd.lib.mk1.298
+share/mk/bsd.links.mk1.34
+share/mk/bsd.man.mk1.100
+share/mk/bsd.prog.mk1.241
+share/zoneinfo/Makefile1.43
+usr.bin/xinstall/xinstall.c			1.106 - 1.108 via patch
+
+	Various METALOG fixes, including entries sorting to
+	fix inconsistent shared sets among builds as seen in
+	/pub/NetBSD-daily/netbsd-5/20090401Z/shared/ and
+	/pub/NetBSD-daily/netbsd-5/200904010002Z/shared/ dirs.
+	Should fix PR 24457 and PR 41155.
+	[snj, ticket #790]
+
+sys/kern/sched_4bsd.c1.25
+
+	sched_pstats_hook: fix estcpu decay.
+	this makes my desktop usable when running "make -j4".
+	[rmind, ticket #791]
+
+sbin/atactl/atactl.c1.54
+
+	make space for a trailing \0 in model,revision and serial buffers.
+	[mlelstv, ticket #794]
+



CVS commit: [netbsd-5] src/sbin/atactl

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:14:31 UTC 2009

Modified Files:
src/sbin/atactl [netbsd-5]: atactl.c

Log Message:
Pull up following revision(s) (requested by mlelstv in ticket #794):
sbin/atactl/atactl.c: revision 1.54
make space for a trailing \0 in model,revision and serial buffers.


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.52.2.1 src/sbin/atactl/atactl.c

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

Modified files:

Index: src/sbin/atactl/atactl.c
diff -u src/sbin/atactl/atactl.c:1.52 src/sbin/atactl/atactl.c:1.52.2.1
--- src/sbin/atactl/atactl.c:1.52	Mon Aug 25 00:45:56 2008
+++ src/sbin/atactl/atactl.c	Sat Jun  6 22:14:31 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: atactl.c,v 1.52 2008/08/25 00:45:56 dholland Exp $	*/
+/*	$NetBSD: atactl.c,v 1.52.2.1 2009/06/06 22:14:31 bouyer Exp $	*/
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
 #include 
 
 #ifndef lint
-__RCSID("$NetBSD: atactl.c,v 1.52 2008/08/25 00:45:56 dholland Exp $");
+__RCSID("$NetBSD: atactl.c,v 1.52.2.1 2009/06/06 22:14:31 bouyer Exp $");
 #endif
 
 
@@ -856,9 +856,9 @@
 device_identify(int argc, char *argv[])
 {
 	struct ataparams *inqbuf;
-	char model[sizeof(inqbuf->atap_model)];
-	char revision[sizeof(inqbuf->atap_revision)];
-	char serial[sizeof(inqbuf->atap_serial)];
+	char model[sizeof(inqbuf->atap_model)+1];
+	char revision[sizeof(inqbuf->atap_revision)+1];
+	char serial[sizeof(inqbuf->atap_serial)+1];
 	int needswap = 0;
 
 	/* No arguments. */



CVS commit: [netbsd-5-0] src/sys/kern

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:13:05 UTC 2009

Modified Files:
src/sys/kern [netbsd-5-0]: sched_4bsd.c

Log Message:
Pull up following revision(s) (requested by rmind in ticket #791):
sys/kern/sched_4bsd.c: revision 1.25
sched_pstats_hook: fix estcpu decay.
this makes my desktop usable when running "make -j4".


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.24.10.1 src/sys/kern/sched_4bsd.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/sched_4bsd.c
diff -u src/sys/kern/sched_4bsd.c:1.24 src/sys/kern/sched_4bsd.c:1.24.10.1
--- src/sys/kern/sched_4bsd.c:1.24	Tue Oct  7 09:48:27 2008
+++ src/sys/kern/sched_4bsd.c	Sat Jun  6 22:13:04 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: sched_4bsd.c,v 1.24 2008/10/07 09:48:27 rmind Exp $	*/
+/*	$NetBSD: sched_4bsd.c,v 1.24.10.1 2009/06/06 22:13:04 bouyer Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2004, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -68,7 +68,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: sched_4bsd.c,v 1.24 2008/10/07 09:48:27 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sched_4bsd.c,v 1.24.10.1 2009/06/06 22:13:04 bouyer Exp $");
 
 #include "opt_ddb.h"
 #include "opt_lockdebug.h"
@@ -288,17 +288,22 @@
 void
 sched_pstats_hook(struct lwp *l, int batch)
 {
+	fixpt_t loadfac;
 
 	/*
 	 * If the LWP has slept an entire second, stop recalculating
 	 * its priority until it wakes up.
 	 */
 	KASSERT(lwp_locked(l, NULL));
-	if (l->l_slptime > 0) {
-		fixpt_t loadfac = 2 * (averunnable.ldavg[0]);
-		l->l_estcpu = decay_cpu(loadfac, l->l_estcpu);
-		resetpriority(l);
+	if (l->l_stat == LSSLEEP || l->l_stat == LSSTOP ||
+	l->l_stat == LSSUSPENDED) {
+		if (l->l_slptime > 1) {
+			return;
+		}
 	}
+	loadfac = 2 * (averunnable.ldavg[0]);
+	l->l_estcpu = decay_cpu(loadfac, l->l_estcpu);
+	resetpriority(l);
 }
 
 /*



CVS commit: [netbsd-5] src/sys/kern

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:12:44 UTC 2009

Modified Files:
src/sys/kern [netbsd-5]: sched_4bsd.c

Log Message:
Pull up following revision(s) (requested by rmind in ticket #791):
sys/kern/sched_4bsd.c: revision 1.25
sched_pstats_hook: fix estcpu decay.
this makes my desktop usable when running "make -j4".


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.24.4.1 src/sys/kern/sched_4bsd.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/sched_4bsd.c
diff -u src/sys/kern/sched_4bsd.c:1.24 src/sys/kern/sched_4bsd.c:1.24.4.1
--- src/sys/kern/sched_4bsd.c:1.24	Tue Oct  7 09:48:27 2008
+++ src/sys/kern/sched_4bsd.c	Sat Jun  6 22:12:44 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: sched_4bsd.c,v 1.24 2008/10/07 09:48:27 rmind Exp $	*/
+/*	$NetBSD: sched_4bsd.c,v 1.24.4.1 2009/06/06 22:12:44 bouyer Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2004, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -68,7 +68,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: sched_4bsd.c,v 1.24 2008/10/07 09:48:27 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sched_4bsd.c,v 1.24.4.1 2009/06/06 22:12:44 bouyer Exp $");
 
 #include "opt_ddb.h"
 #include "opt_lockdebug.h"
@@ -288,17 +288,22 @@
 void
 sched_pstats_hook(struct lwp *l, int batch)
 {
+	fixpt_t loadfac;
 
 	/*
 	 * If the LWP has slept an entire second, stop recalculating
 	 * its priority until it wakes up.
 	 */
 	KASSERT(lwp_locked(l, NULL));
-	if (l->l_slptime > 0) {
-		fixpt_t loadfac = 2 * (averunnable.ldavg[0]);
-		l->l_estcpu = decay_cpu(loadfac, l->l_estcpu);
-		resetpriority(l);
+	if (l->l_stat == LSSLEEP || l->l_stat == LSSTOP ||
+	l->l_stat == LSSUSPENDED) {
+		if (l->l_slptime > 1) {
+			return;
+		}
 	}
+	loadfac = 2 * (averunnable.ldavg[0]);
+	l->l_estcpu = decay_cpu(loadfac, l->l_estcpu);
+	resetpriority(l);
 }
 
 /*



CVS commit: [netbsd-5-0] src

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:10:50 UTC 2009

Modified Files:
src/distrib/common [netbsd-5-0]: parselist.awk
src/distrib/sets [netbsd-5-0]: maketars
src/share/dict [netbsd-5-0]: Makefile
src/share/mk [netbsd-5-0]: bsd.README bsd.hostprog.mk bsd.kmodule.mk
bsd.lib.mk bsd.links.mk bsd.man.mk bsd.prog.mk
src/share/zoneinfo [netbsd-5-0]: Makefile
src/usr.bin/xinstall [netbsd-5-0]: xinstall.c

Log Message:
Pull up following revision(s) (requested by snj in ticket #790):
share/mk/bsd.lib.mk: revision 1.298
share/mk/bsd.man.mk: revision 1.100
share/mk/bsd.hostprog.mk: revision 1.55
distrib/sets/maketars: revision 1.66
share/zoneinfo/Makefile: revision 1.43
share/mk/bsd.kmodule.mk: revision 1.19
usr.bin/xinstall/xinstall.c: revisions 1.106 - 1.108 via patch
share/mk/bsd.prog.mk: revision 1.241
share/dict/Makefile: revision 1.17
share/mk/bsd.README: revision 1.249
distrib/common/parselist.awk: revision 1.16
share/mk/bsd.links.mk: revision 1.34
Explicitly sort entries on preparing set files from METALOG.
METALOG could have different order due to install(1) race
on parallel builds, and mtree(8) doesn't sort files.
Should fix inconsistent shared sets among builds as seen in
/pub/NetBSD-daily/netbsd-5/20090401Z/shared/ and
/pub/NetBSD-daily/netbsd-5/200904010002Z/shared/ dirs.
Okay'ed by s...@.
Changes for installing with a metalog:
* When installing hard links and using a metalog, if -o, -g, -m, or -f
  args were explicitly specified on the command line, then believe them,
  but do not implicitly believe uname/gname/mode/flags from the file
  system.
* Output fields in the same order used by mtree.
Fix -Wshadow -Wcast-qual issues
Re-calculate size and digestresult after stripping, to ensure that
correct values appear in the metalog.
Add LINKSOWN, LINKSGRP, and LINKSMODE variables for use by bsd.links.mk
when installing hard links.  They have no effect except when using a
metalog, in which case the information is added to the metalog.  In
the future, these variables may be replaced by a method for explicitly
recording hard links in a metadata log.
Also change a few things that called ${INSTALL_LINK} without going
through bsd.links.mk.
Reviewed by perry and joerg.  This should fix PR 24457 and PR 41155.


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.15.8.1 src/distrib/common/parselist.awk
cvs rdiff -u -r1.64.6.2 -r1.64.6.2.2.1 src/distrib/sets/maketars
cvs rdiff -u -r1.16 -r1.16.42.1 src/share/dict/Makefile
cvs rdiff -u -r1.236.2.7 -r1.236.2.7.2.1 src/share/mk/bsd.README
cvs rdiff -u -r1.53 -r1.53.4.1 src/share/mk/bsd.hostprog.mk
cvs rdiff -u -r1.13.2.1 -r1.13.2.1.2.1 src/share/mk/bsd.kmodule.mk
cvs rdiff -u -r1.289.2.2 -r1.289.2.2.2.1 src/share/mk/bsd.lib.mk
cvs rdiff -u -r1.32 -r1.32.28.1 src/share/mk/bsd.links.mk
cvs rdiff -u -r1.98 -r1.98.6.1 src/share/mk/bsd.man.mk
cvs rdiff -u -r1.239.2.1 -r1.239.2.1.2.1 src/share/mk/bsd.prog.mk
cvs rdiff -u -r1.42 -r1.42.16.1 src/share/zoneinfo/Makefile
cvs rdiff -u -r1.103 -r1.103.6.1 src/usr.bin/xinstall/xinstall.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/common/parselist.awk
diff -u src/distrib/common/parselist.awk:1.15 src/distrib/common/parselist.awk:1.15.8.1
--- src/distrib/common/parselist.awk:1.15	Wed Apr 30 13:10:48 2008
+++ src/distrib/common/parselist.awk	Sat Jun  6 22:10:50 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: parselist.awk,v 1.15 2008/04/30 13:10:48 martin Exp $
+#	$NetBSD: parselist.awk,v 1.15.8.1 2009/06/06 22:10:50 bouyer Exp $
 #
 # Copyright (c) 2002 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -225,7 +225,7 @@
 crunchprog, 555);
 continue;
 			}
-			link(crunchprog, $i);
+			link(crunchprog, $i, 555);
 		}
 	}
 	next;
@@ -248,7 +248,7 @@
 		err("Usage: LINK prog link [...]");
 	if (mode == "install" || mode == "mtree" || mode == "populate") {
 		for (i = 3; i <= NF; i++)
-			link($2, $i);
+			link($2, $i, 444);
 	}
 	next;
 }
@@ -305,7 +305,8 @@
 	if (perm == "")
 		perm = 444;
 	if (mode == "install") {
-		printf("\t${INSTALL_FILE} -o ${BINOWN} -g ${BINGRP} -m %s %s %s/%s\n",
+		printf("\t${INSTALL_FILE} -o ${BINOWN} -g ${BINGRP}" \
+		" -m %s %s %s/%s\n",
 		perm, src, ENVIRON["TARGETDIR"], dest)
 	} else if (mode == "mtree") {
 		printf("./%s mode=%s\n", dest, perm);
@@ -316,13 +317,14 @@
 	}
 }
 
-function link (src, dest) \
+function link (src, dest, perm) \
 {
 	if (mode == "install") {
-		printf("\t${INSTALL_LINK} %s/%s %s/%s\n",
-		ENVIRON["TARGETDIR"], src, ENVIRON["TARGETDIR"], dest)
+		printf("\t${INSTALL_LINK} -o ${BINOWN} -g ${BINGRP}" \
+		" -m %s %s/%s %s/%s\n",
+		perm, ENVIRON["TARGETDIR"], src, ENVIRON["TARGETDIR"], dest)
 	} else if (mode == "mtree") {
-		printf("./%s\n", dest);
+		prin

CVS commit: [netbsd-5] src

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:10:13 UTC 2009

Modified Files:
src/distrib/common [netbsd-5]: parselist.awk
src/distrib/sets [netbsd-5]: maketars
src/share/dict [netbsd-5]: Makefile
src/share/mk [netbsd-5]: bsd.README bsd.hostprog.mk bsd.kmodule.mk
bsd.lib.mk bsd.links.mk bsd.man.mk bsd.prog.mk
src/share/zoneinfo [netbsd-5]: Makefile
src/usr.bin/xinstall [netbsd-5]: xinstall.c

Log Message:
Pull up following revision(s) (requested by snj in ticket #790):
share/mk/bsd.lib.mk: revision 1.298
share/mk/bsd.man.mk: revision 1.100
share/mk/bsd.hostprog.mk: revision 1.55
distrib/sets/maketars: revision 1.66
share/zoneinfo/Makefile: revision 1.43
share/mk/bsd.kmodule.mk: revision 1.19
usr.bin/xinstall/xinstall.c: revisions 1.106 - 1.108 via patch
share/mk/bsd.prog.mk: revision 1.241
share/dict/Makefile: revision 1.17
share/mk/bsd.README: revision 1.249
distrib/common/parselist.awk: revision 1.16
share/mk/bsd.links.mk: revision 1.34
Explicitly sort entries on preparing set files from METALOG.
METALOG could have different order due to install(1) race
on parallel builds, and mtree(8) doesn't sort files.
Should fix inconsistent shared sets among builds as seen in
/pub/NetBSD-daily/netbsd-5/20090401Z/shared/ and
/pub/NetBSD-daily/netbsd-5/200904010002Z/shared/ dirs.
Okay'ed by s...@.
Changes for installing with a metalog:
* When installing hard links and using a metalog, if -o, -g, -m, or -f
  args were explicitly specified on the command line, then believe them,
  but do not implicitly believe uname/gname/mode/flags from the file
  system.
* Output fields in the same order used by mtree.
Fix -Wshadow -Wcast-qual issues
Re-calculate size and digestresult after stripping, to ensure that
correct values appear in the metalog.
Add LINKSOWN, LINKSGRP, and LINKSMODE variables for use by bsd.links.mk
when installing hard links.  They have no effect except when using a
metalog, in which case the information is added to the metalog.  In
the future, these variables may be replaced by a method for explicitly
recording hard links in a metadata log.
Also change a few things that called ${INSTALL_LINK} without going
through bsd.links.mk.
Reviewed by perry and joerg.  This should fix PR 24457 and PR 41155.


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.15.4.1 src/distrib/common/parselist.awk
cvs rdiff -u -r1.64.6.2 -r1.64.6.3 src/distrib/sets/maketars
cvs rdiff -u -r1.16 -r1.16.38.1 src/share/dict/Makefile
cvs rdiff -u -r1.236.2.7 -r1.236.2.8 src/share/mk/bsd.README
cvs rdiff -u -r1.53 -r1.53.2.1 src/share/mk/bsd.hostprog.mk
cvs rdiff -u -r1.13.2.1 -r1.13.2.2 src/share/mk/bsd.kmodule.mk
cvs rdiff -u -r1.289.2.2 -r1.289.2.3 src/share/mk/bsd.lib.mk
cvs rdiff -u -r1.32 -r1.32.24.1 src/share/mk/bsd.links.mk
cvs rdiff -u -r1.98 -r1.98.2.1 src/share/mk/bsd.man.mk
cvs rdiff -u -r1.239.2.1 -r1.239.2.2 src/share/mk/bsd.prog.mk
cvs rdiff -u -r1.42 -r1.42.12.1 src/share/zoneinfo/Makefile
cvs rdiff -u -r1.103 -r1.103.4.1 src/usr.bin/xinstall/xinstall.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/common/parselist.awk
diff -u src/distrib/common/parselist.awk:1.15 src/distrib/common/parselist.awk:1.15.4.1
--- src/distrib/common/parselist.awk:1.15	Wed Apr 30 13:10:48 2008
+++ src/distrib/common/parselist.awk	Sat Jun  6 22:10:13 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: parselist.awk,v 1.15 2008/04/30 13:10:48 martin Exp $
+#	$NetBSD: parselist.awk,v 1.15.4.1 2009/06/06 22:10:13 bouyer Exp $
 #
 # Copyright (c) 2002 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -225,7 +225,7 @@
 crunchprog, 555);
 continue;
 			}
-			link(crunchprog, $i);
+			link(crunchprog, $i, 555);
 		}
 	}
 	next;
@@ -248,7 +248,7 @@
 		err("Usage: LINK prog link [...]");
 	if (mode == "install" || mode == "mtree" || mode == "populate") {
 		for (i = 3; i <= NF; i++)
-			link($2, $i);
+			link($2, $i, 444);
 	}
 	next;
 }
@@ -305,7 +305,8 @@
 	if (perm == "")
 		perm = 444;
 	if (mode == "install") {
-		printf("\t${INSTALL_FILE} -o ${BINOWN} -g ${BINGRP} -m %s %s %s/%s\n",
+		printf("\t${INSTALL_FILE} -o ${BINOWN} -g ${BINGRP}" \
+		" -m %s %s %s/%s\n",
 		perm, src, ENVIRON["TARGETDIR"], dest)
 	} else if (mode == "mtree") {
 		printf("./%s mode=%s\n", dest, perm);
@@ -316,13 +317,14 @@
 	}
 }
 
-function link (src, dest) \
+function link (src, dest, perm) \
 {
 	if (mode == "install") {
-		printf("\t${INSTALL_LINK} %s/%s %s/%s\n",
-		ENVIRON["TARGETDIR"], src, ENVIRON["TARGETDIR"], dest)
+		printf("\t${INSTALL_LINK} -o ${BINOWN} -g ${BINGRP}" \
+		" -m %s %s/%s %s/%s\n",
+		perm, ENVIRON["TARGETDIR"], src, ENVIRON["TARGETDIR"], dest)
 	} else if (mode == "mtree") {
-		printf("./%s\n", dest);
+		printf("./%s mode=%s\n", dest, perm)

CVS commit: [netbsd-5] src

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:04:40 UTC 2009

Modified Files:
src/sbin/newfs_udf [netbsd-5]: udf_create.c
src/sys/fs/udf [netbsd-5]: udf_allocation.c udf_bswap.h udf_subr.c

Log Message:
Pull up following revision(s) (requested by reinoud in ticket #770):
sys/fs/udf/udf_subr.c: revision 1.88, 1.89
sys/fs/udf/udf_bswap.h: revision 1.6, 1.7
sys/fs/udf/udf_allocation.c: revision 1.22, 1.23
sbin/newfs_udf/udf_create.c: revision 1.16
Fix *serious* bug in bswapping definitions for big endian machines.
ANSI-fy. No idea why they weren't so in the first place.
Fix newfs_udf to create a valid disc images on bigendian machines.
A descriptor's CRC lenth is 16 bit so use udf_rw16() on tag.desc_crc_len.
Forgot to use the udf_rw16() on the descriptor crc lengths of FID's!
Also fix a few dubiously formatted checks.
On creation of a new node, don't forget to set the length of the allocated
space in the right endian!
Account for the logical blocks recorded by the extent in the right endian!


To generate a diff of this commit:
cvs rdiff -u -r1.12.4.2 -r1.12.4.3 src/sbin/newfs_udf/udf_create.c
cvs rdiff -u -r1.18.4.2 -r1.18.4.3 src/sys/fs/udf/udf_allocation.c
cvs rdiff -u -r1.5 -r1.5.8.1 src/sys/fs/udf/udf_bswap.h
cvs rdiff -u -r1.73.4.10 -r1.73.4.11 src/sys/fs/udf/udf_subr.c

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

Modified files:

Index: src/sbin/newfs_udf/udf_create.c
diff -u src/sbin/newfs_udf/udf_create.c:1.12.4.2 src/sbin/newfs_udf/udf_create.c:1.12.4.3
--- src/sbin/newfs_udf/udf_create.c:1.12.4.2	Wed Feb 18 00:37:00 2009
+++ src/sbin/newfs_udf/udf_create.c	Sat Jun  6 22:04:40 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: udf_create.c,v 1.12.4.2 2009/02/18 00:37:00 snj Exp $ */
+/* $NetBSD: udf_create.c,v 1.12.4.3 2009/06/06 22:04:40 bouyer Exp $ */
 
 /*
  * Copyright (c) 2006, 2008 Reinoud Zandijk
@@ -28,7 +28,7 @@
 
 #include 
 #ifndef lint
-__RCSID("$NetBSD: udf_create.c,v 1.12.4.2 2009/02/18 00:37:00 snj Exp $");
+__RCSID("$NetBSD: udf_create.c,v 1.12.4.3 2009/06/06 22:04:40 bouyer Exp $");
 #endif /* not lint */
 
 #include 
@@ -1055,7 +1055,7 @@
 	assert(lvid);
 	assert(logvol);
 
-	lvid->integrity_type = udf_rw16(type);
+	lvid->integrity_type = udf_rw32(type);
 
 	num_partmappings = udf_rw32(logvol->n_pm);
 
@@ -1298,7 +1298,7 @@
 	fid->file_char = UDF_FILE_CHAR_DIR | UDF_FILE_CHAR_PAR;
 	fid->icb = *parent;
 	fid->icb.longad_uniqueid = udf_rw32((uint32_t) unique_id);
-	fid->tag.desc_crc_len = fidsize - UDF_DESC_TAG_LENGTH;
+	fid->tag.desc_crc_len = udf_rw16(fidsize - UDF_DESC_TAG_LENGTH);
 
 	/* we have to do the fid here explicitly for simplicity */
 	udf_validate_tag_and_crc_sums((union dscrptr *) fid);

Index: src/sys/fs/udf/udf_allocation.c
diff -u src/sys/fs/udf/udf_allocation.c:1.18.4.2 src/sys/fs/udf/udf_allocation.c:1.18.4.3
--- src/sys/fs/udf/udf_allocation.c:1.18.4.2	Thu Apr 23 02:22:25 2009
+++ src/sys/fs/udf/udf_allocation.c	Sat Jun  6 22:04:40 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: udf_allocation.c,v 1.18.4.2 2009/04/23 02:22:25 snj Exp $ */
+/* $NetBSD: udf_allocation.c,v 1.18.4.3 2009/06/06 22:04:40 bouyer Exp $ */
 
 /*
  * Copyright (c) 2006, 2008 Reinoud Zandijk
@@ -28,7 +28,7 @@
 
 #include 
 #ifndef lint
-__KERNEL_RCSID(0, "$NetBSD: udf_allocation.c,v 1.18.4.2 2009/04/23 02:22:25 snj Exp $");
+__KERNEL_RCSID(0, "$NetBSD: udf_allocation.c,v 1.18.4.3 2009/06/06 22:04:40 bouyer Exp $");
 #endif /* not lint */
 
 
@@ -1325,11 +1325,11 @@
 	if (fe) {
 		fe->l_ad = udf_rw32(0);
 		fe->logblks_rec  = udf_rw64(0);
-		fe->tag.desc_crc_len = udf_rw32(crclen);
+		fe->tag.desc_crc_len = udf_rw16(crclen);
 	} else {
 		efe->l_ad= udf_rw32(0);
 		efe->logblks_rec = udf_rw64(0);
-		efe->tag.desc_crc_len = udf_rw32(crclen);
+		efe->tag.desc_crc_len = udf_rw16(crclen);
 	}
 
 	/* wipe all allocation extent entries */
@@ -1342,7 +1342,7 @@
 		ext->l_ad = udf_rw32(0);
 
 		crclen = dscr_size - UDF_DESC_TAG_LENGTH;
-		ext->tag.desc_crc_len = udf_rw32(crclen);
+		ext->tag.desc_crc_len = udf_rw16(crclen);
 	}
 	udf_node->i_flags |= IN_NODE_REBUILD;
 }
@@ -1568,7 +1568,7 @@
 
 	/* offset is offset within the current (E)FE/AED */
 	l_ad   = udf_rw32(*l_ad_p);
-	crclen = udf_rw32(dscr->tag.desc_crc_len);
+	crclen = udf_rw16(dscr->tag.desc_crc_len);
 	logblks_rec = udf_rw64(*logblks_rec_p);
 
 	/* overwriting old piece? */
@@ -1630,7 +1630,7 @@
 			memset(ext->data, 0, max_l_ad);
 			ext->l_ad = udf_rw32(0);
 			ext->tag.desc_crc_len =
-udf_rw32(dscr_size - UDF_DESC_TAG_LENGTH);
+udf_rw16(dscr_size - UDF_DESC_TAG_LENGTH);
 
 			/* declare aed */
 			udf_node->num_extensions++;
@@ -1648,7 +1648,7 @@
 		}
 		l_ad   += adlen;
 		crclen += adlen;
-		dscr->tag.desc_crc_len = udf_rw32(crclen);
+		dscr->tag.desc_crc_len = udf_rw16(crclen);
 		*l_ad_p = udf_rw32(l_ad);
 
 		/* advance to the new extension */
@@ -1660,7 +1660,7 @@
 
 		l_ad_p = &ext->l_ad;
 

CVS commit: [netbsd-5] src/sys/fs/udf

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 22:00:23 UTC 2009

Modified Files:
src/sys/fs/udf [netbsd-5]: ecma167-udf.h

Log Message:
Pull up following revision(s) (requested by reinoud in ticket #769):
sys/fs/udf/ecma167-udf.h: revision 1.12
Make ecma167 header file compilable by pcc


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.11.4.1 src/sys/fs/udf/ecma167-udf.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/fs/udf/ecma167-udf.h
diff -u src/sys/fs/udf/ecma167-udf.h:1.11 src/sys/fs/udf/ecma167-udf.h:1.11.4.1
--- src/sys/fs/udf/ecma167-udf.h:1.11	Fri Jul 25 15:37:56 2008
+++ src/sys/fs/udf/ecma167-udf.h	Sat Jun  6 22:00:23 2009
@@ -1,7 +1,8 @@
-/* $NetBSD: ecma167-udf.h,v 1.11 2008/07/25 15:37:56 reinoud Exp $ */
+/* $NetBSD: ecma167-udf.h,v 1.11.4.1 2009/06/06 22:00:23 bouyer Exp $ */
 
 /*-
- * Copyright (c) 2003, 2004, 2005, 2006, 2008 Reinoud Zandijk
+ * Copyright (c) 2003, 2004, 2005, 2006, 2008, 2009
+ * 	Reinoud Zandijk * 
  * Copyright (c) 2001, 2002 Scott Long 
  * All rights reserved.
  *
@@ -59,7 +60,7 @@
 */
 
 #ifndef __packed
-#define __packed __packed
+#define __packed __attribute__((packed))
 #endif
 
 
@@ -178,7 +179,7 @@
 	union {
 		uint8_t	bytes[6];
 		struct UDF_ADImp_use im_used;
-	} __packed impl;
+	} impl;
 } __packed;
 #define longad_uniqueid impl.im_used.unique_id
 
@@ -198,7 +199,7 @@
 	struct short_ad	s_ad;
 	struct long_ad	l_ad;
 	struct ext_ad	e_ad;
-} __packed;
+};
 
 
 /* short/long/ext extent have flags encoded in length */
@@ -371,7 +372,7 @@
 	union {
 		struct udf_lv_info	lv_info;
 		char			impl_use[460];
-	} __packed _impl_use;
+	} _impl_use;
 } __packed;
 
 
@@ -386,7 +387,7 @@
 	union {
 		struct long_ad	fsd_loc;		/* to fileset descriptor SEQUENCE */
 		uint8_t		logvol_content_use[16];
-	} __packed _lvd_use;
+	} _lvd_use;
 	uint32_t		mt_l;			/* Partition map length */
 	uint32_t		n_pm;			/* Number of partition maps */
 	struct regid		imp_id;
@@ -477,7 +478,7 @@
 	struct part_map_virt	pmv;
 	struct part_map_spare	pms;
 	struct part_map_meta	pmm;
-} __packed;
+};
 
 
 /* Sparing Map Entry [UDF 2.01/2.2.11] */
@@ -607,7 +608,7 @@
 	union {
 		struct logvolhdr  logvolhdr;
 		int8_t		  reserved[32];
-	} __packed _impl_use;
+	} _impl_use;
 	uint32_t		num_part;
 	uint32_t		l_iu;
 	uint32_t		tables[1];	/* Freespace table, Sizetable, Implementation use */
@@ -827,7 +828,7 @@
 	struct udf_sparing_table spt;
 	struct space_bitmap_desc sbd;
 	struct space_entry_desc	 sed;
-} __packed;
+};
 
 
 #endif /* !_FS_UDF_ECMA167_UDF_H_ */



CVS commit: [netbsd-5] src/sbin/drvctl

2009-06-06 Thread Manuel Bouyer
Module Name:src
Committed By:   bouyer
Date:   Sat Jun  6 21:59:18 UTC 2009

Modified Files:
src/sbin/drvctl [netbsd-5]: drvctl.8 drvctl.c

Log Message:
Pull up following revision(s) (requested by dyoung in ticket #736):
sbin/drvctl/drvctl.8: revisions 1.7 - 1.10
sbin/drvctl/drvctl.c: revision 1.7 via patch, 1.9, 1.10
fix sign-compare issues
Add flag -n to suppress the first column of drvctl -l output.
Mention -n in usage.
Bump date for previous. Remove trailing whitespace.
Add -n to usage. Now it just needs to be documented.
Document -n.


To generate a diff of this commit:
cvs rdiff -u -r1.5.10.1 -r1.5.10.2 src/sbin/drvctl/drvctl.8
cvs rdiff -u -r1.6.10.1 -r1.6.10.2 src/sbin/drvctl/drvctl.c

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

Modified files:

Index: src/sbin/drvctl/drvctl.8
diff -u src/sbin/drvctl/drvctl.8:1.5.10.1 src/sbin/drvctl/drvctl.8:1.5.10.2
--- src/sbin/drvctl/drvctl.8:1.5.10.1	Sun May  3 22:49:51 2009
+++ src/sbin/drvctl/drvctl.8	Sat Jun  6 21:59:18 2009
@@ -1,4 +1,4 @@
-.\" $NetBSD: drvctl.8,v 1.5.10.1 2009/05/03 22:49:51 snj Exp $
+.\" $NetBSD: drvctl.8,v 1.5.10.2 2009/06/06 21:59:18 bouyer Exp $
 .\"
 .\" Copyright (c) 2004
 .\" 	Matthias Drochner.  All rights reserved.
@@ -24,7 +24,7 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.Dd April 4, 2009
+.Dd April 20, 2009
 .Dt DRVCTL 8
 .Os
 .Sh NAME
@@ -40,6 +40,7 @@
 .Fl d
 .Ar device
 .Nm
+.Op Fl n
 .Fl l
 .Op Ar device
 .Nm
@@ -80,7 +81,20 @@
 argument.
 If
 .Ar device
-is not specified, query for roots of the device tree instead.
+is not specified, list roots of the device tree instead.
+Output comes in two columns.
+The first column is
+.Ar device ,
+or
+.Dq root
+if
+.Ar device
+is not specified.
+The second column is the child.
+.It Fl n
+Suppress first column in
+.Fl l
+output.
 .It Fl p
 Get the properties for the device specified by the
 .Ar device

Index: src/sbin/drvctl/drvctl.c
diff -u src/sbin/drvctl/drvctl.c:1.6.10.1 src/sbin/drvctl/drvctl.c:1.6.10.2
--- src/sbin/drvctl/drvctl.c:1.6.10.1	Sun May  3 22:49:51 2009
+++ src/sbin/drvctl/drvctl.c	Sat Jun  6 21:59:18 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: drvctl.c,v 1.6.10.1 2009/05/03 22:49:51 snj Exp $ */
+/* $NetBSD: drvctl.c,v 1.6.10.2 2009/06/06 21:59:18 bouyer Exp $ */
 
 /*
  * Copyright (c) 2004
@@ -26,6 +26,7 @@
  * SUCH DAMAGE.
  */
 
+#include 
 #include 
 #include 
 #include 
@@ -35,7 +36,7 @@
 #include 
 #include 
 
-#define OPTS "QRSa:dlpr"
+#define OPTS "QRSa:dlnpr"
 
 #define	OPEN_MODE(mode)			\
 	(((mode) == 'd' || (mode) == 'r') ? O_RDWR			\
@@ -49,7 +50,7 @@
 
 	fprintf(stderr, "Usage: %s -r [-a attribute] busdevice [locator ...]\n"
 	"   %s -d device\n"
-	"   %s -l [device]\n"
+	"   %s [-n] -l [device]\n"
 	"   %s -p device\n"
 	"   %s -Q device\n"
 	"   %s -R device\n"
@@ -62,6 +63,7 @@
 int
 main(int argc, char **argv)
 {
+	bool nflag = false;
 	int c, mode;
 	char *attr = 0;
 	extern char *optarg;
@@ -95,6 +97,9 @@
 		case 'a':
 			attr = optarg;
 			break;
+		case 'n':
+			nflag = true;
+			break;
 		case '?':
 		default:
 			usage();
@@ -152,9 +157,12 @@
 		if (laa.l_children > children)
 			err(6, "DRVLISTDEV: number of children grew");
 
-		for (i = 0; i < laa.l_children; i++) {
-			printf("%s%s%s\n", laa.l_devname, (argc ? " " : ""),
-			laa.l_childname[i]);
+		for (i = 0; i < (int)laa.l_children; i++) {
+			if (!nflag) {
+printf("%s ",
+(argc == 0) ? "root" : laa.l_devname);
+			}
+			printf("%s\n", laa.l_childname[i]);
 		}
 		break;
 	case 'r':



CVS commit: src

2009-06-06 Thread Hubert Feyrer
Module Name:src
Committed By:   hubertf
Date:   Sat Jun  6 18:48:10 UTC 2009

Modified Files:
src/distrib/sets/lists/comp: mi
src/share/man/man9: Makefile

Log Message:
add mlinks for iic manpages


To generate a diff of this commit:
cvs rdiff -u -r1.1264 -r1.1265 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.282 -r1.283 src/share/man/man9/Makefile

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.1264 src/distrib/sets/lists/comp/mi:1.1265
--- src/distrib/sets/lists/comp/mi:1.1264	Tue May 26 21:58:31 2009
+++ src/distrib/sets/lists/comp/mi	Sat Jun  6 18:48:09 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: mi,v 1.1264 2009/05/26 21:58:31 pooka Exp $
+#	$NetBSD: mi,v 1.1265 2009/06/06 18:48:09 hubertf Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -8563,6 +8563,12 @@
 ./usr/share/man/cat9/ieee80211_setmode.0	comp-sys-catman		.cat
 ./usr/share/man/cat9/ieee80211_watchdog.0	comp-sys-catman		.cat
 ./usr/share/man/cat9/iic.0			comp-sys-catman		.cat
+./usr/share/man/cat9/iic_acquire_bus.0		comp-sys-catman		.cat
+./usr/share/man/cat9/iic_exec.0			comp-sys-catman		.cat
+./usr/share/man/cat9/iic_release_bus.0		comp-sys-catman		.cat
+./usr/share/man/cat9/iic_smbus_read_byte.0	comp-sys-catman		.cat
+./usr/share/man/cat9/iic_smbus_receive_byte.0	comp-sys-catman		.cat
+./usr/share/man/cat9/iic_smbus_write_byte.0	comp-sys-catman		.cat
 ./usr/share/man/cat9/imax.0			comp-sys-catman		.cat
 ./usr/share/man/cat9/imin.0			comp-sys-catman		.cat
 ./usr/share/man/cat9/in4_cksum.0		comp-sys-catman		.cat
@@ -13896,6 +13902,12 @@
 ./usr/share/man/html9/ieee80211_setmode.html	comp-sys-htmlman	html
 ./usr/share/man/html9/ieee80211_watchdog.html	comp-sys-htmlman	html
 ./usr/share/man/html9/iic.html			comp-sys-htmlman	html
+./usr/share/man/html9/iic_acquire_bus.html	comp-sys-htmlman	html
+./usr/share/man/html9/iic_exec.html		comp-sys-htmlman	html
+./usr/share/man/html9/iic_release_bus.html	comp-sys-htmlman	html
+./usr/share/man/html9/iic_smbus_read_byte.html	comp-sys-htmlman	html
+./usr/share/man/html9/iic_smbus_receive_byte.html	comp-sys-htmlman	html
+./usr/share/man/html9/iic_smbus_write_byte.html	comp-sys-htmlman	html
 ./usr/share/man/html9/imax.html			comp-sys-htmlman	html
 ./usr/share/man/html9/imin.html			comp-sys-htmlman	html
 ./usr/share/man/html9/in4_cksum.html		comp-sys-htmlman	html
@@ -19384,6 +19396,12 @@
 ./usr/share/man/man9/ieee80211_setmode.9	comp-sys-man		.man
 ./usr/share/man/man9/ieee80211_watchdog.9	comp-sys-man		.man
 ./usr/share/man/man9/iic.9			comp-sys-man		.man
+./usr/share/man/man9/iic_acquire_bus.9		comp-sys-man		.man
+./usr/share/man/man9/iic_exec.9			comp-sys-man		.man
+./usr/share/man/man9/iic_release_bus.9		comp-sys-man		.man
+./usr/share/man/man9/iic_smbus_read_byte.9	comp-sys-man		.man
+./usr/share/man/man9/iic_smbus_receive_byte.9	comp-sys-man		.man
+./usr/share/man/man9/iic_smbus_write_byte.9	comp-sys-man		.man
 ./usr/share/man/man9/imax.9			comp-sys-man		.man
 ./usr/share/man/man9/imin.9			comp-sys-man		.man
 ./usr/share/man/man9/in4_cksum.9		comp-sys-man		.man

Index: src/share/man/man9/Makefile
diff -u src/share/man/man9/Makefile:1.282 src/share/man/man9/Makefile:1.283
--- src/share/man/man9/Makefile:1.282	Wed May 20 22:48:05 2009
+++ src/share/man/man9/Makefile	Sat Jun  6 18:48:10 2009
@@ -1,4 +1,4 @@
-#   $NetBSD: Makefile,v 1.282 2009/05/20 22:48:05 dyoung Exp $
+#   $NetBSD: Makefile,v 1.283 2009/06/06 18:48:10 hubertf Exp $
 
 #	Makefile for section 9 (kernel function and variable) manual pages.
 
@@ -293,6 +293,12 @@
 	ieee80211.9 ieee80211_rate2media.9 \
 	ieee80211.9 ieee80211_setmode.9 \
 	ieee80211.9 ieee80211_watchdog.9
+MLINKS+=iic.9 iic_acquire_bus.9 \
+	iic.9 iic_release_bus.9 \
+	iic.9 iic_exec.9 \
+	iic.9 iic_smbus_write_byte.9 \
+	iic.9 iic_smbus_read_byte.9 \
+	iic.9 iic_smbus_receive_byte.9
 MLINKS+=imax.9 imin.9
 MLINKS+=in4_cksum.9 in_cksum.9 \
 	in4_cksum.9 in6_cksum.9



CVS commit: src/sbin/fsck

2009-06-06 Thread Adam Hamsik
Module Name:src
Committed By:   haad
Date:   Sat Jun  6 18:31:29 UTC 2009

Modified Files:
src/sbin/fsck: partutil.c

Log Message:
Add support for devices which do not support DIOCGDISKINFO ioctl yet. This
change  will restore fsck/newfs on vnd device.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sbin/fsck/partutil.c

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

Modified files:

Index: src/sbin/fsck/partutil.c
diff -u src/sbin/fsck/partutil.c:1.6 src/sbin/fsck/partutil.c:1.7
--- src/sbin/fsck/partutil.c:1.6	Sat Jun  6 17:47:50 2009
+++ src/sbin/fsck/partutil.c	Sat Jun  6 18:31:29 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: partutil.c,v 1.6 2009/06/06 17:47:50 haad Exp $	*/
+/*	$NetBSD: partutil.c,v 1.7 2009/06/06 18:31:29 haad Exp $	*/
 
 /*-
  * Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__RCSID("$NetBSD: partutil.c,v 1.6 2009/06/06 17:47:50 haad Exp $");
+__RCSID("$NetBSD: partutil.c,v 1.7 2009/06/06 18:31:29 haad Exp $");
 
 #include 
 #include 
@@ -52,6 +52,23 @@
 
 #include "partutil.h"
 
+/*
+ * Convert disklabel geometry info to disk_geom.
+ */
+static void
+label2geom(struct disk_geom *geo, const struct disklabel *lp)
+{
+	geo->dg_secperunit = lp->d_secperunit;
+	geo->dg_secsize = lp->d_secsize;
+	geo->dg_nsectors = lp->d_nsectors;
+	geo->dg_ntracks = lp->d_ntracks;
+	geo->dg_ncylinders = lp->d_ncylinders;
+	geo->dg_secpercyl = lp->d_secpercyl;
+	geo->dg_pcylinders = lp->d_ncylinders;
+	geo->dg_sparespertrack = lp->d_sparespertrack;
+	geo->dg_sparespercyl = lp->d_sparespercyl;
+	geo->dg_acylinders = lp->d_acylinders;
+}
 
 /*
  * Set what we need to know about disk geometry.
@@ -138,7 +155,10 @@
 	struct disklabel lab;
 	struct disklabel *lp = &lab;
 	prop_dictionary_t disk_dict, geom_dict;
+	int error;
 
+	error = 0;
+	
 	if (dt) {
 		lp = getdiskbyname(dt);
 		if (lp == NULL)
@@ -146,18 +166,30 @@
 	}
 
 	/* Get disk description dictionary */
-	if (prop_dictionary_recv_ioctl(fd, DIOCGDISKINFO, &disk_dict) != 0) {
-		warn("Please implement DIOCGDISKINFO for %s\n disk driver\n", s);
-		return (errno);
+	if ((error = prop_dictionary_recv_ioctl(fd, DIOCGDISKINFO,
+		&disk_dict)) != 0) {
+		warn("Please implement DIOCGDISKINFO for %s disk driver\n", s);
+		
+		/*
+		 * Ask for disklabel if DIOCGDISKINFO failed. This is
+		 * compatibility call and can be removed when all devices
+		 * will support DIOCGDISKINFO.
+		 */
+		if ((error = ioctl(fd, DIOCGDINFO, lp)) == -1) {
+			printf("DIOCGDINFO on %s failed\n", s);
+			return (errno);
+		}
+		label2geom(geo, lp);
+	} else {
+		geom_dict = prop_dictionary_get(disk_dict, "geometry");
+		dict2geom(geo, geom_dict);
 	}
 	
-	geom_dict = prop_dictionary_get(disk_dict, "geometry");
-	dict2geom(geo, geom_dict);
-
 	/* Get info about partition/wedge */
 	if (ioctl(fd, DIOCGWEDGEINFO, dkw) == -1) {
 		if (ioctl(fd, DIOCGDINFO, lp) == -1)
-			errx(errno, "Please implement DIOCGWEDGEINFO or DIOCGDINFO for disk device %s\n", s);
+			errx(errno, "Please implement DIOCGWEDGEINFO or "
+			"DIOCGDINFO for disk device %s\n", s);
 
 		part2wedge(dkw, lp, s);
 	}



CVS commit: src/sbin/fsck

2009-06-06 Thread Adam Hamsik
Module Name:src
Committed By:   haad
Date:   Sat Jun  6 17:47:51 UTC 2009

Modified Files:
src/sbin/fsck: partutil.c

Log Message:
Remove debug printfs.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/sbin/fsck/partutil.c

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

Modified files:

Index: src/sbin/fsck/partutil.c
diff -u src/sbin/fsck/partutil.c:1.5 src/sbin/fsck/partutil.c:1.6
--- src/sbin/fsck/partutil.c:1.5	Fri Jun  5 21:52:31 2009
+++ src/sbin/fsck/partutil.c	Sat Jun  6 17:47:50 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: partutil.c,v 1.5 2009/06/05 21:52:31 haad Exp $	*/
+/*	$NetBSD: partutil.c,v 1.6 2009/06/06 17:47:50 haad Exp $	*/
 
 /*-
  * Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__RCSID("$NetBSD: partutil.c,v 1.5 2009/06/05 21:52:31 haad Exp $");
+__RCSID("$NetBSD: partutil.c,v 1.6 2009/06/06 17:47:50 haad Exp $");
 
 #include 
 #include 
@@ -156,8 +156,6 @@
 
 	/* Get info about partition/wedge */
 	if (ioctl(fd, DIOCGWEDGEINFO, dkw) == -1) {
-		warn("ioctl (DIOCGWEDGEINFO)");
-		printf("Using old disklabel method\n");
 		if (ioctl(fd, DIOCGDINFO, lp) == -1)
 			errx(errno, "Please implement DIOCGWEDGEINFO or DIOCGDINFO for disk device %s\n", s);
 



CVS commit: src/sys/dev/pci

2009-06-06 Thread Christoph Egger
Module Name:src
Committed By:   cegger
Date:   Sat Jun  6 12:56:43 UTC 2009

Modified Files:
src/sys/dev/pci: pciio.h

Log Message:
typo in comment: autconfiguration -> autoconfiguration


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

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

Modified files:

Index: src/sys/dev/pci/pciio.h
diff -u src/sys/dev/pci/pciio.h:1.2 src/sys/dev/pci/pciio.h:1.3
--- src/sys/dev/pci/pciio.h:1.2	Fri Sep 14 06:09:42 2001
+++ src/sys/dev/pci/pciio.h	Sat Jun  6 12:56:43 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: pciio.h,v 1.2 2001/09/14 06:09:42 simonb Exp $	*/
+/*	$NetBSD: pciio.h,v 1.3 2009/06/06 12:56:43 cegger Exp $	*/
 
 /*
  * Copyright 2001 Wasabi Systems, Inc.
@@ -84,7 +84,7 @@
 /*
  * pciio_businfo:
  *
- *	Information for a PCI bus (autconfiguration node) instance.
+ *	Information for a PCI bus (autoconfiguration node) instance.
  */
 struct pciio_businfo {
 	u_int	busno;		/* bus number */



CVS commit: src/sbin/newfs

2009-06-06 Thread Adam Hamsik
Module Name:src
Committed By:   haad
Date:   Sat Jun  6 11:09:16 UTC 2009

Modified Files:
src/sbin/newfs: Makefile

Log Message:
Remove debuging CFLAGS.


To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 src/sbin/newfs/Makefile

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

Modified files:

Index: src/sbin/newfs/Makefile
diff -u src/sbin/newfs/Makefile:1.33 src/sbin/newfs/Makefile:1.34
--- src/sbin/newfs/Makefile:1.33	Fri Jun  5 21:52:31 2009
+++ src/sbin/newfs/Makefile	Sat Jun  6 11:09:16 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.33 2009/06/05 21:52:31 haad Exp $
+#	$NetBSD: Makefile,v 1.34 2009/06/06 11:09:16 haad Exp $
 #	@(#)Makefile	8.2 (Berkeley) 3/27/94
 
 .include 
@@ -11,8 +11,6 @@
 FSCK=${NETBSDSRCDIR}/sbin/fsck
 CPPFLAGS+=-DMFS -I${.CURDIR} -I${DISKLABEL} -I${FSCK}
 
-CFLAGS+= -g -O0
-
 DPADD+= ${LIBUTIL}
 LDADD+= -lutil
 



CVS commit: src/bin/df

2009-06-06 Thread Michael van Elst
Module Name:src
Committed By:   mlelstv
Date:   Sat Jun  6 09:30:45 UTC 2009

Modified Files:
src/bin/df: df.c

Log Message:
block numbers are measured in f_frsize units. Make -P option
use this instead of f_bsize. Also account for reserved blocks
like normal non-P output.
Fixes PR bin/41541.


To generate a diff of this commit:
cvs rdiff -u -r1.85 -r1.86 src/bin/df/df.c

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

Modified files:

Index: src/bin/df/df.c
diff -u src/bin/df/df.c:1.85 src/bin/df/df.c:1.86
--- src/bin/df/df.c:1.85	Sun Jan 25 14:18:21 2009
+++ src/bin/df/df.c	Sat Jun  6 09:30:45 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: df.c,v 1.85 2009/01/25 14:18:21 lukem Exp $ */
+/*	$NetBSD: df.c,v 1.86 2009/06/06 09:30:45 mlelstv Exp $ */
 
 /*
  * Copyright (c) 1980, 1990, 1993, 1994
@@ -45,7 +45,7 @@
 #if 0
 static char sccsid[] = "@(#)df.c	8.7 (Berkeley) 4/2/94";
 #else
-__RCSID("$NetBSD: df.c,v 1.85 2009/01/25 14:18:21 lukem Exp $");
+__RCSID("$NetBSD: df.c,v 1.86 2009/06/06 09:30:45 mlelstv Exp $");
 #endif
 #endif /* not lint */
 
@@ -473,9 +473,9 @@
 		 */
 		(void)printf("%s %" PRId64 " %" PRId64 " %" PRId64 " %s %s\n",
 		sfsp->f_mntfromname,
-		fsbtoblk(sfsp->f_blocks, sfsp->f_bsize, blocksize),
-		fsbtoblk(used, sfsp->f_bsize, blocksize),
-		fsbtoblk(sfsp->f_bavail, sfsp->f_bsize, blocksize),
+		fsbtoblk(sfsp->f_blocks, sfsp->f_frsize, blocksize),
+		fsbtoblk(used, sfsp->f_frsize, blocksize),
+		fsbtoblk(bavail, sfsp->f_frsize, blocksize),
 		availblks == 0 ? full : strpct64((uint64_t) used,
 		(uint64_t) availblks, 0), sfsp->f_mntonname);
 		/*



CVS commit: src/sbin/atactl

2009-06-06 Thread Michael van Elst
Module Name:src
Committed By:   mlelstv
Date:   Sat Jun  6 09:18:55 UTC 2009

Modified Files:
src/sbin/atactl: atactl.c

Log Message:
make space for a trailing \0 in model,revision and serial buffers.


To generate a diff of this commit:
cvs rdiff -u -r1.53 -r1.54 src/sbin/atactl/atactl.c

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

Modified files:

Index: src/sbin/atactl/atactl.c
diff -u src/sbin/atactl/atactl.c:1.53 src/sbin/atactl/atactl.c:1.54
--- src/sbin/atactl/atactl.c:1.53	Mon Mar 16 12:52:32 2009
+++ src/sbin/atactl/atactl.c	Sat Jun  6 09:18:55 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: atactl.c,v 1.53 2009/03/16 12:52:32 lukem Exp $	*/
+/*	$NetBSD: atactl.c,v 1.54 2009/06/06 09:18:55 mlelstv Exp $	*/
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
 #include 
 
 #ifndef lint
-__RCSID("$NetBSD: atactl.c,v 1.53 2009/03/16 12:52:32 lukem Exp $");
+__RCSID("$NetBSD: atactl.c,v 1.54 2009/06/06 09:18:55 mlelstv Exp $");
 #endif
 
 
@@ -856,9 +856,9 @@
 device_identify(int argc, char *argv[])
 {
 	struct ataparams *inqbuf;
-	char model[sizeof(inqbuf->atap_model)];
-	char revision[sizeof(inqbuf->atap_revision)];
-	char serial[sizeof(inqbuf->atap_serial)];
+	char model[sizeof(inqbuf->atap_model)+1];
+	char revision[sizeof(inqbuf->atap_revision)+1];
+	char serial[sizeof(inqbuf->atap_serial)+1];
 	int needswap = 0;
 
 	/* No arguments. */



CVS commit: src/sbin/fsdb

2009-06-06 Thread Adam Hamsik
Module Name:src
Committed By:   haad
Date:   Sat Jun  6 08:22:24 UTC 2009

Modified Files:
src/sbin/fsdb: Makefile

Log Message:
Add proplib to list of libraries, ifx fsdb build after my getdiskinfo change.


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sbin/fsdb/Makefile

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

Modified files:

Index: src/sbin/fsdb/Makefile
diff -u src/sbin/fsdb/Makefile:1.25 src/sbin/fsdb/Makefile:1.26
--- src/sbin/fsdb/Makefile:1.25	Sat Apr 11 07:58:12 2009
+++ src/sbin/fsdb/Makefile	Sat Jun  6 08:22:24 2009
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.25 2009/04/11 07:58:12 lukem Exp $
+#	$NetBSD: Makefile,v 1.26 2009/06/06 08:22:24 haad Exp $
 #	@(#)Makefile	8.1 (Berkeley) 6/5/93
 
 WARNS?=	3	# XXX: sign-compare issues in ../fsck_ffs
@@ -22,9 +22,9 @@
 .PATH:	${NETBSDSRCDIR}/sys/kern
 CPPFLAGS+=-DWAPBL_DEBUG_PRINT=0
 
-LDADD+= -lutil -ledit -ltermcap
+LDADD+= -lutil -ledit -ltermcap -lprop
 .ifndef HOSTPROG
-DPADD+= ${LIBUTIL} ${LIBEDIT} ${LIBTERMCAP}
+DPADD+= ${LIBUTIL} ${LIBEDIT} ${LIBTERMCAP} ${LIBPROP}
 .endif
 
 .if (defined(HAVE_GCC) && ${HAVE_GCC} == 4) || defined(HAVE_PCC)



CVS commit: src/sys/dev/raidframe

2009-06-06 Thread Adam Hamsik
Module Name:src
Committed By:   haad
Date:   Sat Jun  6 08:10:06 UTC 2009

Modified Files:
src/sys/dev/raidframe: rf_netbsdkintf.c

Log Message:
Fix my previous commit.


To generate a diff of this commit:
cvs rdiff -u -r1.263 -r1.264 src/sys/dev/raidframe/rf_netbsdkintf.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/raidframe/rf_netbsdkintf.c
diff -u src/sys/dev/raidframe/rf_netbsdkintf.c:1.263 src/sys/dev/raidframe/rf_netbsdkintf.c:1.264
--- src/sys/dev/raidframe/rf_netbsdkintf.c:1.263	Fri Jun  5 21:52:32 2009
+++ src/sys/dev/raidframe/rf_netbsdkintf.c	Sat Jun  6 08:10:06 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: rf_netbsdkintf.c,v 1.263 2009/06/05 21:52:32 haad Exp $	*/
+/*	$NetBSD: rf_netbsdkintf.c,v 1.264 2009/06/06 08:10:06 haad Exp $	*/
 /*-
  * Copyright (c) 1996, 1997, 1998, 2008 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -139,7 +139,7 @@
  ***/
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.263 2009/06/05 21:52:32 haad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.264 2009/06/06 08:10:06 haad Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_compat_netbsd.h"
@@ -1732,7 +1732,7 @@
 	 * Add support for "regular" device ioctls here.
 	 */
 	
-	error = disk_ioctl(&rs->sc_dkdev, cmd, addr, flag, l); 
+	error = disk_ioctl(&rs->sc_dkdev, cmd, data, flag, l); 
 	if (error != EPASSTHROUGH)
 		return (error);
 



CVS commit: othersrc/usr.bin/tnftp

2009-06-06 Thread Luke Mewburn
Module Name:othersrc
Committed By:   lukem
Date:   Sat Jun  6 07:20:37 UTC 2009

Modified Files:
othersrc/usr.bin/tnftp: configure

Log Message:
regen for 20090606


To generate a diff of this commit:
cvs rdiff -u -r1.32 -r1.33 othersrc/usr.bin/tnftp/configure

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

Modified files:

Index: othersrc/usr.bin/tnftp/configure
diff -u othersrc/usr.bin/tnftp/configure:1.32 othersrc/usr.bin/tnftp/configure:1.33
--- othersrc/usr.bin/tnftp/configure:1.32	Fri May 29 09:12:00 2009
+++ othersrc/usr.bin/tnftp/configure	Sat Jun  6 07:20:37 2009
@@ -1,7 +1,7 @@
 #! /bin/sh
-# From configure.ac Revision: 1.18 .
+# From configure.ac Revision: 1.19 .
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.63 for tnftp 20090520.
+# Generated by GNU Autoconf 2.63 for tnftp 20090606.
 #
 # Report bugs to .
 #
@@ -597,8 +597,8 @@
 # Identity of this package.
 PACKAGE_NAME='tnftp'
 PACKAGE_TARNAME='tnftp'
-PACKAGE_VERSION='20090520'
-PACKAGE_STRING='tnftp 20090520'
+PACKAGE_VERSION='20090606'
+PACKAGE_STRING='tnftp 20090606'
 PACKAGE_BUGREPORT='lu...@netbsd.org'
 
 ac_unique_file="tnftp.h"
@@ -1280,7 +1280,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures tnftp 20090520 to adapt to many kinds of systems.
+\`configure' configures tnftp 20090606 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1351,7 +1351,7 @@
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
- short | recursive ) echo "Configuration of tnftp 20090520:";;
+ short | recursive ) echo "Configuration of tnftp 20090606:";;
esac
   cat <<\_ACEOF
 
@@ -1447,7 +1447,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-tnftp configure 20090520
+tnftp configure 20090606
 generated by GNU Autoconf 2.63
 
 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1461,7 +1461,7 @@
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by tnftp $as_me 20090520, which was
+It was created by tnftp $as_me 20090606, which was
 generated by GNU Autoconf 2.63.  Invocation command line was
 
   $ $0 $@
@@ -10863,7 +10863,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by tnftp $as_me 20090520, which was
+This file was extended by tnftp $as_me 20090606, which was
 generated by GNU Autoconf 2.63.  Invocation command line was
 
   CONFIG_FILES= $CONFIG_FILES
@@ -10922,7 +10922,7 @@
 _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_version="\\
-tnftp config.status 20090520
+tnftp config.status 20090606
 configured by $0, generated by GNU Autoconf 2.63,
   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/&/g'`\\"
 



CVS commit: othersrc/usr.bin/tnftp

2009-06-06 Thread Luke Mewburn
Module Name:othersrc
Committed By:   lukem
Date:   Sat Jun  6 07:19:33 UTC 2009

Modified Files:
othersrc/usr.bin/tnftp: ChangeLog NEWS configure.ac

Log Message:
Release tnftp 20090606


To generate a diff of this commit:
cvs rdiff -u -r1.51 -r1.52 othersrc/usr.bin/tnftp/ChangeLog
cvs rdiff -u -r1.5 -r1.6 othersrc/usr.bin/tnftp/NEWS
cvs rdiff -u -r1.18 -r1.19 othersrc/usr.bin/tnftp/configure.ac

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

Modified files:

Index: othersrc/usr.bin/tnftp/ChangeLog
diff -u othersrc/usr.bin/tnftp/ChangeLog:1.51 othersrc/usr.bin/tnftp/ChangeLog:1.52
--- othersrc/usr.bin/tnftp/ChangeLog:1.51	Fri May 22 01:14:46 2009
+++ othersrc/usr.bin/tnftp/ChangeLog	Sat Jun  6 07:19:33 2009
@@ -1,4 +1,8 @@
-$NetBSD: ChangeLog,v 1.51 2009/05/22 01:14:46 lukem Exp $
+$NetBSD: ChangeLog,v 1.52 2009/06/06 07:19:33 lukem Exp $
+
+Sat Jun  6 07:17:38 UTC 2009	lukem
+
+	* Release as "tnftp 20090606"
 
 Fri May 22 01:11:15 UTC 2009	lukem
 

Index: othersrc/usr.bin/tnftp/NEWS
diff -u othersrc/usr.bin/tnftp/NEWS:1.5 othersrc/usr.bin/tnftp/NEWS:1.6
--- othersrc/usr.bin/tnftp/NEWS:1.5	Fri May 22 00:06:11 2009
+++ othersrc/usr.bin/tnftp/NEWS	Sat Jun  6 07:19:33 2009
@@ -1,5 +1,9 @@
 This is tnftp version 20090520.
 
+Changes in tnftp from 20090520 to 20090606:
+
+	Portability fixes.
+
 Changes in tnftp from 20070806 to 20090520:
 
 	Fix intermittent "Alarm clock" error.

Index: othersrc/usr.bin/tnftp/configure.ac
diff -u othersrc/usr.bin/tnftp/configure.ac:1.18 othersrc/usr.bin/tnftp/configure.ac:1.19
--- othersrc/usr.bin/tnftp/configure.ac:1.18	Fri May 22 01:09:45 2009
+++ othersrc/usr.bin/tnftp/configure.ac	Sat Jun  6 07:19:33 2009
@@ -1,10 +1,10 @@
-#   $NetBSD: configure.ac,v 1.18 2009/05/22 01:09:45 lukem Exp $
+#   $NetBSD: configure.ac,v 1.19 2009/06/06 07:19:33 lukem Exp $
 #
 # Process this file with autoconf to produce a configure script.
 
-AC_INIT([tnftp], [20090520], [lu...@netbsd.org])
+AC_INIT([tnftp], [20090606], [lu...@netbsd.org])
 AC_PREREQ([2.61])
-AC_REVISION([$Revision: 1.18 $])
+AC_REVISION([$Revision: 1.19 $])
 
 AS_SHELL_SANITIZE