CVS commit: src/tools/compat/sys

2010-03-26 Thread Christoph Egger
Module Name:src
Committed By:   cegger
Date:   Fri Mar 26 07:16:12 UTC 2010

Added Files:
src/tools/compat/sys: time.h

Log Message:
toolchain buildfix on OSX with MKDTRACE=yes:

The host sys/time.h doesn't provide CLOCK_REALTIME but ctf uses it.
See http://mail-index.netbsd.org/current-users/2010/03/20/msg012963.html

No comments.


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/tools/compat/sys/time.h

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

Added files:

Index: src/tools/compat/sys/time.h
diff -u /dev/null src/tools/compat/sys/time.h:1.1
--- /dev/null	Fri Mar 26 07:16:12 2010
+++ src/tools/compat/sys/time.h	Fri Mar 26 07:16:12 2010
@@ -0,0 +1,11 @@
+/*	$NetBSD: time.h,v 1.1 2010/03/26 07:16:12 cegger Exp $	*/
+
+#if (defined(__APPLE__)  defined(__MACH__))  !defined(__darwin__)
+# define __darwin__ 1
+#endif
+
+#ifdef __darwin__
+#define CLOCK_REALTIME	0	/* XXX Keep this in sync with our sys/time.h */
+#endif
+
+#include_next sys/time.h



CVS commit: src/sys/dev/sysmon

2010-03-26 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Fri Mar 26 12:37:00 UTC 2010

Modified Files:
src/sys/dev/sysmon: sysmon_envsys.c

Log Message:
Export the sensor device's class.


To generate a diff of this commit:
cvs rdiff -u -r1.98 -r1.99 src/sys/dev/sysmon/sysmon_envsys.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/sysmon/sysmon_envsys.c
diff -u src/sys/dev/sysmon/sysmon_envsys.c:1.98 src/sys/dev/sysmon/sysmon_envsys.c:1.99
--- src/sys/dev/sysmon/sysmon_envsys.c:1.98	Wed Mar 24 12:15:54 2010
+++ src/sys/dev/sysmon/sysmon_envsys.c	Fri Mar 26 12:36:59 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: sysmon_envsys.c,v 1.98 2010/03/24 12:15:54 pgoyette Exp $	*/
+/*	$NetBSD: sysmon_envsys.c,v 1.99 2010/03/26 12:36:59 pgoyette Exp $	*/
 
 /*-
  * Copyright (c) 2007, 2008 Juan Romero Pardines.
@@ -64,7 +64,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: sysmon_envsys.c,v 1.98 2010/03/24 12:15:54 pgoyette Exp $);
+__KERNEL_RCSID(0, $NetBSD: sysmon_envsys.c,v 1.99 2010/03/26 12:36:59 pgoyette Exp $);
 
 #include sys/param.h
 #include sys/types.h
@@ -1141,6 +1141,7 @@
 			prop_dictionary_t dict)
 {
 	prop_dictionary_t pdict;
+	const char *class;
 	int error = 0;
 
 	pdict = prop_dictionary_create();
@@ -1148,8 +1149,8 @@
 		return EINVAL;
 
 	/*
-	 * Add the 'refresh-timeout' object into the 'device-properties'
-	 * dictionary. We use by default 30 seconds.
+	 * Add the 'refresh-timeout' and 'dev-class' objects into the
+	 * 'device-properties' dictionary.
 	 *
 	 * 	...
 	 * 	dict
@@ -1157,7 +1158,9 @@
 	 * 		dict
 	 * 			keyrefresh-timeout/key
 	 * 			integer120/integer
-	 * 		/dict
+	 *			keydevice-class/key
+	 *			stringclass_name/string
+	 * 		/dict
 	 * 	/dict
 	 * 	...
 	 *
@@ -1170,6 +1173,16 @@
 		error = EINVAL;
 		goto out;
 	}
+	if (sme-sme_class == SME_CLASS_BATTERY)
+		class = battery;
+	else if (sme-sme_class == SME_CLASS_ACADAPTER)
+		class = ac-adapter;
+	else
+		class = other;
+	if (!prop_dictionary_set_cstring_nocopy(pdict, device-class, class)) {
+		error = EINVAL;
+		goto out;
+	}
 
 	if (!prop_dictionary_set(dict, device-properties, pdict)) {
 		error = EINVAL;



CVS commit: src/sys/dev/dm

2010-03-26 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Mar 26 15:46:05 UTC 2010

Modified Files:
src/sys/dev/dm: device-mapper.c

Log Message:
Fix build of i386 ALL kernel with patch from Greg A. Woods in PR/43056.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/dev/dm/device-mapper.c

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

Modified files:

Index: src/sys/dev/dm/device-mapper.c
diff -u src/sys/dev/dm/device-mapper.c:1.21 src/sys/dev/dm/device-mapper.c:1.22
--- src/sys/dev/dm/device-mapper.c:1.21	Tue Mar 23 15:09:45 2010
+++ src/sys/dev/dm/device-mapper.c	Fri Mar 26 15:46:04 2010
@@ -1,4 +1,4 @@
-/*$NetBSD: device-mapper.c,v 1.21 2010/03/23 15:09:45 jakllsch Exp $ */
+/*$NetBSD: device-mapper.c,v 1.22 2010/03/26 15:46:04 jakllsch Exp $ */
 
 /*
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -59,7 +59,9 @@
 
 /* attach and detach routines */
 void dmattach(int);
+#ifdef _MODULE
 static int dmdestroy(void);
+#endif
 
 static void dm_doinit(void);
 
@@ -297,6 +299,7 @@
 	}
 }
 
+#ifdef _MODULE
 /* Destroy routine */
 static int
 dmdestroy(void)
@@ -313,6 +316,7 @@
 
 	return 0;
 }
+#endif /* _MODULE */
 
 static int
 dmopen(dev_t dev, int flags, int mode, struct lwp *l)



CVS commit: src/usr.bin/config

2010-03-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Mar 26 15:51:17 UTC 2010

Modified Files:
src/usr.bin/config: mkioconf.c

Log Message:
Put cfdata* in a similar namespace with cfdriver** cfattachinit*.
This was nagging me already yesterday, but I decided to leave it
alone for better compat with old ioconf.c builds.  But as it turns
out, new code depends on newly built ioconf.c with a new config(1)
anyway, so renaming is not an issue (at least not at this stage).

While renaming, namespace cfdriver and cfattach in ioconf rather
than comp, since the former reflects the config(5) keyword.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/usr.bin/config/mkioconf.c

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

Modified files:

