CVS commit: src/sys/arch/powerpc

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 06:10:42 UTC 2011

Modified Files:
src/sys/arch/powerpc/include: types.h
src/sys/arch/powerpc/powerpc: powerpc_machdep.c

Log Message:
need mm_md_direct_mapped_phys support.


To generate a diff of this commit:
cvs rdiff -u -r1.41 -r1.42 src/sys/arch/powerpc/include/types.h
cvs rdiff -u -r1.51 -r1.52 src/sys/arch/powerpc/powerpc/powerpc_machdep.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/powerpc/include/types.h
diff -u src/sys/arch/powerpc/include/types.h:1.41 src/sys/arch/powerpc/include/types.h:1.42
--- src/sys/arch/powerpc/include/types.h:1.41	Sun Jun  5 16:52:25 2011
+++ src/sys/arch/powerpc/include/types.h	Sun Jun 12 06:10:41 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: types.h,v 1.41 2011/06/05 16:52:25 matt Exp $	*/
+/*	$NetBSD: types.h,v 1.42 2011/06/12 06:10:41 matt Exp $	*/
 
 /*-
  * Copyright (C) 1995 Wolfgang Solfrank.
@@ -89,4 +89,6 @@
 #define	PCU_UNIT_COUNT	2
 #endif
 
+#define	__HAVE_MM_MD_DIRECT_MAPPED_PHYS
+
 #endif	/* _MACHTYPES_H_ */

Index: src/sys/arch/powerpc/powerpc/powerpc_machdep.c
diff -u src/sys/arch/powerpc/powerpc/powerpc_machdep.c:1.51 src/sys/arch/powerpc/powerpc/powerpc_machdep.c:1.52
--- src/sys/arch/powerpc/powerpc/powerpc_machdep.c:1.51	Sun Jun 12 03:35:45 2011
+++ src/sys/arch/powerpc/powerpc/powerpc_machdep.c	Sun Jun 12 06:10:42 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: powerpc_machdep.c,v 1.51 2011/06/12 03:35:45 rmind Exp $	*/
+/*	$NetBSD: powerpc_machdep.c,v 1.52 2011/06/12 06:10:42 matt Exp $	*/
 
 /*
  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
@@ -32,7 +32,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: powerpc_machdep.c,v 1.51 2011/06/12 03:35:45 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: powerpc_machdep.c,v 1.52 2011/06/12 06:10:42 matt Exp $);
 
 #include opt_altivec.h
 #include opt_modular.h
@@ -433,6 +433,17 @@
 }
 #endif /* MODULAR */
 