Index: src/usr.bin/config/mkioconf.c
diff -u src/usr.bin/config/mkioconf.c:1.17 src/usr.bin/config/mkioconf.c:1.18
--- src/usr.bin/config/mkioconf.c:1.17	Thu Mar 25 19:39:05 2010
+++ src/usr.bin/config/mkioconf.c	Fri Mar 26 15:51:17 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: mkioconf.c,v 1.17 2010/03/25 19:39:05 pooka Exp $	*/
+/*	$NetBSD: mkioconf.c,v 1.18 2010/03/26 15:51:17 pooka Exp $	*/
 
 /*
  * Copyright (c) 1992, 1993
@@ -240,7 +240,7 @@
 	fprintf(fp,
 	%sstruct cfdriver * const cfdriver_%s_%s[] = {\n,
 	ioconfname ? static  : ,
-	ioconfname ? comp : list,
+	ioconfname ? ioconf : list,
 	ioconfname ? ioconfname : initial);
 
 	TAILQ_FOREACH(d, allbases, d_next) {
@@ -292,7 +292,7 @@
 	NEWLINE;
 	fprintf(fp, %sconst struct cfattachinit cfattach%s%s[] = {\n,
 	ioconfname ? static  : ,
-	ioconfname ? _comp_ : init,
+	ioconfname ? _ioconf_ : init,
 	ioconfname ? ioconfname : );
 
 	TAILQ_FOREACH(d, allbases, d_next) {
@@ -377,7 +377,7 @@
 		/* driver   attachmentunit state 
 		loc   flags pspec */\n,
 		ioconfname ? static  : ,
-		ioconfname ? _ : ,
+		ioconfname ? _ioconf_ : ,
 		ioconfname ? ioconfname : );
 	for (p = packed; (i = *p) != NULL; p++) {
 		/* the description */



CVS commit: src/sys

2010-03-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Mar 26 15:51:55 UTC 2010

Modified Files:
src/sys/dev/acpi: acpi_bat.c
src/sys/rump/dev/lib/libubt: ubt_at_usb.c
src/sys/rump/dev/lib/libucom: ucom_at_usb.c
src/sys/rump/dev/lib/libugenhc: ugenhc_at_mainbus.c
src/sys/rump/dev/lib/libulpt: ulpt_at_usb.c
src/sys/rump/dev/lib/libumass: sd_at_scsibus_at_umass.c
src/sys/rump/dev/lib/libusb: usb_at_ugenhc.c
src/sys/rump/dev/lib/libwscons: component.c

Log Message:
Catch up with cosmetic changes to output from config(1)


To generate a diff of this commit:
cvs rdiff -u -r1.96 -r1.97 src/sys/dev/acpi/acpi_bat.c
cvs rdiff -u -r1.3 -r1.4 src/sys/rump/dev/lib/libubt/ubt_at_usb.c
cvs rdiff -u -r1.6 -r1.7 src/sys/rump/dev/lib/libucom/ucom_at_usb.c
cvs rdiff -u -r1.2 -r1.3 src/sys/rump/dev/lib/libugenhc/ugenhc_at_mainbus.c
cvs rdiff -u -r1.4 -r1.5 src/sys/rump/dev/lib/libulpt/ulpt_at_usb.c
cvs rdiff -u -r1.4 -r1.5 \
src/sys/rump/dev/lib/libumass/sd_at_scsibus_at_umass.c
cvs rdiff -u -r1.2 -r1.3 src/sys/rump/dev/lib/libusb/usb_at_ugenhc.c
cvs rdiff -u -r1.4 -r1.5 src/sys/rump/dev/lib/libwscons/component.c

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

Modified files:

Index: src/sys/dev/acpi/acpi_bat.c
diff -u src/sys/dev/acpi/acpi_bat.c:1.96 src/sys/dev/acpi/acpi_bat.c:1.97
--- src/sys/dev/acpi/acpi_bat.c:1.96	Fri Mar 26 05:59:26 2010
+++ src/sys/dev/acpi/acpi_bat.c	Fri Mar 26 15:51:55 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_bat.c,v 1.96 2010/03/26 05:59:26 pooka Exp $	*/
+/*	$NetBSD: acpi_bat.c,v 1.97 2010/03/26 15:51:55 pooka Exp $	*/
 
 /*-
  * Copyright (c) 2003 The NetBSD Foundation, Inc.
@@ -75,7 +75,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: acpi_bat.c,v 1.96 2010/03/26 05:59:26 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: acpi_bat.c,v 1.97 2010/03/26 15:51:55 pooka Exp $);
 
 #include sys/param.h
 #include sys/condvar.h
@@ -799,12 +799,12 @@
 	switch (cmd) {
 
 	case MODULE_CMD_INIT:
-		return config_init_component(cfdriver_comp_acpibat,
-		cfattach_comp_acpibat, cfdata_acpibat);
+		return config_init_component(cfdriver_ioconf_acpibat,
+		cfattach_ioconf_acpibat, cfdata_ioconf_acpibat);
 
 	case MODULE_CMD_FINI:
-		return config_fini_component(cfdriver_comp_acpibat,
-		cfattach_comp_acpibat, cfdata_acpibat);
+		return config_fini_component(cfdriver_ioconf_acpibat,
+		cfattach_ioconf_acpibat, cfdata_ioconf_acpibat);
 
 	default:
 		return ENOTTY;

Index: src/sys/rump/dev/lib/libubt/ubt_at_usb.c
diff -u src/sys/rump/dev/lib/libubt/ubt_at_usb.c:1.3 src/sys/rump/dev/lib/libubt/ubt_at_usb.c:1.4
--- src/sys/rump/dev/lib/libubt/ubt_at_usb.c:1.3	Thu Mar 25 19:54:08 2010
+++ src/sys/rump/dev/lib/libubt/ubt_at_usb.c	Fri Mar 26 15:51:55 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: ubt_at_usb.c,v 1.3 2010/03/25 19:54:08 pooka Exp $	*/
+/*	$NetBSD: ubt_at_usb.c,v 1.4 2010/03/26 15:51:55 pooka Exp $	*/
 
 #include sys/param.h
 #include sys/types.h
@@ -14,5 +14,6 @@
 RUMP_COMPONENT(RUMP_COMPONENT_DEV)
 {
 
-	config_init_component(cfdriver_comp_ubt, cfattach_comp_ubt, cfdata_ubt);
+	config_init_component(cfdriver_ioconf_ubt,
+	cfattach_ioconf_ubt, cfdata_ioconf_ubt);
 }

Index: src/sys/rump/dev/lib/libucom/ucom_at_usb.c
diff -u src/sys/rump/dev/lib/libucom/ucom_at_usb.c:1.6 src/sys/rump/dev/lib/libucom/ucom_at_usb.c:1.7
--- src/sys/rump/dev/lib/libucom/ucom_at_usb.c:1.6	Thu Mar 25 19:54:08 2010
+++ src/sys/rump/dev/lib/libucom/ucom_at_usb.c	Fri Mar 26 15:51:55 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: ucom_at_usb.c,v 1.6 2010/03/25 19:54:08 pooka Exp $	*/
+/*	$NetBSD: ucom_at_usb.c,v 1.7 2010/03/26 15:51:55 pooka Exp $	*/
 
 #include sys/param.h
 #include sys/types.h
@@ -20,8 +20,8 @@
 	extern struct cdevsw ucom_cdevsw;
 	devmajor_t cmaj, bmaj;
 
-	config_init_component(cfdriver_comp_ucom,
-	cfattach_comp_ucom, cfdata_ucom);
+	config_init_component(cfdriver_ioconf_ucom,
+	cfattach_ioconf_ucom, cfdata_ioconf_ucom);
 
 	bmaj = cmaj = -1;
 	FLAWLESSCALL(devsw_attach(ucom, NULL, bmaj, ucom_cdevsw, cmaj));

Index: src/sys/rump/dev/lib/libugenhc/ugenhc_at_mainbus.c
diff -u src/sys/rump/dev/lib/libugenhc/ugenhc_at_mainbus.c:1.2 src/sys/rump/dev/lib/libugenhc/ugenhc_at_mainbus.c:1.3
--- src/sys/rump/dev/lib/libugenhc/ugenhc_at_mainbus.c:1.2	Thu Mar 25 19:54:08 2010
+++ src/sys/rump/dev/lib/libugenhc/ugenhc_at_mainbus.c	Fri Mar 26 15:51:55 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: ugenhc_at_mainbus.c,v 1.2 2010/03/25 19:54:08 pooka Exp $	*/
+/*	$NetBSD: ugenhc_at_mainbus.c,v 1.3 2010/03/26 15:51:55 pooka Exp $	*/
 
 #include sys/param.h
 #include sys/types.h
@@ -17,6 +17,6 @@
 RUMP_COMPONENT(RUMP_COMPONENT_DEV)
 {
 
-	config_init_component(cfdriver_comp_ugenhc,
-	cfattach_comp_ugenhc, cfdata_ugenhc);
+	config_init_component(cfdriver_ioconf_ugenhc,
+	cfattach_ioconf_ugenhc, cfdata_ioconf_ugenhc);
 }

Index: src/sys/rump/dev/lib/libulpt/ulpt_at_usb.c
diff -u 

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

2010-03-26 Thread Jonathan A. Kollasch
Module Name:src
Committed By:   jakllsch
Date:   Fri Mar 26 15:55:33 UTC 2010

Modified Files:
src/sys/arch/arm/xscale: ixp425-fw.mk

Log Message:
Use objcopy rather than ld to copy Intel NPE firmware blob into ELF.
Avoids internal error in newer binutils ld.
Should fix PR/42864 and PR/43057.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/xscale/ixp425-fw.mk

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

Modified files:

Index: src/sys/arch/arm/xscale/ixp425-fw.mk
diff -u src/sys/arch/arm/xscale/ixp425-fw.mk:1.1 src/sys/arch/arm/xscale/ixp425-fw.mk:1.2
--- src/sys/arch/arm/xscale/ixp425-fw.mk:1.1	Sun Dec 10 10:01:49 2006
+++ src/sys/arch/arm/xscale/ixp425-fw.mk	Fri Mar 26 15:55:33 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: ixp425-fw.mk,v 1.1 2006/12/10 10:01:49 scw Exp $
+#	$NetBSD: ixp425-fw.mk,v 1.2 2010/03/26 15:55:33 jakllsch Exp $
 
 #
 # For IXP425 NE support, this file must be included by the board-specific
@@ -17,5 +17,5 @@
 ixp425_fw.o:	$S/arch/arm/xscale/IxNpeMicrocode.dat
 	-rm -f ${.OBJDIR}/IxNpeMicrocode.dat
 	-ln -s $S/arch/arm/xscale/IxNpeMicrocode.dat ${.OBJDIR}
-	${LD} -b binary -d -warn-common -r -d -o ${.TARGET} IxNpeMicrocode.dat
+	${OBJCOPY} -I binary -O default -B arm IxNpeMicrocode.dat ${.TARGET}
 .endif



CVS commit: src/sys/net80211

2010-03-26 Thread David Young
Module Name:src
Committed By:   dyoung
Date:   Fri Mar 26 17:18:05 UTC 2010

Modified Files:
src/sys/net80211: ieee80211.c

Log Message:
In ieee80211_media_init(), change a pointer that we never write
through to a pointer to const.


To generate a diff of this commit:
cvs rdiff -u -r1.50 -r1.51 src/sys/net80211/ieee80211.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/net80211/ieee80211.c
diff -u src/sys/net80211/ieee80211.c:1.50 src/sys/net80211/ieee80211.c:1.51
--- src/sys/net80211/ieee80211.c:1.50	Tue Jan 19 22:08:17 2010
+++ src/sys/net80211/ieee80211.c	Fri Mar 26 17:18:05 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: ieee80211.c,v 1.50 2010/01/19 22:08:17 pooka Exp $	*/
+/*	$NetBSD: ieee80211.c,v 1.51 2010/03/26 17:18:05 dyoung Exp $	*/
 /*-
  * Copyright (c) 2001 Atsushi Onoe
  * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting
@@ -36,7 +36,7 @@
 __FBSDID($FreeBSD: src/sys/net80211/ieee80211.c,v 1.22 2005/08/10 16:22:29 sam Exp $);
 #endif
 #ifdef __NetBSD__
-__KERNEL_RCSID(0, $NetBSD: ieee80211.c,v 1.50 2010/01/19 22:08:17 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: ieee80211.c,v 1.51 2010/03/26 17:18:05 dyoung Exp $);
 #endif
 
 /*
@@ -352,7 +352,7 @@
 	struct ifnet *ifp = ic-ic_ifp;
 	struct ifmediareq imr;
 	int i, j, mode, rate, maxrate, mword, mopt, r;
-	struct ieee80211_rateset *rs;
+	const struct ieee80211_rateset *rs;
 	struct ieee80211_rateset allrates;
 
 	/*



CVS commit: src

2010-03-26 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Mar 26 18:02:14 UTC 2010

Modified Files:
src: build.sh

Log Message:
make kernobjdir absolute.


To generate a diff of this commit:
cvs rdiff -u -r1.231 -r1.232 src/build.sh

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

Modified files:

Index: src/build.sh
diff -u src/build.sh:1.231 src/build.sh:1.232
--- src/build.sh:1.231	Sun Mar  7 12:34:25 2010
+++ src/build.sh	Fri Mar 26 14:02:14 2010
@@ -1,5 +1,5 @@
 #! /usr/bin/env sh
-#	$NetBSD: build.sh,v 1.231 2010/03/07 17:34:25 hans Exp $
+#	$NetBSD: build.sh,v 1.232 2010/03/26 18:02:14 christos Exp $
 #
 # Copyright (c) 2001-2009 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -1352,7 +1352,7 @@
 	eval cat EOF ${makewrapout}
 #! ${HOST_SH}
 # Set proper variables to allow easy make building of a NetBSD subtree.
-# Generated from:  \$NetBSD: build.sh,v 1.231 2010/03/07 17:34:25 hans Exp $
+# Generated from:  \$NetBSD: build.sh,v 1.232 2010/03/26 18:02:14 christos Exp $
 # with these arguments: ${_args}
 #
 
@@ -1421,6 +1421,13 @@
 	fi
 	KERNCONFDIR=$(getmakevar KERNCONFDIR)
 	KERNOBJDIR=$(getmakevar KERNOBJDIR)
+	case ${KERNOBJDIR} in
+	''|/*)	;;
+	*)	KERNOBJDIR=${TOP}/${KERNOBJDIR}
+		setmakeenv KERNOBJDIR ${KERNOBJDIR}
+		;;
+	esac
+
 	case ${kernelconf} in
 	*/*)
 		kernelconfpath=${kernelconf}



CVS commit: src/sys

2010-03-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Mar 26 18:15:15 UTC 2010

Modified Files:
src/sys/netbt: bluetooth.h files.netbt
src/sys/rump/dev/lib/libubt: Makefile
Removed Files:
src/sys/rump/net/lib/libnetbt: opt_bluetooth.h