+bool
+mm_md_direct_mapped_phys(paddr_t pa, vaddr_t *vap)
+{
+	if (atop(pa)  physmem) {
+		*vap = pa;
+		return true;
+	}
+
+	return false;
+}
+
 int
 mm_md_physacc(paddr_t pa, vm_prot_t prot)
 {



CVS commit: src/usr.bin/pmap

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 06:35:00 UTC 2011

Modified Files:
src/usr.bin/pmap: pmap.c

Log Message:
an_ref is now a uintptr_t.


To generate a diff of this commit:
cvs rdiff -u -r1.45 -r1.46 src/usr.bin/pmap/pmap.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/pmap/pmap.c
diff -u src/usr.bin/pmap/pmap.c:1.45 src/usr.bin/pmap/pmap.c:1.46
--- src/usr.bin/pmap/pmap.c:1.45	Mon Dec 14 17:16:12 2009
+++ src/usr.bin/pmap/pmap.c	Sun Jun 12 06:34:59 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.45 2009/12/14 17:16:12 uebayasi Exp $ */
+/*	$NetBSD: pmap.c,v 1.46 2011/06/12 06:34:59 mrg Exp $ */
 
 /*
  * Copyright (c) 2002, 2003 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
 
 #include sys/cdefs.h
 #ifndef lint
-__RCSID($NetBSD: pmap.c,v 1.45 2009/12/14 17:16:12 uebayasi Exp $);
+__RCSID($NetBSD: pmap.c,v 1.46 2011/06/12 06:34:59 mrg Exp $);
 #endif
 
 #include string.h
@@ -659,7 +659,7 @@
 		else
 			KDEREF(kd, anon);
 
-		printf( = { an_ref = %d, an_page = %p, an_swslot = %d },
+		printf( = { an_ref = %PRIuPTR, an_page = %p, an_swslot = %d },
 		D(anon, anon)-an_ref, D(anon, anon)-an_page,
 		D(anon, anon)-an_swslot);
 	}



CVS commit: src/sys

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 06:36:38 UTC 2011

Modified Files:
src/sys/rump/librump/rumpkern: Makefile.rumpkern vm.c
src/sys/uvm: uvm_object.c

Log Message:
include uvm_object.c in the rump kernel for the new uvm_obj* functions.
don't build the uvm_object.c uvm_object_printit() for _RUMPKERNEL. (XXX)
add empty panic() stubs for uvm_loanbreak() and ubc_purge().

fixes some more 5.99.53 rump build issues.


To generate a diff of this commit:
cvs rdiff -u -r1.109 -r1.110 src/sys/rump/librump/rumpkern/Makefile.rumpkern
cvs rdiff -u -r1.115 -r1.116 src/sys/rump/librump/rumpkern/vm.c
cvs rdiff -u -r1.8 -r1.9 src/sys/uvm/uvm_object.c

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

Modified files:

Index: src/sys/rump/librump/rumpkern/Makefile.rumpkern
diff -u src/sys/rump/librump/rumpkern/Makefile.rumpkern:1.109 src/sys/rump/librump/rumpkern/Makefile.rumpkern:1.110
--- src/sys/rump/librump/rumpkern/Makefile.rumpkern:1.109	Thu May 19 21:24:55 2011
+++ src/sys/rump/librump/rumpkern/Makefile.rumpkern	Sun Jun 12 06:36:38 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.rumpkern,v 1.109 2011/05/19 21:24:55 joerg Exp $
+#	$NetBSD: Makefile.rumpkern,v 1.110 2011/06/12 06:36:38 mrg Exp $
 #
 
 .include ${RUMPTOP}/Makefile.rump
@@ -106,7 +106,7 @@
 	syscalls.c
 
 # sys/uvm
-SRCS+=	uvm_aobj.c uvm_readahead.c
+SRCS+=	uvm_aobj.c uvm_readahead.c uvm_object.c
 
 # 4.4BSD secmodel.  selection is hardcoded for now
 SRCS+=	secmodel_suser.c

Index: src/sys/rump/librump/rumpkern/vm.c
diff -u src/sys/rump/librump/rumpkern/vm.c:1.115 src/sys/rump/librump/rumpkern/vm.c:1.116
--- src/sys/rump/librump/rumpkern/vm.c:1.115	Sun Jun 12 03:35:59 2011
+++ src/sys/rump/librump/rumpkern/vm.c	Sun Jun 12 06:36:38 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: vm.c,v 1.115 2011/06/12 03:35:59 rmind Exp $	*/
+/*	$NetBSD: vm.c,v 1.116 2011/06/12 06:36:38 mrg Exp $	*/
 
 /*
  * Copyright (c) 2007-2011 Antti Kantee.  All Rights Reserved.
@@ -41,7 +41,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: vm.c,v 1.115 2011/06/12 03:35:59 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: vm.c,v 1.116 2011/06/12 06:36:38 mrg Exp $);
 
 #include sys/param.h
 #include sys/atomic.h
@@ -634,6 +634,20 @@
 	return EBUSY;
 }
 
+struct vm_page *
+uvm_loanbreak(struct vm_page *pg)
+{
+
+	panic(%s: unimplemented, __func__);
+}
+
+void
+ubc_purge(struct uvm_object *uobj)
+{
+
+	panic(%s: unimplemented, __func__);
+}
+
 #ifdef DEBUGPRINT
 void
 uvm_object_printit(struct uvm_object *uobj, bool full,

Index: src/sys/uvm/uvm_object.c
diff -u src/sys/uvm/uvm_object.c:1.8 src/sys/uvm/uvm_object.c:1.9
--- src/sys/uvm/uvm_object.c:1.8	Sun Jun 12 03:36:03 2011
+++ src/sys/uvm/uvm_object.c	Sun Jun 12 06:36:38 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: uvm_object.c,v 1.8 2011/06/12 03:36:03 rmind Exp $	*/
+/*	$NetBSD: uvm_object.c,v 1.9 2011/06/12 06:36:38 mrg Exp $	*/
 
 /*
  * Copyright (c) 2006, 2010 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: uvm_object.c,v 1.8 2011/06/12 03:36:03 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: uvm_object.c,v 1.9 2011/06/12 06:36:38 mrg Exp $);
 
 #include opt_ddb.h
 
@@ -225,7 +225,7 @@
 	mutex_exit(uobj-vmobjlock);
 }
 
-#if defined(DDB) || defined(DEBUGPRINT)
+#if (defined(DDB) || defined(DEBUGPRINT))  !defined(_RUMPKERNEL)
 
 /*
  * uvm_object_printit: actually prints the object



CVS commit: src/tests/rump/kernspace

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 06:38:14 UTC 2011

Modified Files:
src/tests/rump/kernspace: busypage.c

Log Message:
vmobjlock is now a pointer to kmutex_t.  use it as one.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tests/rump/kernspace/busypage.c

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

Modified files:

Index: src/tests/rump/kernspace/busypage.c
diff -u src/tests/rump/kernspace/busypage.c:1.3 src/tests/rump/kernspace/busypage.c:1.4
--- src/tests/rump/kernspace/busypage.c:1.3	Thu Sep  9 09:59:48 2010
+++ src/tests/rump/kernspace/busypage.c	Sun Jun 12 06:38:14 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: busypage.c,v 1.3 2010/09/09 09:59:48 pooka Exp $	*/
+/*	$NetBSD: busypage.c,v 1.4 2011/06/12 06:38:14 mrg Exp $	*/
 
 /*-
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
 
 #include sys/cdefs.h
 #if !defined(lint)
-__RCSID($NetBSD: busypage.c,v 1.3 2010/09/09 09:59:48 pooka Exp $);
+__RCSID($NetBSD: busypage.c,v 1.4 2011/06/12 06:38:14 mrg Exp $);
 #endif /* !lint */
 
 #include sys/param.h
@@ -52,11 +52,11 @@
 thread(void *arg)
 {
 
-	mutex_enter(uobj-vmobjlock);
+	mutex_enter(uobj-vmobjlock);
 	threadrun = true;
 	cv_signal(tcv);
 	testpg-flags |= PG_WANTED;
-	UVM_UNLOCK_AND_WAIT(testpg, uobj-vmobjlock, false, tw, 0);
+	UVM_UNLOCK_AND_WAIT(testpg, uobj-vmobjlock, false, tw, 0);
 	kthread_exit(0);
 }
 
@@ -69,9 +69,9 @@
 	cv_init(tcv, napina);
 
 	uobj = uao_create(1, 0);
-	mutex_enter(uobj-vmobjlock);
+	mutex_enter(uobj-vmobjlock);
 	testpg = uvm_pagealloc(uobj, 0, NULL, 0);
-	mutex_exit(uobj-vmobjlock);
+	mutex_exit(uobj-vmobjlock);
 	if (testpg == NULL)
 		panic(couldn't create vm page);
 
@@ -80,12 +80,12 @@
 	if (rv)
 		panic(thread creation failed: %d, rv);
 
-	mutex_enter(uobj-vmobjlock);
+	mutex_enter(uobj-vmobjlock);
 	while (!threadrun)
-		cv_wait(tcv, uobj-vmobjlock);
+		cv_wait(tcv, uobj-vmobjlock);
 
 	uvm_page_unbusy(testpg, 1);
-	mutex_exit(uobj-vmobjlock);
+	mutex_exit(uobj-vmobjlock);
 
 	rv = kthread_join(newl);
 	if (rv)



CVS commit: src/sys/arch/bebox/include

2011-06-12 Thread KIYOHARA Takashi
Module Name:src
Committed By:   kiyohara
Date:   Sun Jun 12 07:04:55 UTC 2011

Modified Files:
src/sys/arch/bebox/include: param.h

Log Message:
Remove comment-outed DELAY().


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/bebox/include/param.h

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

Modified files:

Index: src/sys/arch/bebox/include/param.h
diff -u src/sys/arch/bebox/include/param.h:1.12 src/sys/arch/bebox/include/param.h:1.13
--- src/sys/arch/bebox/include/param.h:1.12	Sun Mar  6 20:34:57 2011
+++ src/sys/arch/bebox/include/param.h	Sun Jun 12 07:04:55 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: param.h,v 1.12 2011/03/06 20:34:57 he Exp $	*/
+/*	$NetBSD: param.h,v 1.13 2011/06/12 07:04:55 kiyohara Exp $	*/
 
 /*-
  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
@@ -38,7 +38,6 @@
 #endif
 
 
-//#define DELAY(ms) delay(ms)
 /*
  * Machine dependent constants for PowerPC (32-bit only currently)
  */



CVS commit: src/sys/arch/bebox/stand/boot

2011-06-12 Thread KIYOHARA Takashi
Module Name:src
Committed By:   kiyohara
Date:   Sun Jun 12 07:07:17 UTC 2011

Modified Files:
src/sys/arch/bebox/stand/boot: cpu.c

Log Message:
Remove null line.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/bebox/stand/boot/cpu.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/bebox/stand/boot/cpu.c
diff -u src/sys/arch/bebox/stand/boot/cpu.c:1.6 src/sys/arch/bebox/stand/boot/cpu.c:1.7
--- src/sys/arch/bebox/stand/boot/cpu.c:1.6	Sun Dec 11 12:17:04 2005
+++ src/sys/arch/bebox/stand/boot/cpu.c	Sun Jun 12 07:07:17 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: cpu.c,v 1.6 2005/12/11 12:17:04 christos Exp $	*/
+/*	$NetBSD: cpu.c,v 1.7 2011/06/12 07:07:17 kiyohara Exp $	*/
 
 /*
  * This file contains information proprietary to Be Inc.
@@ -58,7 +58,6 @@
 /*
  * Force CPU #1 into Hard RESET state
  */
-
 void
 resetCPU1(void)
 {



CVS commit: src

2011-06-12 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jun 12 07:25:44 UTC 2011

Modified Files:
src/share/man/man4: aibs.4
src/sys/dev/acpi: files.acpi
src/sys/modules/aibs: Makefile
Added Files:
src/sys/dev/acpi: aibs_acpi.c
Removed Files:
src/sys/dev/acpi: atk0110.c

Log Message:
Rewrite the aibs(4) driver in order to support new models. Draws from the
revision 1.6 (claudio@) of the OpenBSD's equivalent driver. Tested by mrg@.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/share/man/man4/aibs.4
cvs rdiff -u -r0 -r1.1 src/sys/dev/acpi/aibs_acpi.c
cvs rdiff -u -r1.16 -r0 src/sys/dev/acpi/atk0110.c
cvs rdiff -u -r1.88 -r1.89 src/sys/dev/acpi/files.acpi
cvs rdiff -u -r1.3 -r1.4 src/sys/modules/aibs/Makefile

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/aibs.4
diff -u src/share/man/man4/aibs.4:1.6 src/share/man/man4/aibs.4:1.7
--- src/share/man/man4/aibs.4:1.6	Sat Mar  6 19:53:33 2010
+++ src/share/man/man4/aibs.4	Sun Jun 12 07:25:43 2011
@@ -1,4 +1,4 @@
-.\	$NetBSD: aibs.4,v 1.6 2010/03/06 19:53:33 cnst Exp $
+.\	$NetBSD: aibs.4,v 1.7 2011/06/12 07:25:43 jruoho Exp $
 .\	$OpenBSD: aibs.4,v 1.4 2009/07/30 06:30:45 jmc Exp $
 .\
 .\ Copyright (c) 2009 Constantine A. Murenin cnst+net...@bugmail.mojo.ru
@@ -15,24 +15,21 @@
 .\ ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 .\ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 .\
-.Dd February 8, 2010
+.Dd June 12, 2011
 .Dt AIBS 4
 .Os
 .Sh NAME
 .Nm aibs
-.Nd ASUSTeK AI Booster ACPI ATK0110 voltage, temperature, and fan sensor
+.Nd ASUSTeK AI Booster voltage, temperature, and fan sensor
 .Sh SYNOPSIS
 .Cd aibs* at acpi?
 .Sh DESCRIPTION
 The
 .Nm
-driver provides support for the voltage, temperature and fan sensors
-available through the
-.Tn ATK0110
-.Tn ASOC
+driver provides support for voltage, temperature, and fan sensors
+available as an
 .Tn ACPI
-device
-on
+device on
 .Tn ASUSTeK
 motherboards.
 The number of sensors of each type,
@@ -53,43 +50,43 @@
 .Bl -bullet
 .It
 Voltage sensors can have a state of
-.Dv valid ,
-.Dv critunder ,
+.Sq valid ,
+.Sq critunder ,
 or
-.Dv critover ;
+.Sq critover ;
 temperature sensors can have a state of
-.Dv valid ,
-.Dv warnover ,
-.Dv critover ,
+.Sq valid ,
+.Sq warnover ,
+.Sq critover ,
 or
-.Dv invalid ;
+.Sq invalid ;
 and fan sensors can have a state of
-.Dv valid ,
-.Dv warnunder ,
+.Sq valid ,
+.Sq warnunder ,
 or
-.Dv warnover .
+.Sq warnover .
 .It
 Temperature sensors that have a reading of 0
 are marked
-.Dv invalid ,
+.Sq invalid ,
 whereas all other sensors are always assumed valid.
 .It
-Voltage sensors have a lower and an upper limit
-.Dv ( critunder
+Voltage sensors have a lower and an upper limit,
+.Sq critunder
 and
-.Dv critover ) ,
-temperature sensors have two upper limits
-.Dv ( warnover
+.Sq critover ,
+temperature sensors have two upper limits,
+.Sq warnover
 and
-.Dv critover ) ,
+.Sq critover ,
 whereas fan sensors may either have only the lower limit
-.Dv ( warnunder ) ,
-or, depending on the
-.Tn DSDT ,
-one lower and one upper limit
-.Dv ( warnunder
+.Sq warnunder ,
+or, depending on the vendor's
+.Tn ACPI
+implementation, one lower and one upper limit,
+.Sq warnunder
 and
-.Dv warnover ) .
+.Sq warnover .
 .El
 .Pp
 Sensor values and limits are made available through the
@@ -189,6 +186,7 @@
 the hardware monitoring chip through
 .Tn ACPI .
 .Sh SEE ALSO
+.Xr acpi 4 ,
 .Xr envsys 4 ,
 .Xr envstat 8
 .Sh HISTORY
@@ -199,8 +197,7 @@
 DragonFly 2.4.1
 and
 .Nx 6.0 .
-.Pp
-An earlier version of the driver,
+An earlier version of the driver, named
 .Nm aiboost ,
 first appeared in
 .Fx 7.0
@@ -212,16 +209,19 @@
 .Nm
 driver was written for
 .Ox ,
-DragonFly
-and
+DragonFly BSD, and
 .Nx
 by
 .An Constantine A. Murenin Aq http://cnst.su/ ,
 Raouf Boutaba Research Group,
 David R. Cheriton School of Computer Science,
 University of Waterloo.
-.Pp
-An earlier version of the driver, named
+.An Jukka Ruohonen
+.Aq jruoho...@iki.fi
+later reworked and adjusted the driver to support new
+.Tn ASUSTeK
+motherboards.
+The earlier version of the driver,
 .Nm aiboost ,
 was written for
 .Fx

Index: src/sys/dev/acpi/files.acpi
diff -u src/sys/dev/acpi/files.acpi:1.88 src/sys/dev/acpi/files.acpi:1.89
--- src/sys/dev/acpi/files.acpi:1.88	Sun Feb 27 17:10:33 2011
+++ src/sys/dev/acpi/files.acpi	Sun Jun 12 07:25:43 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: files.acpi,v 1.88 2011/02/27 17:10:33 jruoho Exp $
+#	$NetBSD: files.acpi,v 1.89 2011/06/12 07:25:43 jruoho Exp $
 
 include dev/acpi/acpica/files.acpica
 
@@ -180,10 +180,10 @@
 attach	wb at acpinodebus with wb_acpi
 file	dev/acpi/wb_acpi.c		wb_acpi
 
-# ASUSTeK AI Booster ATK0110
+# ASUSTeK AI Booster
 device	aibs: sysmon_envsys
 attach	aibs at acpinodebus
-file	dev/acpi/atk0110.c		aibs
+file	dev/acpi/aibs_acpi.c		aibs
 
 # ACPI SMBus controller
 

CVS commit: othersrc/external/bsd/bufgap

2011-06-12 Thread Alistair G. Crooks
Module Name:othersrc
Committed By:   agc
Date:   Sun Jun 12 07:48:29 UTC 2011

Update of /cvsroot/othersrc/external/bsd/bufgap
In directory ivanova.netbsd.org:/tmp/cvs-serv28782

Log Message:
Import buffer gap routines into othersrc.

These routines were originally written in 1996 to support various
editors, and are still in use where text may change at beginning and
ends of buffers, with a need to be able to move forwards and backwards
within a buffer efficiently, counting characters and line positions. 

A buffer gap structure works by having a number of characters after
the gap, and a number of characters before the gap.  To move forwards,
the next character before the gap is copied to the group of characters
after the gap, and the count of before characters decremented, and the
after count incremented.  Moving backwards is the opposite operation. 
Text is inserted at the end of the after characters.

A small program is included which exercises the routines by moving to
the end of the file character by character, reversing character by
character, and then moving forwards once again.

Status:

Vendor Tag: CROOKS
Release Tags:   bufgap-base

N othersrc/external/bsd/bufgap/Makefile
N othersrc/external/bsd/bufgap/dist/bufgap.c
N othersrc/external/bsd/bufgap/dist/bufgap.h
N othersrc/external/bsd/bufgap/dist/defs.h
N othersrc/external/bsd/bufgap/dist/bufgap
N othersrc/external/bsd/bufgap/dist/bufgap.3
N othersrc/external/bsd/bufgap/dist/main.c
N othersrc/external/bsd/bufgap/dist/bufgap.1
N othersrc/external/bsd/bufgap/libbufgap/shlib_version
N othersrc/external/bsd/bufgap/libbufgap/config.h
N othersrc/external/bsd/bufgap/libbufgap/Makefile
N othersrc/external/bsd/bufgap/bufgap/Makefile

No conflicts created by this import



CVS commit: src/sys

2011-06-12 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jun 12 10:11:53 UTC 2011

Modified Files:
src/sys/arch/ia64/acpi: acpi_machdep.c
src/sys/arch/ia64/include: acpi_machdep.h
src/sys/arch/x86/acpi: acpi_cpu_md.c
src/sys/arch/x86/conf: files.x86
src/sys/arch/x86/include: acpi_machdep.h
src/sys/dev/acpi: acpi.c acpi_cpu.c acpi_cpu.h
Added Files:
src/sys/arch/x86/acpi: acpi_pdc.c

Log Message:
Move the evaluation of the _PDC control method out from the acpicpu(4)
driver to the main acpi(4) stack. Follow Linux and evaluate it early.
Should fix PR port-amd64/42895, possibly also PR kern/42583, and many
other comparable bugs.

A common sense explanation is that Intel supplies additional CPU tables to
OEMs. BIOS writers do not bother to modify their DSDTs, but instead load
these extra tables dynamically as secondary SSDT tables. The actual Load()
happens when the _PDC method is invoked, and thus namespace errors occur
when the CPU-specific ACPI methods are not yet present but referenced in the
AML by various drivers, including, but not limited to, acpitz(4).


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/ia64/acpi/acpi_machdep.c
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/ia64/include/acpi_machdep.h
cvs rdiff -u -r1.60 -r1.61 src/sys/arch/x86/acpi/acpi_cpu_md.c
cvs rdiff -u -r0 -r1.1 src/sys/arch/x86/acpi/acpi_pdc.c
cvs rdiff -u -r1.69 -r1.70 src/sys/arch/x86/conf/files.x86
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/x86/include/acpi_machdep.h
cvs rdiff -u -r1.242 -r1.243 src/sys/dev/acpi/acpi.c
cvs rdiff -u -r1.40 -r1.41 src/sys/dev/acpi/acpi_cpu.c \
src/sys/dev/acpi/acpi_cpu.h

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

Modified files:

Index: src/sys/arch/ia64/acpi/acpi_machdep.c
diff -u src/sys/arch/ia64/acpi/acpi_machdep.c:1.3 src/sys/arch/ia64/acpi/acpi_machdep.c:1.4
--- src/sys/arch/ia64/acpi/acpi_machdep.c:1.3	Thu Jan 13 03:40:50 2011
+++ src/sys/arch/ia64/acpi/acpi_machdep.c	Sun Jun 12 10:11:52 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_machdep.c,v 1.3 2011/01/13 03:40:50 jruoho Exp $	*/
+/*	$NetBSD: acpi_machdep.c,v 1.4 2011/06/12 10:11:52 jruoho Exp $	*/
 /*
  * Copyright (c) 2009 KIYOHARA Takashi
  * All rights reserved.
@@ -28,7 +28,7 @@
  * Machine-dependent routines for ACPICA.
  */
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: acpi_machdep.c,v 1.3 2011/01/13 03:40:50 jruoho Exp $);
+__KERNEL_RCSID(0, $NetBSD: acpi_machdep.c,v 1.4 2011/06/12 10:11:52 jruoho Exp $);
 
 #include sys/param.h
 
@@ -186,20 +186,23 @@
 }
 
 uint32_t
-acpi_md_ncpus(void)
+acpi_md_pdc(void)
 {
+	return 0;
+}
 
+uint32_t
+acpi_md_ncpus(void)
+{
 	return 0;		/* XXX. */
 }
 
 void
 acpi_md_callback(void)
 {
-
-	/* nothing */
+	/* Nothing. */
 }
 
-
 int
 acpi_md_sleep(int state)
 {

Index: src/sys/arch/ia64/include/acpi_machdep.h
diff -u src/sys/arch/ia64/include/acpi_machdep.h:1.3 src/sys/arch/ia64/include/acpi_machdep.h:1.4
--- src/sys/arch/ia64/include/acpi_machdep.h:1.3	Thu Jan 13 03:40:50 2011
+++ src/sys/arch/ia64/include/acpi_machdep.h	Sun Jun 12 10:11:52 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_machdep.h,v 1.3 2011/01/13 03:40:50 jruoho Exp $	*/
+/*	$NetBSD: acpi_machdep.h,v 1.4 2011/06/12 10:11:52 jruoho Exp $	*/
 
 ACPI_STATUS acpi_md_OsInitialize(void);
 ACPI_STATUS acpi_md_OsTerminate(void);
@@ -27,5 +27,6 @@
 void		acpi_md_OsDisableInterrupt(void);
 
 int		acpi_md_sleep(int);
+uint32_t	acpi_md_pdc(void);
 uint32_t	acpi_md_ncpus(void);
 void		acpi_md_callback(void);

Index: src/sys/arch/x86/acpi/acpi_cpu_md.c
diff -u src/sys/arch/x86/acpi/acpi_cpu_md.c:1.60 src/sys/arch/x86/acpi/acpi_cpu_md.c:1.61
--- src/sys/arch/x86/acpi/acpi_cpu_md.c:1.60	Mon Jun  6 07:42:32 2011
+++ src/sys/arch/x86/acpi/acpi_cpu_md.c	Sun Jun 12 10:11:52 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: acpi_cpu_md.c,v 1.60 2011/06/06 07:42:32 jruoho Exp $ */
+/* $NetBSD: acpi_cpu_md.c,v 1.61 2011/06/12 10:11:52 jruoho Exp $ */
 
 /*-
  * Copyright (c) 2010, 2011 Jukka Ruohonen jruoho...@iki.fi
@@ -27,7 +27,7 @@
  * SUCH DAMAGE.
  */
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: acpi_cpu_md.c,v 1.60 2011/06/06 07:42:32 jruoho Exp $);
+__KERNEL_RCSID(0, $NetBSD: acpi_cpu_md.c,v 1.61 2011/06/12 10:11:52 jruoho Exp $);
 
 #include sys/param.h
 #include sys/bus.h
@@ -141,57 +141,6 @@
 }
 
 uint32_t