Log Message:
Remove unused opt_bluetooth.h

plunky: feel free


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/netbt/bluetooth.h
cvs rdiff -u -r1.4 -r1.5 src/sys/netbt/files.netbt
cvs rdiff -u -r1.2 -r1.3 src/sys/rump/dev/lib/libubt/Makefile
cvs rdiff -u -r1.1 -r0 src/sys/rump/net/lib/libnetbt/opt_bluetooth.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/netbt/bluetooth.h
diff -u src/sys/netbt/bluetooth.h:1.8 src/sys/netbt/bluetooth.h:1.9
--- src/sys/netbt/bluetooth.h:1.8	Mon Sep  8 23:36:55 2008
+++ src/sys/netbt/bluetooth.h	Fri Mar 26 18:15:15 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: bluetooth.h,v 1.8 2008/09/08 23:36:55 gmcgarry Exp $	*/
+/*	$NetBSD: bluetooth.h,v 1.9 2010/03/26 18:15:15 pooka Exp $	*/
 
 /*-
  * Copyright (c) 2005 Iain Hibbert.
@@ -122,8 +122,6 @@
 /*
  * Debugging stuff
  */
-#include opt_bluetooth.h
-
 #ifdef BLUETOOTH_DEBUG
 extern int bluetooth_debug;
 # define DPRINTF(fmt, args...)	do {			\

Index: src/sys/netbt/files.netbt
diff -u src/sys/netbt/files.netbt:1.4 src/sys/netbt/files.netbt:1.5
--- src/sys/netbt/files.netbt:1.4	Sun Sep 10 15:45:56 2006
+++ src/sys/netbt/files.netbt	Fri Mar 26 18:15:15 2010
@@ -1,9 +1,8 @@
-# $NetBSD: files.netbt,v 1.4 2006/09/10 15:45:56 plunky Exp $
+# $NetBSD: files.netbt,v 1.5 2010/03/26 18:15:15 pooka Exp $
 
 # Bluetooth Protocols
 
 define	bluetooth
-defflag	opt_bluetooth.h		BLUETOOTH
 
 # Bluetooth HCI controller (bthub attaches here)
 define	btbus	{ }

Index: src/sys/rump/dev/lib/libubt/Makefile
diff -u src/sys/rump/dev/lib/libubt/Makefile:1.2 src/sys/rump/dev/lib/libubt/Makefile:1.3
--- src/sys/rump/dev/lib/libubt/Makefile:1.2	Mon Mar 22 14:47:02 2010
+++ src/sys/rump/dev/lib/libubt/Makefile	Fri Mar 26 18:15:15 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.2 2010/03/22 14:47:02 pooka Exp $
+#	$NetBSD: Makefile,v 1.3 2010/03/26 18:15:15 pooka Exp $
 #
 
 .PATH:	${.CURDIR}/../../../../dev/usb ${.CURDIR}/../../../../dev/bluetooth
@@ -10,7 +10,5 @@
 
 SRCS+=	ubt_at_usb.c
 
-CPPFLAGS+= -I${RUMPTOP}/net/lib/libnetbt
-
 .include bsd.lib.mk
 .include bsd.klinks.mk



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

2010-03-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Fri Mar 26 18:21:28 UTC 2010

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

Log Message:
rootfstype is not a vfs stub, so it doesn't belong in vfs_stubs


To generate a diff of this commit:
cvs rdiff -u -r1.43 -r1.44 src/sys/rump/librump/rumpvfs/rump_vfs.c
cvs rdiff -u -r1.7 -r1.8 src/sys/rump/librump/rumpvfs/vfsops_stub.c

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

Modified files:

Index: src/sys/rump/librump/rumpvfs/rump_vfs.c
diff -u src/sys/rump/librump/rumpvfs/rump_vfs.c:1.43 src/sys/rump/librump/rumpvfs/rump_vfs.c:1.44
--- src/sys/rump/librump/rumpvfs/rump_vfs.c:1.43	Fri Mar  5 18:41:46 2010
+++ src/sys/rump/librump/rumpvfs/rump_vfs.c	Fri Mar 26 18:21:28 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: rump_vfs.c,v 1.43 2010/03/05 18:41:46 pooka Exp $	*/
+/*	$NetBSD: rump_vfs.c,v 1.44 2010/03/26 18:21:28 pooka Exp $	*/
 
 /*
  * Copyright (c) 2008 Antti Kantee.  All Rights Reserved.
@@ -29,7 +29,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rump_vfs.c,v 1.43 2010/03/05 18:41:46 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: rump_vfs.c,v 1.44 2010/03/26 18:21:28 pooka Exp $);
 
 #include sys/param.h
 #include sys/buf.h
@@ -55,6 +55,7 @@
 #include rump_vfs_private.h
 
 struct cwdinfo cwdi0;
+const char *rootfstype = ROOT_FSTYPE_ANY;
 
 static void rump_rcvp_lwpset(struct vnode *, struct vnode *, struct lwp *);
 
@@ -108,7 +109,6 @@
 			panic(syncer thread create failed: %d, rv);
 	}
 
-	rootfstype = ROOT_FSTYPE_ANY;
 	root_device = rump_rootdev;
 
 	/* bootstrap cwdi (rest done in vfs_mountroot() */

Index: src/sys/rump/librump/rumpvfs/vfsops_stub.c
diff -u src/sys/rump/librump/rumpvfs/vfsops_stub.c:1.7 src/sys/rump/librump/rumpvfs/vfsops_stub.c:1.8
--- src/sys/rump/librump/rumpvfs/vfsops_stub.c:1.7	Thu Mar 19 09:14:37 2009
+++ src/sys/rump/librump/rumpvfs/vfsops_stub.c	Fri Mar 26 18:21:28 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: vfsops_stub.c,v 1.7 2009/03/19 09:14:37 pooka Exp $	*/
+/*	$NetBSD: vfsops_stub.c,v 1.8 2010/03/26 18:21:28 pooka Exp $	*/
 
 /*
  * Copyright (c) 2007 Antti Kantee.  All Rights Reserved.
@@ -28,7 +28,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: vfsops_stub.c,v 1.7 2009/03/19 09:14:37 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: vfsops_stub.c,v 1.8 2010/03/26 18:21:28 pooka Exp $);
 
 #include sys/param.h
 #include sys/errno.h
@@ -39,8 +39,6 @@
 #include miscfs/fifofs/fifo.h
 #include miscfs/syncfs/syncfs.h
 
-const char *rootfstype;
-
 #define VFSSTUB(name)			\
 int name(void *arg) {panic(%s: unimplemented vfs stub, __func__);}
 



CVS commit: src/share/man/man9

2010-03-26 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Mar 26 19:40:41 UTC 2010

Modified Files:
src/share/man/man9: hz.9

Log Message:
Split Nm argument in NAME section on multiple lines, like usual.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/share/man/man9/hz.9

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

Modified files:

Index: src/share/man/man9/hz.9
diff -u src/share/man/man9/hz.9:1.8 src/share/man/man9/hz.9:1.9
--- src/share/man/man9/hz.9:1.8	Thu Mar 25 14:59:36 2010
+++ src/share/man/man9/hz.9	Fri Mar 26 19:40:41 2010
@@ -1,4 +1,4 @@
-.\	$NetBSD: hz.9,v 1.8 2010/03/25 14:59:36 jruoho Exp $
+.\	$NetBSD: hz.9,v 1.9 2010/03/26 19:40:41 wiz Exp $
 .\
 .\ Copyright (c) 2001 The NetBSD Foundation, Inc.
 .\ All rights reserved.
@@ -31,7 +31,11 @@
 .Dt HZ 9
 .Os
 .Sh NAME
-.Nm hz, tick, tickadj, stathz, profhz
+.Nm hz ,
+.Nm tick ,
+.Nm tickadj ,
+.Nm stathz ,
+.Nm profhz
 .Nd system time model
 .Sh SYNOPSIS
 .In sys/kernel.h



CVS commit: src/share/man/man9

2010-03-26 Thread Thomas Klausner
Module Name:src
Committed By:   wiz
Date:   Fri Mar 26 19:43:04 UTC 2010

Modified Files:
src/share/man/man9: pfind.9

Log Message:
Uppercase Dt argument. Fix a typo. Improve wording in one sentence.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/share/man/man9/pfind.9

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

Modified files:

Index: src/share/man/man9/pfind.9
diff -u src/share/man/man9/pfind.9:1.1 src/share/man/man9/pfind.9:1.2
--- src/share/man/man9/pfind.9:1.1	Thu Mar 25 10:09:54 2010
+++ src/share/man/man9/pfind.9	Fri Mar 26 19:43:04 2010
@@ -1,4 +1,4 @@
-.\ $NetBSD: pfind.9,v 1.1 2010/03/25 10:09:54 jruoho Exp $
+.\ $NetBSD: pfind.9,v 1.2 2010/03/26 19:43:04 wiz Exp $
 .\
 .\ Copyright (c) 2010 The NetBSD Foundation, Inc.
 .\ All rights reserved.
@@ -28,7 +28,7 @@
 .\ POSSIBILITY OF SUCH DAMAGE.
 .\
 .Dd March 25, 2010
-.Dt pfind 9
+.Dt PFIND 9
 .Os
 .Sh NAME
 .Nm pfind
@@ -88,7 +88,7 @@
 .Fn pfind
 and
 .Fn pgfind
-are equivalent to
+functions are equivalent to
 .Fn p_find
 and
 .Fn pg_find
@@ -97,7 +97,7 @@
 argument specified as
 .Dv PFIND_UNLOCK .
 .Sh RETURN VALUES
-Upon succesful completion, the described functions return a pointer to either
+Upon successful completion, the described functions return a pointer to either
 .Em struct proc
 or
 .Em struct pgrp .



CVS commit: src/sys/dev/sysmon

2010-03-26 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Fri Mar 26 20:31:06 UTC 2010

Modified Files:
src/sys/dev/sysmon: sysmon_envsys.c sysmonvar.h

Log Message:
Add a routine to iterate over all the sensors on the system.  This will
be needed to update acpiapm_get_powstat() which is currently slightly
broken due to recent rearrangement of acpi_bat(4)'s sensors.  (This
approach is in lieu of exporting proplists between kernel entities, and
avoids exposing some internal sysmon_envsys details.)


To generate a diff of this commit:
cvs rdiff -u -r1.99 -r1.100 src/sys/dev/sysmon/sysmon_envsys.c
cvs rdiff -u -r1.34 -r1.35 src/sys/dev/sysmon/sysmonvar.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/sysmon/sysmon_envsys.c
diff -u src/sys/dev/sysmon/sysmon_envsys.c:1.99 src/sys/dev/sysmon/sysmon_envsys.c:1.100
--- src/sys/dev/sysmon/sysmon_envsys.c:1.99	Fri Mar 26 12:36:59 2010
+++ src/sys/dev/sysmon/sysmon_envsys.c	Fri Mar 26 20:31:06 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: sysmon_envsys.c,v 1.99 2010/03/26 12:36:59 pgoyette Exp $	*/
+/*	$NetBSD: sysmon_envsys.c,v 1.100 2010/03/26 20:31:06 pgoyette Exp $	*/
 
 /*-
  * Copyright (c) 2007, 2008 Juan Romero Pardines.
@@ -64,7 +64,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: sysmon_envsys.c,v 1.99 2010/03/26 12:36:59 pgoyette Exp $);
+__KERNEL_RCSID(0, $NetBSD: sysmon_envsys.c,v 1.100 2010/03/26 20:31:06 pgoyette Exp $);
 
 #include sys/param.h
 #include sys/types.h
@@ -2001,3 +2001,30 @@
 
 	return error;
 }
+
+/*
+ * + sysmon_envsys_foreach_sensor
+ *
+ *	Walk through the devices' sensor lists and execute the callback.
+ *	If the callback returns false, the remainder of the current
+ *	device's sensors are skipped.
+ */
+void   
+sysmon_envsys_foreach_sensor(bool(*func)(struct sysmon_envsys *,
+			 envsys_data_t *, void*), void *arg)
+{
+	struct sysmon_envsys *sme;
+	envsys_data_t *sensor;
+
+	mutex_enter(sme_global_mtx);
+	LIST_FOREACH(sme, sysmon_envsys_list, sme_list) {
+
+		mutex_enter(sme-sme_mtx);
+		TAILQ_FOREACH(sensor, sme-sme_sensors_list, sensors_head) {
+			if ((*func)(sme, sensor, arg))
+break;
+		}
+		mutex_exit(sme-sme_mtx);
+	}
+	mutex_exit(sme_global_mtx);
+}