-acpicpu_md_cap(void)
-{
-	struct cpu_info *ci = curcpu();
-	uint32_t regs[4];
-	uint32_t val = 0;
-
-	if (cpu_vendor != CPUVENDOR_IDT 
-	cpu_vendor != CPUVENDOR_INTEL)
-		return val;
-
-	/*
-	 * Basic SMP C-states (required for e.g. _CST).
-	 */
-	val |= ACPICPU_PDC_C_C1PT | ACPICPU_PDC_C_C2C3;
-
-	/*
-	 * Claim to support dependency coordination.
-	 */
-	val |= ACPICPU_PDC_P_SW | ACPICPU_PDC_C_SW | ACPICPU_PDC_T_SW;
-
-/*
-	 * If MONITOR/MWAIT is available, announce
-	 * support for native instructions in all C-states.
-	 */
-if ((ci-ci_feat_val[1]  CPUID2_MONITOR) != 0)
-		val |= 

CVS commit: src/sys

2011-06-12 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jun 12 11:31:31 UTC 2011

Modified Files:
src/sys/arch/ia64/acpi: acpi_machdep.c
src/sys/arch/ia64/include: acpi_machdep.h
src/sys/arch/x86/conf: files.x86
src/sys/arch/x86/include: acpi_machdep.h
src/sys/dev/acpi/acpica: OsdEnvironment.c
Added Files:
src/sys/arch/x86/acpi: acpi_machdep.c
Removed Files:
src/sys/arch/x86/x86: acpi_machdep.c

Log Message:
Follow IA-64 with the x86-specific ACPI MD functions and move these where
they belong to. Remove an unused function. Minor KNF. No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/ia64/acpi/acpi_machdep.c
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/ia64/include/acpi_machdep.h
cvs rdiff -u -r0 -r1.1 src/sys/arch/x86/acpi/acpi_machdep.c
cvs rdiff -u -r1.70 -r1.71 src/sys/arch/x86/conf/files.x86
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/x86/include/acpi_machdep.h
cvs rdiff -u -r1.29 -r0 src/sys/arch/x86/x86/acpi_machdep.c
cvs rdiff -u -r1.5 -r1.6 src/sys/dev/acpi/acpica/OsdEnvironment.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/ia64/acpi/acpi_machdep.c
diff -u src/sys/arch/ia64/acpi/acpi_machdep.c:1.4 src/sys/arch/ia64/acpi/acpi_machdep.c:1.5
--- src/sys/arch/ia64/acpi/acpi_machdep.c:1.4	Sun Jun 12 10:11:52 2011
+++ src/sys/arch/ia64/acpi/acpi_machdep.c	Sun Jun 12 11:31:30 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_machdep.c,v 1.4 2011/06/12 10:11:52 jruoho Exp $	*/
+/*	$NetBSD: acpi_machdep.c,v 1.5 2011/06/12 11:31:30 jruoho Exp $	*/
 /*
  * Copyright (c) 2009 KIYOHARA Takashi
  * All rights reserved.
@@ -28,7 +28,7 @@
  * Machine-dependent routines for ACPICA.
  */
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: acpi_machdep.c,v 1.4 2011/06/12 10:11:52 jruoho Exp $);
+__KERNEL_RCSID(0, $NetBSD: acpi_machdep.c,v 1.5 2011/06/12 11:31:30 jruoho Exp $);
 
 #include sys/param.h
 
@@ -59,15 +59,6 @@
 	return AE_OK;
 }
 
-ACPI_STATUS
-acpi_md_OsTerminate(void)
-{
-
-	/* nothing to do. */
-printf(%s\n, __func__);
-	return AE_OK;
-}
-
 ACPI_PHYSICAL_ADDRESS
 acpi_md_OsGetRootPointer(void)
 {

Index: src/sys/arch/ia64/include/acpi_machdep.h
diff -u src/sys/arch/ia64/include/acpi_machdep.h:1.4 src/sys/arch/ia64/include/acpi_machdep.h:1.5
--- src/sys/arch/ia64/include/acpi_machdep.h:1.4	Sun Jun 12 10:11:52 2011
+++ src/sys/arch/ia64/include/acpi_machdep.h	Sun Jun 12 11:31:30 2011
@@ -1,8 +1,7 @@
-/*	$NetBSD: acpi_machdep.h,v 1.4 2011/06/12 10:11:52 jruoho Exp $	*/
+/*	$NetBSD: acpi_machdep.h,v 1.5 2011/06/12 11:31:30 jruoho Exp $	*/
 
-ACPI_STATUS acpi_md_OsInitialize(void);
-ACPI_STATUS acpi_md_OsTerminate(void);
-ACPI_PHYSICAL_ADDRESS acpi_md_OsGetRootPointer(void);
+ACPI_STATUS		acpi_md_OsInitialize(void);
+ACPI_PHYSICAL_ADDRESS	acpi_md_OsGetRootPointer(void);
 
 #define acpi_md_OsIn8(x)	inb((x))
 #define acpi_md_OsIn16(x)	inw((x))

Index: src/sys/arch/x86/conf/files.x86
diff -u src/sys/arch/x86/conf/files.x86:1.70 src/sys/arch/x86/conf/files.x86:1.71
--- src/sys/arch/x86/conf/files.x86:1.70	Sun Jun 12 10:11:52 2011
+++ src/sys/arch/x86/conf/files.x86	Sun Jun 12 11:31:31 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: files.x86,v 1.70 2011/06/12 10:11:52 jruoho Exp $
+#	$NetBSD: files.x86,v 1.71 2011/06/12 11:31:31 jruoho Exp $
 
 # options for MP configuration through the MP spec
 defflag opt_mpbios.h MPBIOS MPVERBOSE MPDEBUG MPBIOS_SCANPCI
@@ -105,10 +105,9 @@
 # MP configuration using ACPI
 file 	arch/x86/x86/mpacpi.c		acpi
 
-file	arch/x86/x86/acpi_machdep.c	acpi
-
 file	arch/x86/acpi/acpi_pdc.c	acpi
 file	arch/x86/acpi/acpi_wakeup.c	acpi
+file	arch/x86/acpi/acpi_machdep.c	acpi
 
 file	arch/x86/isa/isa_machdep.c	isa
 

Index: src/sys/arch/x86/include/acpi_machdep.h
diff -u src/sys/arch/x86/include/acpi_machdep.h:1.9 src/sys/arch/x86/include/acpi_machdep.h:1.10
--- src/sys/arch/x86/include/acpi_machdep.h:1.9	Sun Jun 12 10:11:52 2011
+++ src/sys/arch/x86/include/acpi_machdep.h	Sun Jun 12 11:31:31 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_machdep.h,v 1.9 2011/06/12 10:11:52 jruoho Exp $	*/
+/*	$NetBSD: acpi_machdep.h,v 1.10 2011/06/12 11:31:31 jruoho Exp $	*/
 
 /*
  * Copyright 2001 Wasabi Systems, Inc.
@@ -46,7 +46,6 @@
 #include machine/i82489reg.h
 
 ACPI_STATUS		acpi_md_OsInitialize(void);
-ACPI_STATUS		acpi_md_OsTerminate(void);
 ACPI_PHYSICAL_ADDRESS	acpi_md_OsGetRootPointer(void);
 
 #define	acpi_md_OsIn8(x)	inb((x))

Index: src/sys/dev/acpi/acpica/OsdEnvironment.c
diff -u src/sys/dev/acpi/acpica/OsdEnvironment.c:1.5 src/sys/dev/acpi/acpica/OsdEnvironment.c:1.6
--- src/sys/dev/acpi/acpica/OsdEnvironment.c:1.5	Sun Aug 23 15:16:16 2009
+++ src/sys/dev/acpi/acpica/OsdEnvironment.c	Sun Jun 12 11:31:31 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: OsdEnvironment.c,v 1.5 2009/08/23 15:16:16 jmcneill Exp $	*/
+/*	$NetBSD: OsdEnvironment.c,v 1.6 2011/06/12 11:31:31 jruoho Exp $	*/
 
 /*
  * Copyright 2001 Wasabi Systems, Inc.
@@ -42,7 

CVS commit: src/sys/arch/emips/emips

2011-06-12 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sun Jun 12 13:40:14 UTC 2011

Modified Files:
src/sys/arch/emips/emips: promcall.c

Log Message:
Some KNF.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/emips/emips/promcall.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/emips/emips/promcall.c
diff -u src/sys/arch/emips/emips/promcall.c:1.2 src/sys/arch/emips/emips/promcall.c:1.3
--- src/sys/arch/emips/emips/promcall.c:1.2	Tue Feb  8 20:20:11 2011
+++ src/sys/arch/emips/emips/promcall.c	Sun Jun 12 13:40:14 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: promcall.c,v 1.2 2011/02/08 20:20:11 rmind Exp $	*/
+/*	$NetBSD: promcall.c,v 1.3 2011/06/12 13:40:14 tsutsui Exp $	*/
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: promcall.c,v 1.2 2011/02/08 20:20:11 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: promcall.c,v 1.3 2011/06/12 13:40:14 tsutsui Exp $);
 
 #include sys/param.h
 #include sys/device.h
@@ -60,16 +60,19 @@
 static int  nogetsysid(void);
 static void nohalt(int *, int);
 
-/* Callback vector. We keep this fall-back copy jic the bootloader is broken.
+/*
+ * Callback vector. We keep this fall-back copy jic the bootloader is broken.
  */
 static void *nope(void)
 {
-return NULL;
+
+	return NULL;
 }
 
 static int  nogetchar(void)
 {
-return -1;
+
+	return -1;
 }
 
 static void noprintf(const char *fmt, ...)
@@ -78,56 +81,58 @@
 
 static int  nogetsysid(void)
 {
-/* say its an eMIPS, ML board */
-return MAKESYSID(1,1,XS_ML40x,MIPS_eMIPS);
+
+	/* say its an eMIPS, ML board */
+	return MAKESYSID(1, 1, XS_ML40x, MIPS_eMIPS);
 }
 
 static void nohalt(int *unused, int howto)
 {
-	while(1) ;	/* fool gcc */
+
+	while (1);	/* fool gcc */
 	/*NOTREACHED*/
 }
 
 const struct callback callvec = {
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
 	nogetchar,
-nope,
-nope,
+	nope,
+	nope,
 	noprintf,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
-nogetsysid,
-nope,
-nope,
-nope,
-nope,
-nope,
-nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nogetsysid,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
+	nope,
 	nohalt
 };
 
@@ -166,8 +171,7 @@
  * Print a character on PROM console.
  */
 static void
-romputc(dev_t dev,
-int c)
+romputc(dev_t dev, int c)
 {
 	int s;
 
@@ -186,7 +190,8 @@
 int
 prom_systype(void)
 {
-return (*callv-_getsysid)();
+
+	return (*callv-_getsysid)();
 }
 
 /*
@@ -195,8 +200,8 @@
 void __attribute__((__noreturn__))
 prom_halt(int howto)
 {
+
 	(*callv-_halt)((int *)0, howto);
 	while(1) ;	/* fool gcc */
 	/*NOTREACHED*/
 }
-



CVS commit: src/sys/arch/emips/ebus

2011-06-12 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sun Jun 12 14:31:31 UTC 2011

Modified Files:
src/sys/arch/emips/ebus: if_le_ebus.c

Log Message:
- misc KNF
- use device_t and cfdata_t


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/emips/ebus/if_le_ebus.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/emips/ebus/if_le_ebus.c
diff -u src/sys/arch/emips/ebus/if_le_ebus.c:1.1 src/sys/arch/emips/ebus/if_le_ebus.c:1.2
--- src/sys/arch/emips/ebus/if_le_ebus.c:1.1	Wed Jan 26 01:18:50 2011
+++ src/sys/arch/emips/ebus/if_le_ebus.c	Sun Jun 12 14:31:31 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_le_ebus.c,v 1.1 2011/01/26 01:18:50 pooka Exp $	*/
+/*	$NetBSD: if_le_ebus.c,v 1.2 2011/06/12 14:31:31 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: if_le_ebus.c,v 1.1 2011/01/26 01:18:50 pooka Exp $);
+__KERNEL_RCSID(0, $NetBSD: if_le_ebus.c,v 1.2 2011/06/12 14:31:31 tsutsui Exp $);
 
 #include opt_inet.h
 
@@ -71,8 +71,8 @@
 extern paddr_t kvtophys(vaddr_t);
 
 struct bufmap {
-struct mbuf *mbuf;
-paddr_t phys;
+	struct mbuf *mbuf;
+	paddr_t phys;
 };
 
 struct enic_softc {
@@ -80,40 +80,40 @@
 	struct	ethercom sc_ethercom;	/* Ethernet common part */
 	struct	ifmedia sc_media;	/* our supported media */
 
-struct _Enic *sc_regs;  /* hw registers */
+	struct _Enic *sc_regs;		/* hw registers */
 
-	int	sc_havecarrier;	/* carrier status */
-	void	*sc_sh;		/* shutdownhook cookie */
-int inited;
-
-int sc_no_rd;
-int sc_n_recv;
-int sc_recv_h;
-/* BUGBUG really should be malloc-ed */
+	int	sc_havecarrier;		/* carrier status */
+	void	*sc_sh;			/* shutdownhook cookie */
+	int inited;
+
+	int sc_no_rd;
+	int sc_n_recv;
+	int sc_recv_h;
+	/* BUGBUG really should be malloc-ed */
 #define SC_MAX_N_RECV 64
-struct bufmap sc_recv[SC_MAX_N_RECV];
+	struct bufmap sc_recv[SC_MAX_N_RECV];
 
-int sc_no_td;
-int sc_n_xmit;
-int sc_xmit_h;
-/* BUGBUG really should be malloc-ed */
+	int sc_no_td;
+	int sc_n_xmit;
+	int sc_xmit_h;
+	/* BUGBUG really should be malloc-ed */
 #define SC_MAX_N_XMIT 16
-struct bufmap sc_xmit[SC_MAX_N_XMIT];
+	struct bufmap sc_xmit[SC_MAX_N_XMIT];
 
 #if DEBUG
-int xhit;
-int xmiss;
-int tfull;
-int tfull2;
-int brh;
-int rf;
-int bxh;
+	int xhit;
+	int xmiss;
+	int tfull;
+	int tfull2;
+	int brh;
+	int rf;
+	int bxh;
 
-int it;
+	int it;
 #endif
 
-	u_int8_t sc_enaddr[ETHER_ADDR_LEN];
-	u_int8_t sc_pad[2];
+	uint8_t sc_enaddr[ETHER_ADDR_LEN];
+	uint8_t sc_pad[2];
 #if NRND  0
 	rndsource_element_t	rnd_source;
 #endif
@@ -121,44 +121,44 @@
 
 void enic_reset(struct ifnet *);
 int enic_init(struct ifnet *);
-void enic_stop(struct ifnet *ifp, int suspend);
-void enic_start(struct ifnet *ifp);
+void enic_stop(struct ifnet *, int);
+void enic_start(struct ifnet *);
 void enic_shutdown(void *);
-void enic_watchdog(struct ifnet *ifp);
-int enic_mediachange(struct ifnet *ifp);
-void enic_mediastatus(struct ifnet *ifp, struct ifmediareq *ifmr);
-int enic_ioctl(struct ifnet *ifp, u_long cmd, void *data);
-int enic_intr(void *cookie, void *f);
+void enic_watchdog(struct ifnet *);
+int enic_mediachange(struct ifnet *);
+void enic_mediastatus(struct ifnet *, struct ifmediareq *);
+int enic_ioctl(struct ifnet *, u_long, void *);
+int enic_intr(void *, void *);
 void enic_rint(struct enic_softc *, uint32_t, paddr_t);
 void enic_tint(struct enic_softc *, uint32_t, paddr_t);
-void enic_kill_xmit(struct enic_softc *sc);
-void enic_post_recv(struct enic_softc *sc, struct mbuf *m);
-void enic_refill(struct enic_softc *sc);
-static int enic_gethwinfo(struct enic_softc *sc);
-int enic_put(struct enic_softc *sc, struct mbuf **pm);
+void enic_kill_xmit(struct enic_softc *);
+void enic_post_recv(struct enic_softc *, struct mbuf *);
+void enic_refill(struct enic_softc *);
+static int enic_gethwinfo(struct enic_softc *);
+int enic_put(struct enic_softc *, struct mbuf **);
 
-static int enic_match(struct device *, struct cfdata *, void *);
-static void enic_attach(struct device *, struct device *, void *);
+static int enic_match(device_t, cfdata_t, void *);
+static void enic_attach(device_t, device_t, void *);
 
 CFATTACH_DECL_NEW(enic_emips, sizeof(struct enic_softc),
 enic_match, enic_attach, NULL, NULL);
 
 int
-enic_match(struct device *parent, struct cfdata *match, void *aux)
+enic_match(device_t parent, cfdata_t cf, void *aux)
 {
 	struct ebus_attach_args *d = aux;
 	/* donno yet */
 	struct _Enic *et = (struct _Enic *)d-ia_vaddr;
 
 	if (strcmp(enic, d-ia_name) != 0)
-		return (0);
+		return 0;
 	if ((et == NULL) || (et-Tag != PMTTAG_ETHERNET))
 		return 0;
-	return (1);
+	return 1;
 }
 
 void