Index: src/sys/dev/sysmon/sysmonvar.h
diff -u src/sys/dev/sysmon/sysmonvar.h:1.34 src/sys/dev/sysmon/sysmonvar.h:1.35
--- src/sys/dev/sysmon/sysmonvar.h:1.34	Fri Mar 19 02:19:13 2010
+++ src/sys/dev/sysmon/sysmonvar.h	Fri Mar 26 20:31:06 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: sysmonvar.h,v 1.34 2010/03/19 02:19:13 pgoyette Exp $	*/
+/*	$NetBSD: sysmonvar.h,v 1.35 2010/03/26 20:31:06 pgoyette Exp $	*/
 
 /*-
  * Copyright (c) 2000 Zembu Labs, Inc.
@@ -208,6 +208,9 @@
 void	sysmon_envsys_sensor_event(struct sysmon_envsys *, envsys_data_t *,
    int);
 
+void	sysmon_envsys_foreach_sensor(bool(*)(struct sysmon_envsys *,
+ envsys_data_t *, void*), void *);
+
 void	sysmon_envsys_init(void);
 
 /*



CVS commit: src/sys/dev/sysmon

2010-03-26 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Fri Mar 26 21:06:25 UTC 2010

Modified Files:
src/sys/dev/sysmon: sysmon_envsys.c

Log Message:
Make this work the way the preceeding comment blocks says it works, and
break out of the while{ } when the callback returns false, not when it
returns true!


To generate a diff of this commit:
cvs rdiff -u -r1.100 -r1.101 src/sys/dev/sysmon/sysmon_envsys.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/sysmon/sysmon_envsys.c
diff -u src/sys/dev/sysmon/sysmon_envsys.c:1.100 src/sys/dev/sysmon/sysmon_envsys.c:1.101
--- src/sys/dev/sysmon/sysmon_envsys.c:1.100	Fri Mar 26 20:31:06 2010
+++ src/sys/dev/sysmon/sysmon_envsys.c	Fri Mar 26 21:06:25 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: sysmon_envsys.c,v 1.100 2010/03/26 20:31:06 pgoyette Exp $	*/
+/*	$NetBSD: sysmon_envsys.c,v 1.101 2010/03/26 21:06:25 pgoyette Exp $	*/
 
 /*-
  * Copyright (c) 2007, 2008 Juan Romero Pardines.
@@ -64,7 +64,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: sysmon_envsys.c,v 1.100 2010/03/26 20:31:06 pgoyette Exp $);
+__KERNEL_RCSID(0, $NetBSD: sysmon_envsys.c,v 1.101 2010/03/26 21:06:25 pgoyette Exp $);
 
 #include sys/param.h
 #include sys/types.h
@@ -2021,7 +2021,7 @@
 
 		mutex_enter(sme-sme_mtx);
 		TAILQ_FOREACH(sensor, sme-sme_sensors_list, sensors_head) {
-			if ((*func)(sme, sensor, arg))
+			if (!(*func)(sme, sensor, arg))
 break;
 		}
 		mutex_exit(sme-sme_mtx);



CVS commit: src/external/cddl/osnet/sys/sys

2010-03-26 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Fri Mar 26 21:33:28 UTC 2010

Modified Files:
src/external/cddl/osnet/sys/sys: time.h

Log Message:
deal with missing CLOCK_REALTIME


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/cddl/osnet/sys/sys/time.h

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

Modified files:

Index: src/external/cddl/osnet/sys/sys/time.h
diff -u src/external/cddl/osnet/sys/sys/time.h:1.3 src/external/cddl/osnet/sys/sys/time.h:1.4
--- src/external/cddl/osnet/sys/sys/time.h:1.3	Sat Feb 20 20:46:36 2010
+++ src/external/cddl/osnet/sys/sys/time.h	Fri Mar 26 17:33:28 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: time.h,v 1.3 2010/02/21 01:46:36 darran Exp $	*/
+/*	$NetBSD: time.h,v 1.4 2010/03/26 21:33:28 christos Exp $	*/
 
 /*-
  * Copyright (c) 2007 Pawel Jakub Dawidek p...@freebsd.org
@@ -67,9 +67,15 @@
 #else
 
 static __inline hrtime_t gethrtime(void) {
+#ifdef CLOCK_REALTIME
 	struct timespec ts;
 	clock_gettime(CLOCK_REALTIME,ts);
 	return (((u_int64_t) ts.tv_sec) * NANOSEC + ts.tv_nsec);
+#else
+	struct timeval tv;
+	gettimeofday(tv, NULL);
+	return (((u_int64_t) tv.tv_sec) * MICROSEC + tv.tv_usec) * 1000;
+#endif
 }
 
 #endif	/* _KERNEL */



CVS commit: src/sys/miscfs/fifofs

2010-03-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Sat Mar 27 02:33:11 UTC 2010

Modified Files:
src/sys/miscfs/fifofs: fifo_vnops.c

Log Message:
Access fifoinfo only when it's non-NULL.


To generate a diff of this commit:
cvs rdiff -u -r1.66 -r1.67 src/sys/miscfs/fifofs/fifo_vnops.c

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

Modified files:

Index: src/sys/miscfs/fifofs/fifo_vnops.c
diff -u src/sys/miscfs/fifofs/fifo_vnops.c:1.66 src/sys/miscfs/fifofs/fifo_vnops.c:1.67
--- src/sys/miscfs/fifofs/fifo_vnops.c:1.66	Mon Apr 28 20:24:08 2008
+++ src/sys/miscfs/fifofs/fifo_vnops.c	Sat Mar 27 02:33:11 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: fifo_vnops.c,v 1.66 2008/04/28 20:24:08 martin Exp $	*/
+/*	$NetBSD: fifo_vnops.c,v 1.67 2010/03/27 02:33:11 pooka Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -58,7 +58,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: fifo_vnops.c,v 1.66 2008/04/28 20:24:08 martin Exp $);
+__KERNEL_RCSID(0, $NetBSD: fifo_vnops.c,v 1.67 2010/03/27 02:33:11 pooka Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -528,9 +528,10 @@
 {
 	struct fifoinfo	*fip;
 
-	fip = vp-v_fifoinfo;
-	printf(, fifo with %d readers and %d writers,
-	fip-fi_readers, fip-fi_writers);
+	if ((fip = vp-v_fifoinfo) != NULL) {
+		printf(, fifo with %d readers and %d writers,
+		fip-fi_readers, fip-fi_writers);
+	}
 }
 
 /*



CVS commit: src/sys/fs

2010-03-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Sat Mar 27 02:37:35 UTC 2010

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

Log Message:
\n, police!


To generate a diff of this commit:
cvs rdiff -u -r1.142 -r1.143 src/sys/fs/puffs/puffs_vnops.c
cvs rdiff -u -r1.66 -r1.67 src/sys/fs/tmpfs/tmpfs_vnops.c

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

Modified files:

Index: src/sys/fs/puffs/puffs_vnops.c
diff -u src/sys/fs/puffs/puffs_vnops.c:1.142 src/sys/fs/puffs/puffs_vnops.c:1.143
--- src/sys/fs/puffs/puffs_vnops.c:1.142	Thu Jan 14 14:44:13 2010
+++ src/sys/fs/puffs/puffs_vnops.c	Sat Mar 27 02:37:35 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: puffs_vnops.c,v 1.142 2010/01/14 14:44:13 pooka Exp $	*/
+/*	$NetBSD: puffs_vnops.c,v 1.143 2010/03/27 02:37:35 pooka Exp $	*/
 
 /*
  * Copyright (c) 2005, 2006, 2007  Antti Kantee.  All Rights Reserved.
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: puffs_vnops.c,v 1.142 2010/01/14 14:44:13 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: puffs_vnops.c,v 1.143 2010/03/27 02:37:35 pooka Exp $);
 
 #include sys/param.h
 #include sys/buf.h
@@ -2055,10 +2055,11 @@
 	int error;
 
 	/* kernel portion */