-enic_attach(struct device *parent, struct device *self, void *aux)
+enic_attach(device_t parent, device_t 

CVS commit: src/external/cddl/osnet/dist/uts/common/fs/zfs

2011-06-12 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun Jun 12 14:47:20 UTC 2011

Modified Files:
src/external/cddl/osnet/dist/uts/common/fs/zfs: zfs_znode.c

Log Message:
Fix ZFS build.


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 \
src/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c

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

Modified files:

Index: src/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c
diff -u src/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c:1.10 src/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c:1.11
--- src/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c:1.10	Thu Mar 10 19:32:39 2011
+++ src/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c	Sun Jun 12 14:47:20 2011
@@ -485,7 +485,11 @@
 
 	vp = ZTOV(sharezp);
 	error = getnewvnode(VT_ZFS, zfsvfs-z_parent-z_vfs,
-	zfs_vnodeop_p, sharezp-z_vnode);
+	zfs_vnodeop_p, NULL, sharezp-z_vnode);
+	if (error) {
+		kmem_cache_free(znode_cache, sharezp);
+		return error;
+	}
 	vp-v_type = VDIR;
 
 	VERIFY(0 == zfs_acl_ids_create(sharezp, IS_ROOT_NODE, vattr,
@@ -617,7 +621,7 @@
 	for (;;) {
 
 		error = getnewvnode(VT_ZFS, zfsvfs-z_parent-z_vfs,
-		zfs_vnodeop_p, zp-z_vnode);
+		zfs_vnodeop_p, NULL, zp-z_vnode);
 		if (__predict_true(error == 0))
 			break;
 		printf(WARNING: zfs_znode_alloc: unable to get vnode, 
@@ -1556,7 +1560,7 @@
 
 	for (;;) {
 		error = getnewvnode(VT_ZFS, NULL, zfs_vnodeop_p,
-		rootzp-z_vnode);
+		NULL, rootzp-z_vnode);
 		if (error == 0)
 			break;
 		printf(WARNING: zfs_create_fs: unable to get vnode, 



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

2011-06-12 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Jun 12 16:15:42 UTC 2011

Modified Files:
src/crypto/external/bsd/openssl/dist/crypto/idea: ideatest.c
src/crypto/external/bsd/openssl/dist/crypto/mdc2: mdc2test.c

Log Message:
fix warnings for the patented algos


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.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/openssl/dist/crypto/idea/ideatest.c
diff -u src/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c:1.1.1.1 src/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c:1.2
--- src/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c:1.1.1.1	Sun Jul 19 19:04:11 2009
+++ src/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c	Sun Jun 12 12:15:42 2011
@@ -79,7 +79,7 @@
 unsigned char  c[8]={0x11,0xFB,0xED,0x2B,0x01,0x98,0x6D,0xE5};
 unsigned char out[80];
 
-char *text=Hello to all people out there;
+const char *text=Hello to all people out there;
 
 static unsigned char cfb_key[16]={
 	0xe1,0xf0,0xc3,0xd2,0xa5,0xb4,0x87,0x96,
@@ -148,7 +148,7 @@
 	if (err == 0) printf(ecb idea ok\n);
 
 	memcpy(iv,k,8);
-	idea_cbc_encrypt((unsigned char *)text,out,strlen(text)+1,key,iv,1);
+	idea_cbc_encrypt((const unsigned char *)text,out,strlen(text)+1,key,iv,1);
 	memcpy(iv,k,8);
 	idea_cbc_encrypt(out,out,8,dkey,iv,0);
 	idea_cbc_encrypt((out[8]),(out[8]),strlen(text)+1-8,dkey,iv,0);
@@ -220,7 +220,7 @@
 	static int bnum=0;
 	char *ret;
 	int i;
-	static char *f=0123456789ABCDEF;
+	static const char *f=0123456789ABCDEF;
 
 	ret= (bufs[bnum++][0]);
 	bnum%=10;

Index: src/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c
diff -u src/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c:1.1.1.1 src/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c:1.2
--- src/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c:1.1.1.1	Sun Jul 19 19:04:14 2009
+++ src/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c	Sun Jun 12 12:15:42 2011
@@ -96,7 +96,7 @@
 	unsigned char md[MDC2_DIGEST_LENGTH];
 	int i;
 	EVP_MD_CTX c;
-	static char *text=Now is the time for all ;
+	static const char *text=Now is the time for all ;
 
 #ifdef CHARSET_EBCDIC
 	ebcdic2ascii(text,text,strlen(text));
@@ -104,7 +104,7 @@
 
 	EVP_MD_CTX_init(c);
 	EVP_DigestInit_ex(c,EVP_mdc2(), NULL);
-	EVP_DigestUpdate(c,(unsigned char *)text,strlen(text));
+	EVP_DigestUpdate(c,(const unsigned char *)text,strlen(text));
 	EVP_DigestFinal_ex(c,(md[0]),NULL);
 
 	if (memcmp(md,pad1,MDC2_DIGEST_LENGTH) != 0)
@@ -123,7 +123,7 @@
 	EVP_DigestInit_ex(c,EVP_mdc2(), NULL);
 	/* FIXME: use a ctl function? */
 	((MDC2_CTX *)c.md_data)-pad_type=2;
-	EVP_DigestUpdate(c,(unsigned char *)text,strlen(text));
+	EVP_DigestUpdate(c,(const unsigned char *)text,strlen(text));
 	EVP_DigestFinal_ex(c,(md[0]),NULL);
 
 	if (memcmp(md,pad2,MDC2_DIGEST_LENGTH) != 0)



CVS commit: src/tests/crypto/libcrypto

2011-06-12 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Jun 12 16:16:27 UTC 2011

Modified Files:
src/tests/crypto/libcrypto/idea: Makefile
src/tests/crypto/libcrypto/mdc2: Makefile
src/tests/crypto/libcrypto/rc5: Makefile

Log Message:
Fix patented algo compilation


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/tests/crypto/libcrypto/idea/Makefile
cvs rdiff -u -r1.1 -r1.2 src/tests/crypto/libcrypto/mdc2/Makefile
cvs rdiff -u -r1.1 -r1.2 src/tests/crypto/libcrypto/rc5/Makefile

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

Modified files:

Index: src/tests/crypto/libcrypto/idea/Makefile
diff -u src/tests/crypto/libcrypto/idea/Makefile:1.1 src/tests/crypto/libcrypto/idea/Makefile:1.2
--- src/tests/crypto/libcrypto/idea/Makefile:1.1	Fri Feb 13 15:58:15 2009
+++ src/tests/crypto/libcrypto/idea/Makefile	Sun Jun 12 12:16:26 2011
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.1 2009/02/13 20:58:15 jmmv Exp $
+# $NetBSD: Makefile,v 1.2 2011/06/12 16:16:26 christos Exp $
 
 HELPER_NAME=	ideatest
 HELPER_DIR=	idea
 
-LDADD+=		-lcrypto_idea
+LDADD+=		-Wl,--no-fatal-warnings
 
 .include bsd.init.mk

Index: src/tests/crypto/libcrypto/mdc2/Makefile
diff -u src/tests/crypto/libcrypto/mdc2/Makefile:1.1 src/tests/crypto/libcrypto/mdc2/Makefile:1.2
--- src/tests/crypto/libcrypto/mdc2/Makefile:1.1	Fri Feb 13 15:58:15 2009
+++ src/tests/crypto/libcrypto/mdc2/Makefile	Sun Jun 12 12:16:26 2011
@@ -1,9 +1,6 @@
-# $NetBSD: Makefile,v 1.1 2009/02/13 20:58:15 jmmv Exp $
+# $NetBSD: Makefile,v 1.2 2011/06/12 16:16:26 christos Exp $
 
 HELPER_NAME=	mdc2test
 HELPER_DIR=	mdc2
 
-LDADD+=		-lcrypto_mdc2
-DPADD+=		${LIBCRYPTO_MDC2}
-
 .include bsd.init.mk

Index: src/tests/crypto/libcrypto/rc5/Makefile
diff -u src/tests/crypto/libcrypto/rc5/Makefile:1.1 src/tests/crypto/libcrypto/rc5/Makefile:1.2
--- src/tests/crypto/libcrypto/rc5/Makefile:1.1	Fri Feb 13 15:58:15 2009
+++ src/tests/crypto/libcrypto/rc5/Makefile	Sun Jun 12 12:16:27 2011
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.1 2009/02/13 20:58:15 jmmv Exp $
+# $NetBSD: Makefile,v 1.2 2011/06/12 16:16:27 christos Exp $
 
 HELPER_NAME=	rc5test
 HELPER_DIR=	rc5
 
-LDADD+=		-lcrypto_rc5
+LDADD+=		-Wl,--no-fatal-warnings
 
 .include bsd.init.mk



CVS commit: src/sys/arch/powerpc/include

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 16:27:14 UTC 2011

Modified Files:
src/sys/arch/powerpc/include: cpu.h

Log Message:
Use mfsprg0 instead of mfsprg r,0


To generate a diff of this commit:
cvs rdiff -u -r1.77 -r1.78 src/sys/arch/powerpc/include/cpu.h

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

Modified files:

Index: src/sys/arch/powerpc/include/cpu.h
diff -u src/sys/arch/powerpc/include/cpu.h:1.77 src/sys/arch/powerpc/include/cpu.h:1.78
--- src/sys/arch/powerpc/include/cpu.h:1.77	Sun Jun  5 16:52:25 2011
+++ src/sys/arch/powerpc/include/cpu.h	Sun Jun 12 16:27:14 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: cpu.h,v 1.77 2011/06/05 16:52:25 matt Exp $	*/
+/*	$NetBSD: cpu.h,v 1.78 2011/06/12 16:27:14 matt Exp $	*/
 
 /*
  * Copyright (C) 1999 Wolfgang Solfrank.
@@ -203,7 +203,7 @@
 {
 	struct cpu_info *ci;
 
-	__asm volatile (mfsprg %0,0 : =r(ci));
+	__asm volatile (mfsprg0 %0 : =r(ci));
 	return ci;
 }
 



CVS commit: src/sys/arch/powerpc/oea

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 16:27:52 UTC 2011

Modified Files:
src/sys/arch/powerpc/oea: cpu_subr.c

Log Message:
Use mtsprg0 instead of mtsprg 0,r


To generate a diff of this commit:
cvs rdiff -u -r1.63 -r1.64 src/sys/arch/powerpc/oea/cpu_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/sys/arch/powerpc/oea/cpu_subr.c
diff -u src/sys/arch/powerpc/oea/cpu_subr.c:1.63 src/sys/arch/powerpc/oea/cpu_subr.c:1.64
--- src/sys/arch/powerpc/oea/cpu_subr.c:1.63	Sun Jun  5 16:52:25 2011
+++ src/sys/arch/powerpc/oea/cpu_subr.c	Sun Jun 12 16:27:52 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: cpu_subr.c,v 1.63 2011/06/05 16:52:25 matt Exp $	*/
+/*	$NetBSD: cpu_subr.c,v 1.64 2011/06/12 16:27:52 matt Exp $	*/
 
 /*-
  * Copyright (c) 2001 Matt Thomas.
@@ -34,7 +34,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: cpu_subr.c,v 1.63 2011/06/05 16:52:25 matt Exp $);
+__KERNEL_RCSID(0, $NetBSD: cpu_subr.c,v 1.64 2011/06/12 16:27:52 matt Exp $);
 
 #include opt_ppcparam.h
 #include opt_multiprocessor.h
@@ -1295,7 +1295,7 @@
 	if (msr != h-pir)
 		mtspr(SPR_PIR, h-pir);
 	
-	__asm volatile (mtsprg 0,%0 :: r(ci));
+	__asm volatile (mtsprg0 %0 :: r(ci));
 	cpu_spinstart_ack = 0;
 
 	/* Initialize MMU. */



CVS commit: src/sys/arch/xen/conf

2011-06-12 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jun 12 16:31:57 UTC 2011

Modified Files:
src/sys/arch/xen/conf: files.xen

Log Message:
Fix build failure for the odd child, as pointed out by pgoyette@.


To generate a diff of this commit:
cvs rdiff -u -r1.119 -r1.120 src/sys/arch/xen/conf/files.xen

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/conf/files.xen
diff -u src/sys/arch/xen/conf/files.xen:1.119 src/sys/arch/xen/conf/files.xen:1.120
--- src/sys/arch/xen/conf/files.xen:1.119	Sun Jun 12 03:35:50 2011
+++ src/sys/arch/xen/conf/files.xen	Sun Jun 12 16:31:57 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: files.xen,v 1.119 2011/06/12 03:35:50 rmind Exp $
+#	$NetBSD: files.xen,v 1.120 2011/06/12 16:31:57 jruoho Exp $
 #	NetBSD: files.x86,v 1.10 2003/10/08 17:30:00 bouyer Exp 
 #	NetBSD: files.i386,v 1.254 2004/03/25 23:32:10 jmc Exp 
 
@@ -257,7 +257,6 @@
 include dev/acpi/files.acpi
 file	arch/xen/xen/xen_acpi_machdep.c	acpi
 file	arch/x86/x86/mpacpi.c		acpi
-file	arch/x86/x86/acpi_machdep.c	acpi
 file	arch/x86/x86/i8259.c
 
 # Stubs for x86 routines not included in the system
@@ -275,6 +274,8 @@
 file	arch/x86/x86/apic.c		ioapic
 file	arch/x86/x86/nmi.c
 
+file	arch/x86/acpi/acpi_machdep.c	acpi
+
 device ioapic
 attach ioapic at ioapicbus
 file	arch/x86/x86/ioapic.c		ioapic needs-flag



CVS commit: src/sys/arch/powerpc/oea

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 16:35:10 UTC 2011

Modified Files:
src/sys/arch/powerpc/oea: ofw_subr.S ofwoea_machdep.c

Log Message:
Save/restore all sprgs when calling OFW.
Move all-zero variables from .data to .bss
Use .lcomm for local variables.
Cleanup a bit of assembly.
Clear PSL_IP in the saved ofmsr (was previously done in ofwoea_machdep.c)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/powerpc/oea/ofw_subr.S
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/powerpc/oea/ofwoea_machdep.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/powerpc/oea/ofw_subr.S
diff -u src/sys/arch/powerpc/oea/ofw_subr.S:1.8 src/sys/arch/powerpc/oea/ofw_subr.S:1.9
--- src/sys/arch/powerpc/oea/ofw_subr.S:1.8	Tue Apr  8 02:33:03 2008
+++ src/sys/arch/powerpc/oea/ofw_subr.S	Sun Jun 12 16:35:10 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: ofw_subr.S,v 1.8 2008/04/08 02:33:03 garbled Exp $	*/
+/*	$NetBSD: ofw_subr.S,v 1.9 2011/06/12 16:35:10 matt Exp $	*/
 
 /*
  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
@@ -37,20 +37,12 @@
 	.local	ofwsrsave
 	.local	OF_buffer
 
-	.data
-GLOBAL(ofmsr)
-	.long	0,0,0,0,0		/* msr  sprg[0-3] used in OF */
-
-GLOBAL(ofwsprg0save)
-	.long	0
-
-GLOBAL(ofwreal_incharge)
-	.long	0
-
-	.comm	firmstk,NBPG,8
-	.comm	OF_buffer,NBPG,4
+	.lcomm	firmstk,NBPG,16
+	.lcomm	OF_buffer,NBPG,4
 	.comm	openfirmware_entry,4,4	/* openfirmware entry point */
-	.comm	ofwsrsave,64,4		/* openfirmware SR savearea */
+	.lcomm	ofwsrsave,64,4		/* openfirmware SR savearea */
+	.lcomm	ofwmsr,20,4		/* msr  sprg[0-3] used in OF */
+	.comm	ofwreal_incharge,4,4
 
 /*
  * Called by start to save the initial OFW state so we can restore it
@@ -64,7 +56,7 @@
 
 	li	%r8,1
 	lis	%r9,ofwreal_incharge@ha
-	stw	%r8,ofwreal_incharge@l(9)
+	stw	%r8,ofwreal_incharge@l(%r9)
 
 	mflr	%r30
 	bl	_C_LABEL(ofwr_init)
@@ -75,17 +67,19 @@
 	stw	%r5,openfirmware_entry@l(%r8) /* save client interface handler*/
 
 	mfmsr	%r0
-	lis	%r9,ofmsr@ha
-	stwu	%r0,ofmsr@l(%r9)		/* save initial MSR value */
-
-mfsprg  %r0,0			/* save SPRGs */
-   	stwu	%r0,4(%r9)
-mfsprg  %r0,1
-   	stwu	%r0,4(%r9)
-mfsprg  %r0,2
-   	stwu	%r0,4(%r9)
-mfsprg  %r0,3
-   	stw	%r0,4(%r9)
+	li	%r8,PSL_IP
+	andc	%r0,%r0,%r8			/* make sure PSL_IP is off */
+	lis	%r9,ofwmsr@ha
+	stwu	%r0,ofwmsr@l(%r9)		/* save initial MSR value */
+
+	mfsprg0	%r0/* save SPRGs */
+	stw	%r0,4(%r9)
+	mfsprg1	%r0
+	stw	%r0,8(%r9)
+	mfsprg2	%r0
+	stw	%r0,12(%r9)
+	mfsprg3	%r0
+	stw	%r0,16(%r9)
 
 	lis	%r8,OF_buffer@ha
 	addi	%r8,%r8,OF_buffer@l
@@ -101,16 +95,20 @@
 ENTRY(openfirmware)
 	mflr	%r0			/* save return address */
 	stw	%r0,4(%r1)
-	stwu	%r1,-16(%r1)		/* setup stack frame */
+	stwu	%r1,-32(%r1)		/* setup stack frame */
 
 	lis	%r4,openfirmware_entry@ha	/* get firmware entry point */
 	lwz	%r4,openfirmware_entry@l(%r4)
 	mtlr	%r4
 
-	mfsprg	%r5,0			/* save current sprg0 (curcpu) */
-	lis	%r4,ofwsprg0save@ha
-	addi	%r4,%r4,ofwsprg0save@l
-	stw	%r5,0(%r4)
+	mfsprg0	%r5			/* save current sprg0 (curcpu) */
+	stw	%r5,16(%r1)
+	mfsprg1	%r5			/* save current sprg1 */
+	stw	%r5,20(%r1)
+	mfsprg2	%r5			/* save current sprg1 */
+	stw	%r5,24(%r1)
+	mfsprg3	%r5			/* save current sprg3 */
+	stw	%r5,28(%r1)
 
 #ifdef FIRMWORKSBUGS
 	lis	%r4,ofwreal_incharge@ha
@@ -156,16 +154,16 @@
 	cmpwi	%r5,0
 	bne	1b
 2:
-	lis	%r4,ofmsr@ha		/* Open Firmware msr + sprg[0-3] */
-	lwzu	%r5,ofmsr+16@l(%r4)
-	mtsprg	3,%r5
-	lwzu	%r5,-4(%r4)
-	mtsprg	2,%r5
-	lwzu	%r5,-4(%r4)
-	mtsprg	1,%r5
-	lwzu	%r5,-4(%r4)
-	mtsprg	0,%r5
+	lis	%r4,ofwmsr+16@ha	/* Open Firmware msr + sprg[0-3] */
+	lwzu	%r5,ofwmsr+16@l(%r4)
+	mtsprg3	%r5
 	lwz	%r5,-4(%r4)
+	mtsprg2	%r5
+	lwz	%r5,-8(%r4)
+	mtsprg1	%r5
+	lwz	%r5,-12(%r4)
+	mtsprg0	%r5
+	lwz	%r5,-16(%r4)
 	mtmsr	%r5
 	isync
 
@@ -185,10 +183,14 @@
 	mtmsr	%r4
 	isync
 4:	
-	lis	%r4,ofwsprg0save@ha	/* restore saved sprg0 (curcpu) */
-	addi	%r4,%r4,ofwsprg0save@l
-	lwz	%r5,0(%r4)
-	mtsprg	0,%r5
+	lwz	%r5,16(%r1)		/* restore saved sprgs (curcpu) */
+	mtsprg0	%r5
+	lwz	%r5,20(%r1)
+	mtsprg1	%r5
+	lwz	%r5,24(%r1)
+	mtsprg2	%r5
+	lwz	%r5,28(%r1)
+	mtsprg3	%r5
 
 	lwz	%r1,0(%r1)		/* and return */
 	lwz	%r0,4(%r1)

Index: src/sys/arch/powerpc/oea/ofwoea_machdep.c
diff -u src/sys/arch/powerpc/oea/ofwoea_machdep.c:1.20 src/sys/arch/powerpc/oea/ofwoea_machdep.c:1.21
--- src/sys/arch/powerpc/oea/ofwoea_machdep.c:1.20	Sun Mar 14 10:03:49 2010
+++ src/sys/arch/powerpc/oea/ofwoea_machdep.c	Sun Jun 12 16:35:10 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: ofwoea_machdep.c,v 1.20 2010/03/14 10:03:49 kiyohara Exp $ */
+/* $NetBSD: ofwoea_machdep.c,v 1.21 2011/06/12 16:35:10 matt Exp $ */
 
 /*-
  * Copyright (c) 2007 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: ofwoea_machdep.c,v 1.20 2010/03/14 10:03:49 kiyohara Exp $);
+__KERNEL_RCSID(0, $NetBSD: 

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

2011-06-12 Thread Iain Hibbert
Module Name:src
Committed By:   plunky
Date:   Sun Jun 12 19:22:02 UTC 2011

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

Log Message:
don't pass -fstack-protector for these, the tests are actually for the
__*_chk functions included by -D_FORTIFY_SOURCE=2, and if the compiler
provides additional protection, it can mask broken functions..

(none of the _chk functions will return or process any data if
the length given is known to be larger than the buffer)


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

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

Modified files:

Index: src/tests/lib/libc/ssp/Makefile
diff -u src/tests/lib/libc/ssp/Makefile:1.2 src/tests/lib/libc/ssp/Makefile:1.3
--- src/tests/lib/libc/ssp/Makefile:1.2	Sat Feb 26 02:41:33 2011
+++ src/tests/lib/libc/ssp/Makefile	Sun Jun 12 19:22:01 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.2 2011/02/26 02:41:33 pgoyette Exp $
+# $NetBSD: Makefile,v 1.3 2011/06/12 19:22:01 plunky Exp $
 
 NOMAN=		# defined
 
@@ -7,8 +7,6 @@
 WARNS=	4
 
 CPPFLAGS+=	-D_FORTIFY_SOURCE=2
-CFLAGS+=	-fstack-protector-all -Wstack-protector
-LDFLAGS+=	-fstack-protector-all -Wstack-protector
 
 # Bootstrap hack
 



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

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 20:23:29 UTC 2011

Modified Files:
src/distrib/sets/lists/comp: ad.mips64eb ad.mips64el

Log Message:
Cleanup for libsl.so.5 changes


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/distrib/sets/lists/comp/ad.mips64eb \
src/distrib/sets/lists/comp/ad.mips64el

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

Modified files:

Index: src/distrib/sets/lists/comp/ad.mips64eb
diff -u src/distrib/sets/lists/comp/ad.mips64eb:1.34 src/distrib/sets/lists/comp/ad.mips64eb:1.35
--- src/distrib/sets/lists/comp/ad.mips64eb:1.34	Mon Jun  6 16:16:00 2011
+++ src/distrib/sets/lists/comp/ad.mips64eb	Sun Jun 12 20:23:29 2011
@@ -1,4 +1,4 @@
-# $NetBSD: ad.mips64eb,v 1.34 2011/06/06 16:16:00 njoly Exp $
+# $NetBSD: ad.mips64eb,v 1.35 2011/06/12 20:23:29 matt Exp $
 ./usr/bin/elf2aoutcomp-obsolete		obsolete
 ./usr/bin/elf2ecoffcomp-sysutil-bin
 ./usr/include/mipscomp-c-include
@@ -1359,7 +1359,7 @@
 #./usr/libdata/debug/usr/lib/64/librumpvfs_layerfs.so.0.0.debug	comp-rump-debug	debug,compat
 ./usr/libdata/debug/usr/lib/64/libsaslc.so.0.0.debug	comp-sys-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/64/libskey.so.2.0.debug	comp-sys-debug	skey,debug,compat
-./usr/libdata/debug/usr/lib/64/libsl.so.4.0.debug		comp-krb5-debug	kerberos,debug,compat
+./usr/libdata/debug/usr/lib/64/libsl.so.5.0.debug		comp-krb5-debug	kerberos,debug,compat
 ./usr/libdata/debug/usr/lib/64/libss.so.6.0.debug		comp-krb5-debug	obsolete
 ./usr/libdata/debug/usr/lib/64/libssh.so.16.0.debug	comp-secsh-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/64/libssl.so.8.2.debug		comp-crypto-debug	crypto,debug,compat
@@ -1566,7 +1566,7 @@
 #./usr/libdata/debug/usr/lib/o32/librumpvfs_layerfs.so.0.0.debug	comp-rump-debug	debug,compat
 ./usr/libdata/debug/usr/lib/o32/libsaslc.so.0.0.debug	comp-sys-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/o32/libskey.so.2.0.debug	comp-sys-debug	skey,debug,compat
-./usr/libdata/debug/usr/lib/o32/libsl.so.4.0.debug		comp-krb5-debug	kerberos,debug,compat
+./usr/libdata/debug/usr/lib/o32/libsl.so.5.0.debug		comp-krb5-debug	kerberos,debug,compat
 ./usr/libdata/debug/usr/lib/o32/libss.so.6.0.debug		comp-krb5-debug	obsolete
 ./usr/libdata/debug/usr/lib/o32/libssh.so.16.0.debug	comp-secsh-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/o32/libssl.so.8.2.debug		comp-crypto-debug	crypto,debug,compat
Index: src/distrib/sets/lists/comp/ad.mips64el
diff -u src/distrib/sets/lists/comp/ad.mips64el:1.34 src/distrib/sets/lists/comp/ad.mips64el:1.35
--- src/distrib/sets/lists/comp/ad.mips64el:1.34	Mon Jun  6 16:16:00 2011
+++ src/distrib/sets/lists/comp/ad.mips64el	Sun Jun 12 20:23:29 2011
@@ -1,4 +1,4 @@
-# $NetBSD: ad.mips64el,v 1.34 2011/06/06 16:16:00 njoly Exp $
+# $NetBSD: ad.mips64el,v 1.35 2011/06/12 20:23:29 matt Exp $
 ./usr/bin/elf2aoutcomp-obsolete		obsolete
 ./usr/bin/elf2ecoffcomp-sysutil-bin
 ./usr/include/mipscomp-c-include
@@ -1359,7 +1359,7 @@
 #./usr/libdata/debug/usr/lib/64/librumpvfs_layerfs.so.0.0.debug	comp-rump-debug	debug,compat
 ./usr/libdata/debug/usr/lib/64/libsaslc.so.0.0.debug	comp-sys-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/64/libskey.so.2.0.debug	comp-sys-debug	skey,debug,compat
-./usr/libdata/debug/usr/lib/64/libsl.so.4.0.debug		comp-krb5-debug	kerberos,debug,compat
+./usr/libdata/debug/usr/lib/64/libsl.so.5.0.debug		comp-krb5-debug	kerberos,debug,compat
 ./usr/libdata/debug/usr/lib/64/libss.so.6.0.debug		comp-krb5-debug	obsolete
 ./usr/libdata/debug/usr/lib/64/libssh.so.16.0.debug	comp-secsh-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/64/libssl.so.8.2.debug		comp-crypto-debug	crypto,debug,compat
@@ -1566,7 +1566,7 @@
 #./usr/libdata/debug/usr/lib/o32/librumpvfs_layerfs.so.0.0.debug	comp-rump-debug	debug,compat
 ./usr/libdata/debug/usr/lib/o32/libsaslc.so.0.0.debug	comp-sys-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/o32/libskey.so.2.0.debug	comp-sys-debug	skey,debug,compat
-./usr/libdata/debug/usr/lib/o32/libsl.so.4.0.debug		comp-krb5-debug	kerberos,debug,compat
+./usr/libdata/debug/usr/lib/o32/libsl.so.5.0.debug		comp-krb5-debug	kerberos,debug,compat
 ./usr/libdata/debug/usr/lib/o32/libss.so.6.0.debug		comp-krb5-debug	obsolete
 ./usr/libdata/debug/usr/lib/o32/libssh.so.16.0.debug	comp-secsh-debug	crypto,debug,compat
 ./usr/libdata/debug/usr/lib/o32/libssl.so.8.2.debug		comp-crypto-debug	crypto,debug,compat



CVS commit: src/lib/libc/arch/i386/stdlib

2011-06-12 Thread Iain Hibbert
Module Name:src
Committed By:   plunky
Date:   Sun Jun 12 20:29:26 UTC 2011

Modified Files:
src/lib/libc/arch/i386/stdlib: div.S ldiv.S

Log Message:
Functions that return a struct or union, must set %eax to the value
of the original address of the callers area before it returns.

(System V ABI, i386 supplement, fourth edition, page 3-14)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/arch/i386/stdlib/div.S \
src/lib/libc/arch/i386/stdlib/ldiv.S

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

Modified files:

Index: src/lib/libc/arch/i386/stdlib/div.S
diff -u src/lib/libc/arch/i386/stdlib/div.S:1.8 src/lib/libc/arch/i386/stdlib/div.S:1.9
--- src/lib/libc/arch/i386/stdlib/div.S:1.8	Sat Jul 26 19:24:33 2003
+++ src/lib/libc/arch/i386/stdlib/div.S	Sun Jun 12 20:29:25 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: div.S,v 1.8 2003/07/26 19:24:33 salo Exp $	*/
+/*	$NetBSD: div.S,v 1.9 2011/06/12 20:29:25 plunky Exp $	*/
 /*
  * Written by J.T. Conklin j...@netbsd.org.
  * Public domain.
@@ -7,7 +7,7 @@
 #include machine/asm.h
 
 #if defined(LIBC_SCCS)
-RCSID($NetBSD: div.S,v 1.8 2003/07/26 19:24:33 salo Exp $)
+RCSID($NetBSD: div.S,v 1.9 2011/06/12 20:29:25 plunky Exp $)
 #endif
 
 ENTRY(div)
@@ -19,5 +19,6 @@
 	idiv	%ecx
 	movl	%eax,(%ebx)
 	movl	%edx,4(%ebx)
+	movl	%ebx,%eax
 	popl	%ebx
 	ret	$4
Index: src/lib/libc/arch/i386/stdlib/ldiv.S
diff -u src/lib/libc/arch/i386/stdlib/ldiv.S:1.8 src/lib/libc/arch/i386/stdlib/ldiv.S:1.9
--- src/lib/libc/arch/i386/stdlib/ldiv.S:1.8	Sat Jul 26 19:24:33 2003
+++ src/lib/libc/arch/i386/stdlib/ldiv.S	Sun Jun 12 20:29:25 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: ldiv.S,v 1.8 2003/07/26 19:24:33 salo Exp $	*/
+/*	$NetBSD: ldiv.S,v 1.9 2011/06/12 20:29:25 plunky Exp $	*/
 /*
  * Written by J.T. Conklin j...@netbsd.org.
  * Public domain.
@@ -7,7 +7,7 @@
 #include machine/asm.h
 
 #if defined(LIBC_SCCS)
-RCSID($NetBSD: ldiv.S,v 1.8 2003/07/26 19:24:33 salo Exp $)
+RCSID($NetBSD: ldiv.S,v 1.9 2011/06/12 20:29:25 plunky Exp $)
 #endif
 
 ENTRY(ldiv)
@@ -19,5 +19,6 @@
 	idiv	%ecx
 	movl	%eax,(%ebx)
 	movl	%edx,4(%ebx)
+	movl	%ebx,%eax
 	popl	%ebx
 	ret	$4



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

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 20:38:10 UTC 2011

Modified Files:
src/sys/arch/powerpc/powerpc: process_machdep.c

Log Message:
Change KASSERT to KASSERTMSG.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/sys/arch/powerpc/powerpc/process_machdep.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/powerpc/powerpc/process_machdep.c
diff -u src/sys/arch/powerpc/powerpc/process_machdep.c:1.31 src/sys/arch/powerpc/powerpc/process_machdep.c:1.32
--- src/sys/arch/powerpc/powerpc/process_machdep.c:1.31	Mon May  2 02:01:33 2011
+++ src/sys/arch/powerpc/powerpc/process_machdep.c	Sun Jun 12 20:38:10 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: process_machdep.c,v 1.31 2011/05/02 02:01:33 matt Exp $	*/
+/*	$NetBSD: process_machdep.c,v 1.32 2011/06/12 20:38:10 matt Exp $	*/
 
 /*
  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
@@ -32,7 +32,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: process_machdep.c,v 1.31 2011/05/02 02:01:33 matt Exp $);
+__KERNEL_RCSID(0, $NetBSD: process_machdep.c,v 1.32 2011/06/12 20:38:10 matt Exp $);
 
 #include opt_altivec.h
 
@@ -89,7 +89,8 @@
 		memset(fpregs, 0, sizeof (*fpregs));
 #ifdef PPC_HAVE_FPU
 	} else {
-		KASSERT(l == curlwp);
+		KASSERTMSG(l == curlwp,
+		(%s: l (%p) != curlwp (%p), __func__, l, curlwp));
 		fpu_save();
 #endif
 	}



CVS commit: src

2011-06-12 Thread Iain Hibbert
Module Name:src
Committed By:   plunky
Date:   Sun Jun 12 21:12:46 UTC 2011

Modified Files:
src/distrib/sets/lists/tests: mi
src/tests/lib/libc/ssp: Makefile t_ssp.sh
Added Files:
src/tests/lib/libc/ssp: h_raw.c

Log Message:
reinstate ssp:raw test, slightly differently.. this one is built
with -fstack-protector-all and tests that the compiler built in
stack protection works, by poking directly outside the buffer


To generate a diff of this commit:
cvs rdiff -u -r1.349 -r1.350 src/distrib/sets/lists/tests/mi
cvs rdiff -u -r1.3 -r1.4 src/tests/lib/libc/ssp/Makefile
cvs rdiff -u -r0 -r1.3 src/tests/lib/libc/ssp/h_raw.c
cvs rdiff -u -r1.4 -r1.5 src/tests/lib/libc/ssp/t_ssp.sh

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

Modified files:

Index: src/distrib/sets/lists/tests/mi
diff -u src/distrib/sets/lists/tests/mi:1.349 src/distrib/sets/lists/tests/mi:1.350
--- src/distrib/sets/lists/tests/mi:1.349	Thu Jun  9 05:26:01 2011
+++ src/distrib/sets/lists/tests/mi	Sun Jun 12 21:12:46 2011
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.349 2011/06/09 05:26:01 spz Exp $
+# $NetBSD: mi,v 1.350 2011/06/12 21:12:46 plunky Exp $
 #
 # Note: don't delete entries from here - mark them as obsolete instead.
 #
@@ -416,7 +416,7 @@
 ./usr/libdata/debug/usr/tests/lib/libc/ssp/h_memcpy.debug		tests-lib-debug		debug,atf,ssp
 ./usr/libdata/debug/usr/tests/lib/libc/ssp/h_memmove.debug		tests-lib-debug		debug,atf,ssp
 ./usr/libdata/debug/usr/tests/lib/libc/ssp/h_memset.debug		tests-lib-debug		debug,atf,ssp
-./usr/libdata/debug/usr/tests/lib/libc/ssp/h_raw.debug			tests-obsolete		obsolete
+./usr/libdata/debug/usr/tests/lib/libc/ssp/h_raw.debug			tests-lib-debug		debug,atf,ssp
 ./usr/libdata/debug/usr/tests/lib/libc/ssp/h_read.debug			tests-lib-debug		debug,atf,ssp
 ./usr/libdata/debug/usr/tests/lib/libc/ssp/h_readlink.debug		tests-lib-debug		debug,atf,ssp
 ./usr/libdata/debug/usr/tests/lib/libc/ssp/h_snprintf.debug		tests-lib-debug		debug,atf,ssp
@@ -1930,7 +1930,7 @@
 ./usr/tests/lib/libc/ssp/h_memcpy		tests-lib-tests		atf,ssp
 ./usr/tests/lib/libc/ssp/h_memmove		tests-lib-tests		atf,ssp
 ./usr/tests/lib/libc/ssp/h_memset		tests-lib-tests		atf,ssp
-./usr/tests/lib/libc/ssp/h_raw			tests-obsolete		obsolete
+./usr/tests/lib/libc/ssp/h_raw			tests-lib-tests		atf,ssp
 ./usr/tests/lib/libc/ssp/h_read			tests-lib-tests		atf,ssp
 ./usr/tests/lib/libc/ssp/h_readlink		tests-lib-tests		atf,ssp
 ./usr/tests/lib/libc/ssp/h_snprintf		tests-lib-tests		atf,ssp

Index: src/tests/lib/libc/ssp/Makefile
diff -u src/tests/lib/libc/ssp/Makefile:1.3 src/tests/lib/libc/ssp/Makefile:1.4
--- src/tests/lib/libc/ssp/Makefile:1.3	Sun Jun 12 19:22:01 2011
+++ src/tests/lib/libc/ssp/Makefile	Sun Jun 12 21:12:46 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 2011/06/12 19:22:01 plunky Exp $
+# $NetBSD: Makefile,v 1.4 2011/06/12 21:12:46 plunky Exp $
 
 NOMAN=		# defined
 
@@ -8,6 +8,8 @@
 
 CPPFLAGS+=	-D_FORTIFY_SOURCE=2
 
+COPTS.h_raw.c=	-fstack-protector-all -Wstack-protector --param=ssp-buffer-size=1
+
 # Bootstrap hack
 
 .ifmake !clean  !obj  !cleandir
@@ -30,6 +32,7 @@
 PROGS+=		h_memcpy
 PROGS+=		h_memmove
 PROGS+=		h_memset
+PROGS+=		h_raw
 PROGS+=		h_read
 PROGS+=		h_readlink
 PROGS+=		h_snprintf

Index: src/tests/lib/libc/ssp/t_ssp.sh
diff -u src/tests/lib/libc/ssp/t_ssp.sh:1.4 src/tests/lib/libc/ssp/t_ssp.sh:1.5
--- src/tests/lib/libc/ssp/t_ssp.sh:1.4	Sat Feb 26 02:41:33 2011
+++ src/tests/lib/libc/ssp/t_ssp.sh	Sun Jun 12 21:12:46 2011
@@ -1,4 +1,4 @@
-# $NetBSD: t_ssp.sh,v 1.4 2011/02/26 02:41:33 pgoyette Exp $
+# $NetBSD: t_ssp.sh,v 1.5 2011/06/12 21:12:46 plunky Exp $
 #
 # Copyright (c) 2008 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -206,6 +206,19 @@
 	h_fail $prog 9
 }
 
+atf_test_case raw
+raw_head()
+{
+	atf_set descr Checks raw array overflow
+}
+raw_body()
+{
+	prog=$(atf_get_srcdir)/h_raw
+
+	h_pass $prog 9
+	h_fail $prog 10
+}
+
 atf_test_case read
 read_head()
 {
@@ -260,6 +273,7 @@
 	atf_add_test_case strcpy
 	atf_add_test_case strncat
 	atf_add_test_case strncpy
+	atf_add_test_case raw
 	atf_add_test_case read
 	atf_add_test_case readlink
 	atf_add_test_case getcwd

Added files:

Index: src/tests/lib/libc/ssp/h_raw.c
diff -u /dev/null src/tests/lib/libc/ssp/h_raw.c:1.3
--- /dev/null	Sun Jun 12 21:12:46 2011
+++ src/tests/lib/libc/ssp/h_raw.c	Sun Jun 12 21:12:46 2011
@@ -0,0 +1,49 @@
+/* $NetBSD: h_raw.c,v 1.3 2011/06/12 21:12:46 plunky Exp $ */
+
+/*
+ * Copyright (c) 2011 The NetBSD Foundation, Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *notice, this list of conditions and 

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

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 21:28:27 UTC 2011

Modified Files:
src/sys/arch/powerpc/powerpc: rtas.c

Log Message:
convert to device_t and CFATTACH_DECL_NEW.
now my ofppc system has none left.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/powerpc/powerpc/rtas.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/powerpc/powerpc/rtas.c
diff -u src/sys/arch/powerpc/powerpc/rtas.c:1.9 src/sys/arch/powerpc/powerpc/rtas.c:1.10
--- src/sys/arch/powerpc/powerpc/rtas.c:1.9	Tue Nov  9 06:47:24 2010
+++ src/sys/arch/powerpc/powerpc/rtas.c	Sun Jun 12 21:28:26 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: rtas.c,v 1.9 2010/11/09 06:47:24 uebayasi Exp $ */
+/*	$NetBSD: rtas.c,v 1.10 2011/06/12 21:28:26 mrg Exp $ */
 
 /*
  * CHRP RTAS support routines
@@ -9,7 +9,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: rtas.c,v 1.9 2010/11/09 06:47:24 uebayasi Exp $);
+__KERNEL_RCSID(0, $NetBSD: rtas.c,v 1.10 2011/06/12 21:28:26 mrg Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -28,7 +28,6 @@
 struct rtas_softc *rtas0_softc;
 
 struct rtas_softc {
-	struct device ra_dev;
 	int ra_phandle;
 	int ra_version;
 
@@ -78,7 +77,7 @@
 static int rtas_todr_settime_ymdhms(struct todr_chip_handle *,
 struct clock_ymdhms *);
 
-CFATTACH_DECL(rtas, sizeof (struct rtas_softc),
+CFATTACH_DECL_NEW(rtas, sizeof (struct rtas_softc),
 rtas_match, rtas_attach, rtas_detach, rtas_activate);
 
 static int
@@ -96,7 +95,7 @@
 rtas_attach(struct device *parent, struct device *self, void *aux)
 {
 	struct confargs *ca = aux;
-	struct rtas_softc *sc = (struct rtas_softc *) self;
+	struct rtas_softc *sc = device_private(self);
 	int ph = ca-ca_node;
 	int ih;
 	int rtas_size;



CVS commit: src/bin/sh

2011-06-12 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Mon Jun 13 00:17:15 UTC 2011

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

Log Message:
Typos.


To generate a diff of this commit:
cvs rdiff -u -r1.100 -r1.101 src/bin/sh/sh.1

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

Modified files:

Index: src/bin/sh/sh.1
diff -u src/bin/sh/sh.1:1.100 src/bin/sh/sh.1:1.101
--- src/bin/sh/sh.1:1.100	Sat Jun 11 14:37:36 2011
+++ src/bin/sh/sh.1	Mon Jun 13 00:17:15 2011
@@ -1,4 +1,4 @@
-.\	$NetBSD: sh.1,v 1.100 2011/06/11 14:37:36 christos Exp $
+.\	$NetBSD: sh.1,v 1.101 2011/06/13 00:17:15 uebayasi Exp $
 .\ Copyright (c) 1991, 1993
 .\	The Regents of the University of California.  All rights reserved.
 .\
@@ -1238,7 +1238,7 @@
 .Ar directory
 is
 .Sq - ,
-then she current working directory is changed to the previous current
+then the current working directory is changed to the previous current
 working directory as set in
 .Ev OLDPWD .
 Otherwise if an entry for
@@ -1683,7 +1683,8 @@
 With
 .Ar action
 omitted or set to 
-.Sq - the specified signals are set to their default action.
+.Sq -
+the specified signals are set to their default action.
 When the shell forks off a subshell, it resets trapped (but not ignored)
 signals to the default action.
 On non-interactive shells, the



CVS commit: src/sys/arch/xen/conf

2011-06-12 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Mon Jun 13 00:53:16 UTC 2011

Modified Files:
src/sys/arch/xen/conf: files.xen

Log Message:
Include required file for xen acpi


To generate a diff of this commit:
cvs rdiff -u -r1.120 -r1.121 src/sys/arch/xen/conf/files.xen

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/conf/files.xen
diff -u src/sys/arch/xen/conf/files.xen:1.120 src/sys/arch/xen/conf/files.xen:1.121
--- src/sys/arch/xen/conf/files.xen:1.120	Sun Jun 12 16:31:57 2011
+++ src/sys/arch/xen/conf/files.xen	Mon Jun 13 00:53:15 2011
@@ -1,4 +1,4 @@
-#	$NetBSD: files.xen,v 1.120 2011/06/12 16:31:57 jruoho Exp $
+#	$NetBSD: files.xen,v 1.121 2011/06/13 00:53:15 pgoyette Exp $
 #	NetBSD: files.x86,v 1.10 2003/10/08 17:30:00 bouyer Exp 
 #	NetBSD: files.i386,v 1.254 2004/03/25 23:32:10 jmc Exp 
 
@@ -275,6 +275,7 @@
 file	arch/x86/x86/nmi.c
 
 file	arch/x86/acpi/acpi_machdep.c	acpi
+file	arch/x86/acpi/acpi_pdc.c	acpi
 
 device ioapic
 attach ioapic at ioapicbus



CVS commit: src/sys/lib/libkern/arch/sparc

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Mon Jun 13 03:23:53 UTC 2011

Modified Files:
src/sys/lib/libkern/arch/sparc: divrem.m4

Log Message:
catch up with the userland copy:
revision 1.6
date: 2011/03/23 20:54:35;  author: martin;  state: Exp;  lines: +2 -2
Avoid using %g7

fixes rump on sparc, at least somewhat.
tested that normal kernels runs fine this with this change, too.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/lib/libkern/arch/sparc/divrem.m4

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

Modified files:

Index: src/sys/lib/libkern/arch/sparc/divrem.m4
diff -u src/sys/lib/libkern/arch/sparc/divrem.m4:1.8 src/sys/lib/libkern/arch/sparc/divrem.m4:1.9
--- src/sys/lib/libkern/arch/sparc/divrem.m4:1.8	Sun Dec 11 12:24:44 2005
+++ src/sys/lib/libkern/arch/sparc/divrem.m4	Mon Jun 13 03:23:53 2011
@@ -31,7 +31,7 @@
  * SUCH DAMAGE.
  *
  * from: Header: divrem.m4,v 1.4 92/06/25 13:23:57 torek Exp
- * $NetBSD: divrem.m4,v 1.8 2005/12/11 12:24:44 christos Exp $
+ * $NetBSD: divrem.m4,v 1.9 2011/06/13 03:23:53 mrg Exp $
  */
 
 /*
@@ -89,7 +89,7 @@
 
 /* m4 reminder: ifelse(a,b,c,d) = if a is b, then c, else d */
 define(T, `%g1')
-define(SC, `%g7')
+define(SC, `%g5')
 ifelse(S, `true', `define(SIGN, `%g6')')
 
 /*



CVS commit: src/bin/ps

2011-06-12 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Mon Jun 13 03:42:15 UTC 2011

Modified Files:
src/bin/ps: print.c

Log Message:
When converting from pages to kilobytes, cast the return value of
getpagesize() to size_t. For some reason getpagesize() is defined to
return int, and several of the page counts we get come back from the
kernel as int32_t; in LP64 without the cast the byte count will be
computed in a 32-bit value and for large processes will overflow and
become negative... and then remain negative when divided by 1024 to
convert to kilobytes.

Fixes a problem I hit the other day where I saw negative RSS, which
turns out also to be PR 40642.

Note: other logic in here will break down when we first get 2TB
processes... and int32 page counts will break on 8TB processes. But
hopefully we won't see any of that for a few years yet.


To generate a diff of this commit:
cvs rdiff -u -r1.117 -r1.118 src/bin/ps/print.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/ps/print.c
diff -u src/bin/ps/print.c:1.117 src/bin/ps/print.c:1.118
--- src/bin/ps/print.c:1.117	Sat Jan 22 21:09:51 2011
+++ src/bin/ps/print.c	Mon Jun 13 03:42:15 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: print.c,v 1.117 2011/01/22 21:09:51 christos Exp $	*/
+/*	$NetBSD: print.c,v 1.118 2011/06/13 03:42:15 dholland Exp $	*/
 
 /*
  * Copyright (c) 2000, 2007 The NetBSD Foundation, Inc.
@@ -63,7 +63,7 @@
 #if 0
 static char sccsid[] = @(#)print.c	8.6 (Berkeley) 4/16/94;
 #else
-__RCSID($NetBSD: print.c,v 1.117 2011/01/22 21:09:51 christos Exp $);
+__RCSID($NetBSD: print.c,v 1.118 2011/06/13 03:42:15 dholland Exp $);
 #endif
 #endif /* not lint */
 
@@ -967,7 +967,7 @@
 	}
 }
 
-#define	pgtok(a)(((a)*getpagesize())/1024)
+#define	pgtok(a)(((a)*(size_t)getpagesize())/1024)
 
 void
 vsize(void *arg, VARENT *ve, int mode)



CVS commit: src/sys/arch/x86

2011-06-12 Thread Thor Lancelot Simon
Module Name:src
Committed By:   tls
Date:   Mon Jun 13 04:30:40 UTC 2011

Modified Files:
src/sys/arch/x86/include: pmap.h
src/sys/arch/x86/x86: pmap.c

Log Message:
Fix Xen kernel builds (pmap_is_curpmap can't be static)


To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/sys/arch/x86/include/pmap.h
cvs rdiff -u -r1.122 -r1.123 src/sys/arch/x86/x86/pmap.c

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

Modified files:

Index: src/sys/arch/x86/include/pmap.h
diff -u src/sys/arch/x86/include/pmap.h:1.39 src/sys/arch/x86/include/pmap.h:1.40
--- src/sys/arch/x86/include/pmap.h:1.39	Sun Jun 12 03:35:50 2011
+++ src/sys/arch/x86/include/pmap.h	Mon Jun 13 04:30:40 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.h,v 1.39 2011/06/12 03:35:50 rmind Exp $	*/
+/*	$NetBSD: pmap.h,v 1.40 2011/06/13 04:30:40 tls Exp $	*/
 
 /*
  * Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -243,6 +243,8 @@
 
 u_int		x86_mmap_flags(paddr_t);
 
+bool		pmap_is_curpmap(struct pmap *);
+
 vaddr_t reserve_dumppages(vaddr_t); /* XXX: not a pmap fn */
 
 typedef enum tlbwhy {

Index: src/sys/arch/x86/x86/pmap.c
diff -u src/sys/arch/x86/x86/pmap.c:1.122 src/sys/arch/x86/x86/pmap.c:1.123
--- src/sys/arch/x86/x86/pmap.c:1.122	Sun Jun 12 03:35:50 2011
+++ src/sys/arch/x86/x86/pmap.c	Mon Jun 13 04:30:40 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.122 2011/06/12 03:35:50 rmind Exp $	*/
+/*	$NetBSD: pmap.c,v 1.123 2011/06/13 04:30:40 tls Exp $	*/
 
 /*-
  * Copyright (c) 2008, 2010 The NetBSD Foundation, Inc.
@@ -171,7 +171,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.122 2011/06/12 03:35:50 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.123 2011/06/13 04:30:40 tls Exp $);
 
 #include opt_user_ldt.h
 #include opt_lockdebug.h
@@ -564,7 +564,6 @@
 static void		 pmap_free_ptp(struct pmap *, struct vm_page *,
    vaddr_t, pt_entry_t *,
    pd_entry_t * const *);
-static bool		 pmap_is_curpmap(struct pmap *);
 static bool		 pmap_is_active(struct pmap *, struct cpu_info *, bool);
 static bool		 pmap_remove_pte(struct pmap *, struct vm_page *,
 	 pt_entry_t *, vaddr_t,
@@ -676,7 +675,7 @@
  *		of course the kernel is always loaded
  */
 
-inline static bool
+bool
 pmap_is_curpmap(struct pmap *pmap)
 {
 #if defined(XEN)  defined(__x86_64__)



CVS commit: src/sys/arch/sh3/sh3

2011-06-12 Thread UCHIYAMA Yasushi
Module Name:src
Committed By:   uch
Date:   Mon Jun 13 05:23:34 UTC 2011

Modified Files:
src/sys/arch/sh3/sh3: vm_machdep.c

Log Message:
include uvm_page.h for vm_physmem[]


To generate a diff of this commit:
cvs rdiff -u -r1.72 -r1.73 src/sys/arch/sh3/sh3/vm_machdep.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/sh3/sh3/vm_machdep.c
diff -u src/sys/arch/sh3/sh3/vm_machdep.c:1.72 src/sys/arch/sh3/sh3/vm_machdep.c:1.73
--- src/sys/arch/sh3/sh3/vm_machdep.c:1.72	Sun Jun 12 03:35:46 2011
+++ src/sys/arch/sh3/sh3/vm_machdep.c	Mon Jun 13 05:23:33 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: vm_machdep.c,v 1.72 2011/06/12 03:35:46 rmind Exp $	*/
+/*	$NetBSD: vm_machdep.c,v 1.73 2011/06/13 05:23:33 uch Exp $	*/
 
 /*-
  * Copyright (c) 2002 The NetBSD Foundation, Inc. All rights reserved.
@@ -81,7 +81,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: vm_machdep.c,v 1.72 2011/06/12 03:35:46 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: vm_machdep.c,v 1.73 2011/06/13 05:23:33 uch Exp $);
 
 #include opt_kstack_debug.h
 
@@ -101,6 +101,7 @@
 #include dev/mm.h
 
 #include uvm/uvm_extern.h
+#include uvm/uvm_page.h
 
 #include sh3/locore.h
 #include sh3/cpu.h



CVS commit: src/sys/arch/powerpc

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 06:10:42 UTC 2011

Modified Files:
src/sys/arch/powerpc/include: types.h
src/sys/arch/powerpc/powerpc: powerpc_machdep.c

Log Message:
need mm_md_direct_mapped_phys support.


To generate a diff of this commit:
cvs rdiff -u -r1.41 -r1.42 src/sys/arch/powerpc/include/types.h
cvs rdiff -u -r1.51 -r1.52 src/sys/arch/powerpc/powerpc/powerpc_machdep.c

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



CVS commit: src/usr.bin/pmap

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 06:35:00 UTC 2011

Modified Files:
src/usr.bin/pmap: pmap.c

Log Message:
an_ref is now a uintptr_t.


To generate a diff of this commit:
cvs rdiff -u -r1.45 -r1.46 src/usr.bin/pmap/pmap.c

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



CVS commit: src/sys

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 06:36:38 UTC 2011

Modified Files:
src/sys/rump/librump/rumpkern: Makefile.rumpkern vm.c
src/sys/uvm: uvm_object.c

Log Message:
include uvm_object.c in the rump kernel for the new uvm_obj* functions.
don't build the uvm_object.c uvm_object_printit() for _RUMPKERNEL. (XXX)
add empty panic() stubs for uvm_loanbreak() and ubc_purge().

fixes some more 5.99.53 rump build issues.


To generate a diff of this commit:
cvs rdiff -u -r1.109 -r1.110 src/sys/rump/librump/rumpkern/Makefile.rumpkern
cvs rdiff -u -r1.115 -r1.116 src/sys/rump/librump/rumpkern/vm.c
cvs rdiff -u -r1.8 -r1.9 src/sys/uvm/uvm_object.c

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



CVS commit: src/tests/rump/kernspace

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 06:38:14 UTC 2011

Modified Files:
src/tests/rump/kernspace: busypage.c

Log Message:
vmobjlock is now a pointer to kmutex_t.  use it as one.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tests/rump/kernspace/busypage.c

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



CVS commit: src/sys/arch/bebox/include

2011-06-12 Thread KIYOHARA Takashi
Module Name:src
Committed By:   kiyohara
Date:   Sun Jun 12 07:04:55 UTC 2011

Modified Files:
src/sys/arch/bebox/include: param.h

Log Message:
Remove comment-outed DELAY().


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/bebox/include/param.h

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



CVS commit: src/sys/arch/bebox/stand/boot

2011-06-12 Thread KIYOHARA Takashi
Module Name:src
Committed By:   kiyohara
Date:   Sun Jun 12 07:07:17 UTC 2011

Modified Files:
src/sys/arch/bebox/stand/boot: cpu.c

Log Message:
Remove null line.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/bebox/stand/boot/cpu.c

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



CVS commit: src/sys/arch/powerpc/ibm4xx/dev

2011-06-12 Thread KIYOHARA Takashi
Module Name:src
Committed By:   kiyohara
Date:   Sun Jun 12 07:19:49 UTC 2011

Modified Files:
src/sys/arch/powerpc/ibm4xx/dev: gpiic_opb.c

Log Message:
Initialize i2cbus_attach_args before call config_found().  It has other member.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/powerpc/ibm4xx/dev/gpiic_opb.c

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



CVS commit: src

2011-06-12 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jun 12 07:25:44 UTC 2011

Modified Files:
src/share/man/man4: aibs.4
src/sys/dev/acpi: files.acpi
src/sys/modules/aibs: Makefile
Added Files:
src/sys/dev/acpi: aibs_acpi.c
Removed Files:
src/sys/dev/acpi: atk0110.c

Log Message:
Rewrite the aibs(4) driver in order to support new models. Draws from the
revision 1.6 (claudio@) of the OpenBSD's equivalent driver. Tested by mrg@.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/share/man/man4/aibs.4
cvs rdiff -u -r0 -r1.1 src/sys/dev/acpi/aibs_acpi.c
cvs rdiff -u -r1.16 -r0 src/sys/dev/acpi/atk0110.c
cvs rdiff -u -r1.88 -r1.89 src/sys/dev/acpi/files.acpi
cvs rdiff -u -r1.3 -r1.4 src/sys/modules/aibs/Makefile

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



CVS commit: othersrc/external/bsd/bufgap

2011-06-12 Thread Alistair G. Crooks
Module Name:othersrc
Committed By:   agc
Date:   Sun Jun 12 07:48:29 UTC 2011

Update of /cvsroot/othersrc/external/bsd/bufgap
In directory ivanova.netbsd.org:/tmp/cvs-serv28782

Log Message:
Import buffer gap routines into othersrc.

These routines were originally written in 1996 to support various
editors, and are still in use where text may change at beginning and
ends of buffers, with a need to be able to move forwards and backwards
within a buffer efficiently, counting characters and line positions. 

A buffer gap structure works by having a number of characters after
the gap, and a number of characters before the gap.  To move forwards,
the next character before the gap is copied to the group of characters
after the gap, and the count of before characters decremented, and the
after count incremented.  Moving backwards is the opposite operation. 
Text is inserted at the end of the after characters.

A small program is included which exercises the routines by moving to
the end of the file character by character, reversing character by
character, and then moving forwards once again.

Status:

Vendor Tag: CROOKS
Release Tags:   bufgap-base

N othersrc/external/bsd/bufgap/Makefile
N othersrc/external/bsd/bufgap/dist/bufgap.c
N othersrc/external/bsd/bufgap/dist/bufgap.h
N othersrc/external/bsd/bufgap/dist/defs.h
N othersrc/external/bsd/bufgap/dist/bufgap
N othersrc/external/bsd/bufgap/dist/bufgap.3
N othersrc/external/bsd/bufgap/dist/main.c
N othersrc/external/bsd/bufgap/dist/bufgap.1
N othersrc/external/bsd/bufgap/libbufgap/shlib_version
N othersrc/external/bsd/bufgap/libbufgap/config.h
N othersrc/external/bsd/bufgap/libbufgap/Makefile
N othersrc/external/bsd/bufgap/bufgap/Makefile

No conflicts created by this import



CVS commit: src/sys

2011-06-12 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jun 12 10:11:53 UTC 2011

Modified Files:
src/sys/arch/ia64/acpi: acpi_machdep.c
src/sys/arch/ia64/include: acpi_machdep.h
src/sys/arch/x86/acpi: acpi_cpu_md.c
src/sys/arch/x86/conf: files.x86
src/sys/arch/x86/include: acpi_machdep.h
src/sys/dev/acpi: acpi.c acpi_cpu.c acpi_cpu.h
Added Files:
src/sys/arch/x86/acpi: acpi_pdc.c

Log Message:
Move the evaluation of the _PDC control method out from the acpicpu(4)
driver to the main acpi(4) stack. Follow Linux and evaluate it early.
Should fix PR port-amd64/42895, possibly also PR kern/42583, and many
other comparable bugs.

A common sense explanation is that Intel supplies additional CPU tables to
OEMs. BIOS writers do not bother to modify their DSDTs, but instead load
these extra tables dynamically as secondary SSDT tables. The actual Load()
happens when the _PDC method is invoked, and thus namespace errors occur
when the CPU-specific ACPI methods are not yet present but referenced in the
AML by various drivers, including, but not limited to, acpitz(4).


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/ia64/acpi/acpi_machdep.c
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/ia64/include/acpi_machdep.h
cvs rdiff -u -r1.60 -r1.61 src/sys/arch/x86/acpi/acpi_cpu_md.c
cvs rdiff -u -r0 -r1.1 src/sys/arch/x86/acpi/acpi_pdc.c
cvs rdiff -u -r1.69 -r1.70 src/sys/arch/x86/conf/files.x86
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/x86/include/acpi_machdep.h
cvs rdiff -u -r1.242 -r1.243 src/sys/dev/acpi/acpi.c
cvs rdiff -u -r1.40 -r1.41 src/sys/dev/acpi/acpi_cpu.c \
src/sys/dev/acpi/acpi_cpu.h

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



CVS commit: src/sys

2011-06-12 Thread Jukka Ruohonen
Module Name:src
Committed By:   jruoho
Date:   Sun Jun 12 11:31:31 UTC 2011

Modified Files:
src/sys/arch/ia64/acpi: acpi_machdep.c
src/sys/arch/ia64/include: acpi_machdep.h
src/sys/arch/x86/conf: files.x86
src/sys/arch/x86/include: acpi_machdep.h
src/sys/dev/acpi/acpica: OsdEnvironment.c
Added Files:
src/sys/arch/x86/acpi: acpi_machdep.c
Removed Files:
src/sys/arch/x86/x86: acpi_machdep.c

Log Message:
Follow IA-64 with the x86-specific ACPI MD functions and move these where
they belong to. Remove an unused function. Minor KNF. No functional change.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/ia64/acpi/acpi_machdep.c
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/ia64/include/acpi_machdep.h
cvs rdiff -u -r0 -r1.1 src/sys/arch/x86/acpi/acpi_machdep.c
cvs rdiff -u -r1.70 -r1.71 src/sys/arch/x86/conf/files.x86
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/x86/include/acpi_machdep.h
cvs rdiff -u -r1.29 -r0 src/sys/arch/x86/x86/acpi_machdep.c
cvs rdiff -u -r1.5 -r1.6 src/sys/dev/acpi/acpica/OsdEnvironment.c

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



CVS commit: src/sys/arch/emips/emips

2011-06-12 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sun Jun 12 13:40:14 UTC 2011

Modified Files:
src/sys/arch/emips/emips: promcall.c

Log Message:
Some KNF.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/emips/emips/promcall.c

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



CVS commit: src/sys/arch/emips/ebus

2011-06-12 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sun Jun 12 14:31:31 UTC 2011

Modified Files:
src/sys/arch/emips/ebus: if_le_ebus.c

Log Message:
- misc KNF
- use device_t and cfdata_t


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/emips/ebus/if_le_ebus.c

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



CVS commit: src/external/cddl/osnet/dist/uts/common/fs/zfs

2011-06-12 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Sun Jun 12 14:47:20 UTC 2011

Modified Files:
src/external/cddl/osnet/dist/uts/common/fs/zfs: zfs_znode.c

Log Message:
Fix ZFS build.


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 \
src/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c

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



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

2011-06-12 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Jun 12 16:15:42 UTC 2011

Modified Files:
src/crypto/external/bsd/openssl/dist/crypto/idea: ideatest.c
src/crypto/external/bsd/openssl/dist/crypto/mdc2: mdc2test.c

Log Message:
fix warnings for the patented algos


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c

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



CVS commit: src/sys/arch/powerpc/include

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 16:27:14 UTC 2011

Modified Files:
src/sys/arch/powerpc/include: cpu.h

Log Message:
Use mfsprg0 instead of mfsprg r,0


To generate a diff of this commit:
cvs rdiff -u -r1.77 -r1.78 src/sys/arch/powerpc/include/cpu.h

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



CVS commit: src/sys/arch/powerpc/oea

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 16:27:52 UTC 2011

Modified Files:
src/sys/arch/powerpc/oea: cpu_subr.c

Log Message:
Use mtsprg0 instead of mtsprg 0,r


To generate a diff of this commit:
cvs rdiff -u -r1.63 -r1.64 src/sys/arch/powerpc/oea/cpu_subr.c

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



CVS commit: src/sys/arch/powerpc/oea

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 16:35:10 UTC 2011

Modified Files:
src/sys/arch/powerpc/oea: ofw_subr.S ofwoea_machdep.c

Log Message:
Save/restore all sprgs when calling OFW.
Move all-zero variables from .data to .bss
Use .lcomm for local variables.
Cleanup a bit of assembly.
Clear PSL_IP in the saved ofmsr (was previously done in ofwoea_machdep.c)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/powerpc/oea/ofw_subr.S
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/powerpc/oea/ofwoea_machdep.c

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



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

2011-06-12 Thread Iain Hibbert
Module Name:src
Committed By:   plunky
Date:   Sun Jun 12 19:22:02 UTC 2011

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

Log Message:
don't pass -fstack-protector for these, the tests are actually for the
__*_chk functions included by -D_FORTIFY_SOURCE=2, and if the compiler
provides additional protection, it can mask broken functions..

(none of the _chk functions will return or process any data if
the length given is known to be larger than the buffer)


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

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



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

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 20:23:29 UTC 2011

Modified Files:
src/distrib/sets/lists/comp: ad.mips64eb ad.mips64el

Log Message:
Cleanup for libsl.so.5 changes


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/distrib/sets/lists/comp/ad.mips64eb \
src/distrib/sets/lists/comp/ad.mips64el

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



CVS commit: src/lib/libc/arch/i386/stdlib

2011-06-12 Thread Iain Hibbert
Module Name:src
Committed By:   plunky
Date:   Sun Jun 12 20:29:26 UTC 2011

Modified Files:
src/lib/libc/arch/i386/stdlib: div.S ldiv.S

Log Message:
Functions that return a struct or union, must set %eax to the value
of the original address of the callers area before it returns.

(System V ABI, i386 supplement, fourth edition, page 3-14)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/arch/i386/stdlib/div.S \
src/lib/libc/arch/i386/stdlib/ldiv.S

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



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

2011-06-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Jun 12 20:38:10 UTC 2011

Modified Files:
src/sys/arch/powerpc/powerpc: process_machdep.c

Log Message:
Change KASSERT to KASSERTMSG.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/sys/arch/powerpc/powerpc/process_machdep.c

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



CVS commit: src

2011-06-12 Thread Iain Hibbert
Module Name:src
Committed By:   plunky
Date:   Sun Jun 12 21:12:46 UTC 2011

Modified Files:
src/distrib/sets/lists/tests: mi
src/tests/lib/libc/ssp: Makefile t_ssp.sh
Added Files:
src/tests/lib/libc/ssp: h_raw.c

Log Message:
reinstate ssp:raw test, slightly differently.. this one is built
with -fstack-protector-all and tests that the compiler built in
stack protection works, by poking directly outside the buffer


To generate a diff of this commit:
cvs rdiff -u -r1.349 -r1.350 src/distrib/sets/lists/tests/mi
cvs rdiff -u -r1.3 -r1.4 src/tests/lib/libc/ssp/Makefile
cvs rdiff -u -r0 -r1.3 src/tests/lib/libc/ssp/h_raw.c
cvs rdiff -u -r1.4 -r1.5 src/tests/lib/libc/ssp/t_ssp.sh

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



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

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Jun 12 21:28:27 UTC 2011

Modified Files:
src/sys/arch/powerpc/powerpc: rtas.c

Log Message:
convert to device_t and CFATTACH_DECL_NEW.
now my ofppc system has none left.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/powerpc/powerpc/rtas.c

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



CVS commit: src/bin/sh

2011-06-12 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Mon Jun 13 00:17:15 UTC 2011

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

Log Message:
Typos.


To generate a diff of this commit:
cvs rdiff -u -r1.100 -r1.101 src/bin/sh/sh.1

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



CVS commit: src/sys/arch/xen/conf

2011-06-12 Thread Paul Goyette
Module Name:src
Committed By:   pgoyette
Date:   Mon Jun 13 00:53:16 UTC 2011

Modified Files:
src/sys/arch/xen/conf: files.xen

Log Message:
Include required file for xen acpi


To generate a diff of this commit:
cvs rdiff -u -r1.120 -r1.121 src/sys/arch/xen/conf/files.xen

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



CVS commit: src/sys/lib/libkern/arch/sparc

2011-06-12 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Mon Jun 13 03:23:53 UTC 2011

Modified Files:
src/sys/lib/libkern/arch/sparc: divrem.m4

Log Message:
catch up with the userland copy:
revision 1.6
date: 2011/03/23 20:54:35;  author: martin;  state: Exp;  lines: +2 -2
Avoid using %g7

fixes rump on sparc, at least somewhat.
tested that normal kernels runs fine this with this change, too.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/lib/libkern/arch/sparc/divrem.m4

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



CVS commit: src/bin/ps

2011-06-12 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Mon Jun 13 03:42:15 UTC 2011

Modified Files:
src/bin/ps: print.c

Log Message:
When converting from pages to kilobytes, cast the return value of
getpagesize() to size_t. For some reason getpagesize() is defined to
return int, and several of the page counts we get come back from the
kernel as int32_t; in LP64 without the cast the byte count will be
computed in a 32-bit value and for large processes will overflow and
become negative... and then remain negative when divided by 1024 to
convert to kilobytes.

Fixes a problem I hit the other day where I saw negative RSS, which
turns out also to be PR 40642.

Note: other logic in here will break down when we first get 2TB
processes... and int32 page counts will break on 8TB processes. But
hopefully we won't see any of that for a few years yet.


To generate a diff of this commit:
cvs rdiff -u -r1.117 -r1.118 src/bin/ps/print.c

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



CVS commit: src/sys/arch/x86

2011-06-12 Thread Thor Lancelot Simon
Module Name:src
Committed By:   tls
Date:   Mon Jun 13 04:30:40 UTC 2011

Modified Files:
src/sys/arch/x86/include: pmap.h
src/sys/arch/x86/x86: pmap.c

Log Message:
Fix Xen kernel builds (pmap_is_curpmap can't be static)


To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/sys/arch/x86/include/pmap.h
cvs rdiff -u -r1.122 -r1.123 src/sys/arch/x86/x86/pmap.c

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



CVS commit: src/sys/arch/sh3/sh3

2011-06-12 Thread UCHIYAMA Yasushi
Module Name:src
Committed By:   uch
Date:   Mon Jun 13 05:23:34 UTC 2011

Modified Files:
src/sys/arch/sh3/sh3: vm_machdep.c

Log Message:
include uvm_page.h for vm_physmem[]


To generate a diff of this commit:
cvs rdiff -u -r1.72 -r1.73 src/sys/arch/sh3/sh3/vm_machdep.c

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