-	printf(tag VT_PUFFS, vnode %p, puffs node: %p,\n
+	printf(tag VT_PUFFS, vnode %p, puffs node: %p
 	userspace cookie: %p\n, vp, pn, pn-pn_cookie);
 	if (vp-v_type == VFIFO)
 		fifo_printinfo(vp);
+	printf(\n);
 
 	/* userspace portion */
 	if (EXISTSOP(pmp, PRINT)) {

Index: src/sys/fs/tmpfs/tmpfs_vnops.c
diff -u src/sys/fs/tmpfs/tmpfs_vnops.c:1.66 src/sys/fs/tmpfs/tmpfs_vnops.c:1.67
--- src/sys/fs/tmpfs/tmpfs_vnops.c:1.66	Fri Jan  8 11:35:09 2010
+++ src/sys/fs/tmpfs/tmpfs_vnops.c	Sat Mar 27 02:37:34 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: tmpfs_vnops.c,v 1.66 2010/01/08 11:35:09 pooka Exp $	*/
+/*	$NetBSD: tmpfs_vnops.c,v 1.67 2010/03/27 02:37:34 pooka Exp $	*/
 
 /*
  * Copyright (c) 2005, 2006, 2007 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: tmpfs_vnops.c,v 1.66 2010/01/08 11:35:09 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: tmpfs_vnops.c,v 1.67 2010/03/27 02:37:34 pooka Exp $);
 
 #include sys/param.h
 #include sys/dirent.h
@@ -1336,7 +1336,7 @@
 	printf(tag VT_TMPFS, tmpfs_node %p, flags 0x%x, links %d\n,
 	node, node-tn_flags, node-tn_links);
 	printf(\tmode 0%o, owner %d, group %d, size % PRIdMAX
-	, status 0x%x\n,
+	, status 0x%x,
 	node-tn_mode, node-tn_uid, node-tn_gid,
 	(uintmax_t)node-tn_size, node-tn_status);
 	if (vp-v_type == VFIFO)



CVS commit: src

2010-03-26 Thread NONAKA Kimihiro
Module Name:src
Committed By:   nonaka
Date:   Sat Mar 27 03:04:52 UTC 2010

Modified Files:
src/share/man/man4: sdhc.4
src/sys/arch/i386/conf: ALL GENERIC
src/sys/dev/cardbus: files.cardbus
src/sys/dev/sdmmc: sdhc.c sdhcvar.h
Added Files:
src/sys/dev/cardbus: sdhc_cardbus.c

Log Message:
Added sdhc at cardbus support.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/share/man/man4/sdhc.4
cvs rdiff -u -r1.250 -r1.251 src/sys/arch/i386/conf/ALL
cvs rdiff -u -r1.974 -r1.975 src/sys/arch/i386/conf/GENERIC
cvs rdiff -u -r1.35 -r1.36 src/sys/dev/cardbus/files.cardbus
cvs rdiff -u -r0 -r1.1 src/sys/dev/cardbus/sdhc_cardbus.c
cvs rdiff -u -r1.6 -r1.7 src/sys/dev/sdmmc/sdhc.c
cvs rdiff -u -r1.3 -r1.4 src/sys/dev/sdmmc/sdhcvar.h

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

Modified files:

Index: src/share/man/man4/sdhc.4
diff -u src/share/man/man4/sdhc.4:1.2 src/share/man/man4/sdhc.4:1.3
--- src/share/man/man4/sdhc.4:1.2	Sun Aug  2 00:19:29 2009
+++ src/share/man/man4/sdhc.4	Sat Mar 27 03:04:52 2010
@@ -1,4 +1,4 @@
-.\	$NetBSD: sdhc.4,v 1.2 2009/08/02 00:19:29 nonaka Exp $
+.\	$NetBSD: sdhc.4,v 1.3 2010/03/27 03:04:52 nonaka Exp $
 .\	$OpenBSD: sdhc.4,v 1.4 2009/02/14 18:47:45 deraadt Exp $
 .\
 .\ Theo de Raadt, 2006. Public Domain.
@@ -11,6 +11,7 @@
 .Nd SD Host Controller
 .Sh SYNOPSIS
 .Cd sdhc* at pci?
+.Cd sdhc* at cardbus? function ?
 .Cd sdmmc* at sdhc?
 .Sh DESCRIPTION
 The

Index: src/sys/arch/i386/conf/ALL
diff -u src/sys/arch/i386/conf/ALL:1.250 src/sys/arch/i386/conf/ALL:1.251
--- src/sys/arch/i386/conf/ALL:1.250	Fri Mar 19 04:04:27 2010
+++ src/sys/arch/i386/conf/ALL	Sat Mar 27 03:04:51 2010
@@ -1,4 +1,4 @@
-# $NetBSD: ALL,v 1.250 2010/03/19 04:04:27 cnst Exp $
+# $NetBSD: ALL,v 1.251 2010/03/27 03:04:51 nonaka Exp $
 # From NetBSD: GENERIC,v 1.787 2006/10/01 18:37:54 bouyer Exp
 #
 # ALL machine description file
@@ -17,7 +17,7 @@
 
 options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		ALL-$Revision: 1.250 $
+#ident 		ALL-$Revision: 1.251 $
 
 maxusers	64		# estimated number of users
 
@@ -1333,10 +1333,13 @@
 
 # SD/MMC/SDIO Controller and Device support
 
-# SD/MMC controller
-sdhc*  at pci?# SD Host Controller
-sdmmc* at sdhc? 			# SD/MMC bus
+# PCI SD/MMC controller
+sdhc*	at pci?# SD Host Controller
+
+# CardBus SD/MMC controller
+sdhc*	at cardbus? function ?		# SD Host Controller
 
+sdmmc* at sdhc? 			# SD/MMC bus
 ld*	at sdmmc?
 
 

Index: src/sys/arch/i386/conf/GENERIC
diff -u src/sys/arch/i386/conf/GENERIC:1.974 src/sys/arch/i386/conf/GENERIC:1.975
--- src/sys/arch/i386/conf/GENERIC:1.974	Mon Mar  8 22:51:52 2010
+++ src/sys/arch/i386/conf/GENERIC	Sat Mar 27 03:04:51 2010
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.974 2010/03/08 22:51:52 hubertf Exp $
+# $NetBSD: GENERIC,v 1.975 2010/03/27 03:04:51 nonaka Exp $
 #
 # GENERIC machine description file
 #
@@ -22,7 +22,7 @@
 
 options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		GENERIC-$Revision: 1.974 $
+#ident 		GENERIC-$Revision: 1.975 $
 
 maxusers	64		# estimated number of users
 
@@ -1276,10 +1276,13 @@
 
 # SD/MMC/SDIO Controller and Device support
 
-# SD/MMC controller
+# PCI SD/MMC controller
 sdhc*	at pci?# SD Host Controller
-sdmmc*	at sdhc?			# SD/MMC bus
 
+# CardBus SD/MMC controller
+sdhc*	at cardbus? function ?		# SD Host Controller
+
+sdmmc*	at sdhc?			# SD/MMC bus
 ld*	at sdmmc?
 
 

Index: src/sys/dev/cardbus/files.cardbus
diff -u src/sys/dev/cardbus/files.cardbus:1.35 src/sys/dev/cardbus/files.cardbus:1.36
--- src/sys/dev/cardbus/files.cardbus:1.35	Sun Jul 19 06:28:08 2009
+++ src/sys/dev/cardbus/files.cardbus	Sat Mar 27 03:04:51 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: files.cardbus,v 1.35 2009/07/19 06:28:08 kiyohara Exp $
+#	$NetBSD: files.cardbus,v 1.36 2010/03/27 03:04:51 nonaka Exp $
 #
 # files.cardbus
 #
@@ -137,3 +137,9 @@
 #
 attach	siisata at cardbus with siisata_cardbus
 file	dev/cardbus/siisata_cardbus.c	siisata_cardbus
+
+#
+# SD Host Controller
+#
+attach	sdhc at cardbus with sdhc_cardbus
+file	dev/cardbus/sdhc_cardbus.c	sdhc_cardbus

Index: src/sys/dev/sdmmc/sdhc.c
diff -u src/sys/dev/sdmmc/sdhc.c:1.6 src/sys/dev/sdmmc/sdhc.c:1.7
--- src/sys/dev/sdmmc/sdhc.c:1.6	Wed Feb 24 22:38:08 2010
+++ src/sys/dev/sdmmc/sdhc.c	Sat Mar 27 03:04:52 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: sdhc.c,v 1.6 2010/02/24 22:38:08 dyoung Exp $	*/
+/*	$NetBSD: sdhc.c,v 1.7 2010/03/27 03:04:52 nonaka Exp $	*/
 /*	$OpenBSD: sdhc.c,v 1.25 2009/01/13 19:44:20 grange Exp $	*/
 
 /*
@@ -23,7 +23,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: sdhc.c,v 1.6 2010/02/24 22:38:08 dyoung Exp $);
+__KERNEL_RCSID(0, $NetBSD: sdhc.c,v 1.7 2010/03/27 03:04:52 nonaka Exp $);
 
 #include sys/param.h
 #include sys/device.h
@@ -121,6 +121,7 @@
 static int	sdhc_soft_reset(struct sdhc_host *, int);
 static int	sdhc_wait_intr(struct sdhc_host *, int, int);
 

CVS commit: src/doc

2010-03-26 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sat Mar 27 03:38:27 UTC 2010

Modified Files:
src/doc: BRANCHES

Log Message:
minor updates:
- gmcgarry_ctxsw replaced by yamt-idlelwp
- move nick-hppapmap into the right section
- rtr-xorg-branch is dead
- thorpej-atomic is (bascially) merged to -current


To generate a diff of this commit:
cvs rdiff -u -r1.289 -r1.290 src/doc/BRANCHES

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

Modified files:

Index: src/doc/BRANCHES
diff -u src/doc/BRANCHES:1.289 src/doc/BRANCHES:1.290
--- src/doc/BRANCHES:1.289	Sun Mar 21 13:04:24 2010
+++ src/doc/BRANCHES	Sat Mar 27 03:38:27 2010
@@ -1,4 +1,4 @@
-#	$NetBSD: BRANCHES,v 1.289 2010/03/21 13:04:24 yamt Exp $
+#	$NetBSD: BRANCHES,v 1.290 2010/03/27 03:38:27 mrg Exp $
 #
 # This file contains a list of branches that exist in the NetBSD CVS
 # tree and their current state.
@@ -51,7 +51,7 @@
 Start Date:
 End Date:
 Base Tag:	comdex-fall-1999-base
-Maintainer:	?
+Maintainer:	mycroft
 Scope:		Entire tree.
 Notes:
 
@@ -297,21 +297,6 @@
 		routines, and allow improvements to be shared across all arm
 		based hardware.
 
-Branch:		gmcgarry_ctxsw
-Description:	Separate scheduler from context-switch code
-Status:		Dormant
-Start Date:	18 December 2002
-End Date:
-Base Tag:	gmcgarry_ctxsw_base
-Maintainer:	Gregory McGarry gmcga...@netbsd.org
-Scope:		kernel
-Notes:		Removing knowledge of the scheduler and its run queues
-		from the machine-dependent context switch code is the
-		first step in cleaning up the scheduler.  It is necessary
-		for the newlock branch, making the scheduler SMP friendly,
-		adding real-time scheduler extensions, and reducing the
-		number of code paths for LWP and proc switching.
-
 Branch:		gmcgarry_ucred
 Description:	Integrate and encapsulate user credentials
 Status:		Dormant
@@ -452,17 +437,6 @@
 Scope:		kernel
 Notes:
 
-Branch:		nick-hppapmap
-Description:	Update of hppa pmap with OpenBSD code.
-Status: 	Terminated; merged to -current
-Start Date:	27 October 2008
-End Date:	30 April 2009
-Base Tag:	nick-hppapmap-base3
-Maintainer:	Nick Hudson sk...@netbsd.org
-Scope:		sys/
-Notes:		Port of the OpenBSD pmap including support for PA2.0 CPUs in
-		32-bit mode.
-
 Branch:		nick-net80211-sync
 Description:	sync of net80211 with FreeBSD
 Status:		Active
@@ -536,22 +510,6 @@
 		(before the merge to -current) with an interop IPv6 test.
 		More info at: http://www.tahi.org/
 
-Branch:		rtr-xorg-branch
-Description:	xorg  static build alterations to src/x11
-Status:		Active
-Start Date:	Nov 15 2004
-End Date:	
-Base tag:	rtr-xorg-branch-base
-Maintainer:	Tyler R. Retzlaff r...@netbsd.org
-Scope:		x11
-		distrib/sets/lists
-		share/mk/bsd.x11.mk
-		share/mk/bsd.own.mk
-		etc/mtree/NetBSD.dist
-Notes:		Requires parts of xsrc/xfree (HEAD)
-		xsrc/local, xsrc/xfree/xc/programs/Xserver/hw/netbsd
-		Requires xorg (XORG-6_8_1)
-
 Branch:  	wrstuden-fixsa
 Description:	Fix a number of issues present with Scheduler Activations.
 Status: 	Active
@@ -648,80 +606,6 @@
 Notes:		Used as experiment sandbox and if successful hopefully one day
 		to be integrated.
 
-Branch:		thorpej-atomic
-Description:	Implementation of an atomic memory operations API modeled
-		after the one in Solaris 10.
-Status:		Active
-Start Date:	Apr 11 2007
-End Date:
-Base tag:	thorpej-atomic-base
-Maintainer:	Jason Thorpe thor...@netbsd.org
-Scope:		src/common
-		src/sys
-Notes:		Base atomic primitives need to be implemented for
-		all of the supported architectures:
-
-		alpha		DONE
-		arm		DONE
-		hppa
-		i386		DONE
-		ia64
-		m68k		DONE (except for 68010)
-		mips
-		ns32k
-		powerpc		DONE except for membar_*()
-		powerpc64	DONE except for membar_*()
-		sh3
-		sparc		DONE except for membar_*()
-		sparc64		DONE except for membar_*()
-		vax
-		x86_64		DONE
-
-		Tested:
-
-		alpha		NO
-		arm		NO
-		hppa		NO
-		i386		NO
-		ia64		NO
-		m68k		NO
-		mips		NO
-		ns32k		NO
-		powerpc		NO
-		powerpc64	NO
-		sh3		NO
-		sparc		NO
-		sparc64		NO
-		vax		NO
-		x86_64		NO
-
-		TODO:
-
-		all		- Need to replace mb_*() with membar_*().
-
-- Audit MUTEX_CAS() and RWLOCK_CAS() uses
-  to see of membar_enter() is required here.
-
-- Talk to ad@ -- figure out of non-atomic
-  mutex / rwlock release is actually safe.
-
-		arm		- Consider using a RAS technique like
-  MIPS uses for _lock_cas() and the mutex
-  stubs.  Possibly do more than one atomic
-  op as a RAS.  Possibly implement mutex
-  stubs using the technique.
-
-		m68k		- Need to do 68010 support.
-		
-		i386		- Need to change when x86_patch() is called
-  so we can test ncpus.
-
-		powerpc		- Figure out if we need barriers in the
-  atomic ops themselves (hopefully not!)
-
-		x86_64		- Need to change when x86_patch() is called
-  so we can test ncpus.
-
 
 # Individual developers' branches (Terminated):