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

2020-10-05 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Mon Oct  5 10:42:53 UTC 2020

Modified Files:
src/sys/arch/sun2/conf: Makefile.sun2

Log Message:
Kernel without -fno-omit-frame-pointer works fine now, both for GCC8 and 9.
Not sure which commit ``fixed'' the problem although...


To generate a diff of this commit:
cvs rdiff -u -r1.26 -r1.27 src/sys/arch/sun2/conf/Makefile.sun2

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/sun2/conf/Makefile.sun2
diff -u src/sys/arch/sun2/conf/Makefile.sun2:1.26 src/sys/arch/sun2/conf/Makefile.sun2:1.27
--- src/sys/arch/sun2/conf/Makefile.sun2:1.26	Tue Sep  8 00:51:29 2020
+++ src/sys/arch/sun2/conf/Makefile.sun2	Mon Oct  5 10:42:53 2020
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.sun2,v 1.26 2020/09/08 00:51:29 mrg Exp $
+# $NetBSD: Makefile.sun2,v 1.27 2020/10/05 10:42:53 rin Exp $
 
 # Makefile for NetBSD
 #
@@ -36,7 +36,6 @@ CFLAGS+=	-msoft-float -fno-defer-pop
 AFLAGS+=	-x assembler-with-cpp
 
 # XXX
-COPTS+=		${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} >= 8:? -fno-omit-frame-pointer :}
 COPTS.promlib.c+=${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} >= 9:? -Wno-error=array-bounds :}
 
 ##



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

2020-09-07 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Tue Sep  8 00:51:29 UTC 2020

Modified Files:
src/sys/arch/sun2/conf: Makefile.sun2

Log Message:
don't warn about array bounds for dodgy diagnostic code.
fixes gcc9 builds.


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/sun2/conf/Makefile.sun2

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/sun2/conf/Makefile.sun2
diff -u src/sys/arch/sun2/conf/Makefile.sun2:1.25 src/sys/arch/sun2/conf/Makefile.sun2:1.26
--- src/sys/arch/sun2/conf/Makefile.sun2:1.25	Mon Aug 10 06:28:42 2020
+++ src/sys/arch/sun2/conf/Makefile.sun2	Tue Sep  8 00:51:29 2020
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.sun2,v 1.25 2020/08/10 06:28:42 rin Exp $
+# $NetBSD: Makefile.sun2,v 1.26 2020/09/08 00:51:29 mrg Exp $
 
 # Makefile for NetBSD
 #
@@ -36,9 +36,8 @@ CFLAGS+=	-msoft-float -fno-defer-pop
 AFLAGS+=	-x assembler-with-cpp
 
 # XXX
-.if ${HAVE_GCC:U0} >= 8
-COPTS+=		-fno-omit-frame-pointer
-.endif
+COPTS+=		${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} >= 8:? -fno-omit-frame-pointer :}
+COPTS.promlib.c+=${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} >= 9:? -Wno-error=array-bounds :}
 
 ##
 ## (3) libkern and compat



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

2020-08-10 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Mon Aug 10 06:29:49 UTC 2020

Modified Files:
src/sys/arch/sun2/conf: GENERIC

Log Message:
Reduce kernel size by
- Adding -fno-asynchronous-unwind-tables and -fno-unwind-tables to COPTS
- Specify NO_KERNEL_RCSIDS to strip RCSIDS
Also adding -fno-omit-frame-pointer to COPTS for backtrace in DDB.


To generate a diff of this commit:
cvs rdiff -u -r1.106 -r1.107 src/sys/arch/sun2/conf/GENERIC

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/sun2/conf/GENERIC
diff -u src/sys/arch/sun2/conf/GENERIC:1.106 src/sys/arch/sun2/conf/GENERIC:1.107
--- src/sys/arch/sun2/conf/GENERIC:1.106	Sat Aug  1 08:20:52 2020
+++ src/sys/arch/sun2/conf/GENERIC	Mon Aug 10 06:29:49 2020
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.106 2020/08/01 08:20:52 maxv Exp $
+# $NetBSD: GENERIC,v 1.107 2020/08/10 06:29:49 rin Exp $
 #
 # GENERIC machine description file
 # 
@@ -29,10 +29,13 @@ options 	INSECURE		# allow modload(8) in
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		"GENERIC-$Revision: 1.106 $"
+#ident 		"GENERIC-$Revision: 1.107 $"
 
-makeoptions	COPTS="-Os -fno-inline-small-functions"
-	# bootloader has size limit (~2MB)
+# Bootloader has size limit (~2MB). Kernel should be smaller than this
+# hard limit. Otherwise, it freezes before adding swap even with 7MB
+# memory. -fno-omit-frame-pointer is necessary for backtraces in DDB.
+options 	NO_KERNEL_RCSIDS
+makeoptions	COPTS="-Os -fno-inline-small-functions -fno-asynchronous-unwind-tables -fno-unwind-tables -fno-omit-frame-pointer"
 
 # Machines to be supported by this kernel
 #options 	FPU_EMULATE



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

2020-08-10 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Mon Aug 10 06:28:42 UTC 2020

Modified Files:
src/sys/arch/sun2/conf: Makefile.sun2

Log Message:
Compile sun2 kernel with -fno-omit-frame-pointer for GCC8 as a work
around for reproducible kernel freezes just after ``Starting postfix.'',
where I cannot even enter DDB nor obtain crash dump.

I still haven't figured out why. Possibly something wrong with -Os
optimization level for GCC/m68k, cf.,
http://mail-index.netbsd.org/port-sun3/2020/07/19/msg000166.html


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/sun2/conf/Makefile.sun2

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/sun2/conf/Makefile.sun2
diff -u src/sys/arch/sun2/conf/Makefile.sun2:1.24 src/sys/arch/sun2/conf/Makefile.sun2:1.25
--- src/sys/arch/sun2/conf/Makefile.sun2:1.24	Sat Sep 22 12:24:03 2018
+++ src/sys/arch/sun2/conf/Makefile.sun2	Mon Aug 10 06:28:42 2020
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.sun2,v 1.24 2018/09/22 12:24:03 rin Exp $
+# $NetBSD: Makefile.sun2,v 1.25 2020/08/10 06:28:42 rin Exp $
 
 # Makefile for NetBSD
 #
@@ -35,6 +35,11 @@ CPPFLAGS+=	-Dsun2
 CFLAGS+=	-msoft-float -fno-defer-pop
 AFLAGS+=	-x assembler-with-cpp
 
+# XXX
+.if ${HAVE_GCC:U0} >= 8
+COPTS+=		-fno-omit-frame-pointer
+.endif
+
 ##
 ## (3) libkern and compat
 ##



CVS commit: src/sys/arch/sun2/dev

2020-03-19 Thread Jason R Thorpe
Module Name:src
Committed By:   thorpej
Date:   Thu Mar 19 14:01:48 UTC 2020

Modified Files:
src/sys/arch/sun2/dev: if_ec.c

Log Message:
Replace manipulating IFF_OACTIVE with an internal "txbusy" field.


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/sys/arch/sun2/dev/if_ec.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/sun2/dev/if_ec.c
diff -u src/sys/arch/sun2/dev/if_ec.c:1.35 src/sys/arch/sun2/dev/if_ec.c:1.36
--- src/sys/arch/sun2/dev/if_ec.c:1.35	Wed Jan 29 05:39:48 2020
+++ src/sys/arch/sun2/dev/if_ec.c	Thu Mar 19 14:01:48 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_ec.c,v 1.35 2020/01/29 05:39:48 thorpej Exp $	*/
+/*	$NetBSD: if_ec.c,v 1.36 2020/03/19 14:01:48 thorpej Exp $	*/
 
 /*
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_ec.c,v 1.35 2020/01/29 05:39:48 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_ec.c,v 1.36 2020/03/19 14:01:48 thorpej Exp $");
 
 #include "opt_inet.h"
 #include "opt_ns.h"
@@ -86,6 +86,7 @@ struct ec_softc {
 	bus_space_tag_t sc_iot;	/* bus space tag */
 	bus_space_handle_t sc_ioh;	/* bus space handle */
 
+	bool sc_txbusy;
 	u_char sc_jammed;	/* nonzero if the net is jammed */
 	u_char sc_colliding;	/* nonzero if the net is colliding */
 	uint32_t sc_backoff_seed;	/* seed for the backoff PRNG */
@@ -281,7 +282,7 @@ ec_init(struct ifnet *ifp)
 
 	/* Set flags appropriately. */
 	ifp->if_flags |= IFF_RUNNING;
-	ifp->if_flags &= ~IFF_OACTIVE;
+	sc->sc_txbusy = false;
 
 	/* Start output. */
 	ec_start(ifp);
@@ -305,7 +306,7 @@ ec_start(struct ifnet *ifp)
 	s = splnet();
 
 	/* Don't do anything if output is active. */
-	if ((ifp->if_flags & IFF_OACTIVE) != 0) {
+	if (sc->sc_txbusy) {
 		splx(s);
 		return;
 	}
@@ -334,7 +335,7 @@ ec_start(struct ifnet *ifp)
 	/* Enable the transmitter. */
 	ECREG_CSR_WR((ECREG_CSR_RD & EC_CSR_PA) |
 	EC_CSR_TBSW | EC_CSR_TINT | EC_CSR_JINT);
-	ifp->if_flags |= IFF_OACTIVE;
+	sc->sc_txbusy = true;
 
 	/* Done. */
 	splx(s);
@@ -413,7 +414,7 @@ ec_intr(void *arg)
 		retval++;
 	}
 	/* Check for a transmitted packet. */
-	if (ifp->if_flags & IFF_OACTIVE) {
+	if (sc->sc_txbusy) {
 
 		/* If we got a collision. */
 		if (ECREG_CSR_RD & EC_CSR_JAM) {
@@ -431,7 +432,7 @@ ec_intr(void *arg)
 			retval++;
 			if_statinc(ifp, if_opackets);
 			sc->sc_jammed = 0;
-			ifp->if_flags &= ~IFF_OACTIVE;
+			sc->sc_txbusy = false;
 			if_schedule_deferred_start(ifp);
 		}
 	} else {
@@ -635,7 +636,7 @@ ec_coll(struct ec_softc *sc)
 			device_xname(sc->sc_dev));
 		sc->sc_jammed = 1;
 		sc->sc_colliding = 0;
-		ifp->if_flags &= ~IFF_OACTIVE;
+		sc->sc_txbusy = false;
 		if_schedule_deferred_start(ifp);
 	} else {
 		jams = MAX(sc->sc_colliding, EC_BACKOFF_PRNG_COLL_MAX);



CVS commit: src/sys/arch/sun2/dev

2020-03-12 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Fri Mar 13 01:48:16 UTC 2020

Modified Files:
src/sys/arch/sun2/dev: zsvar.h

Log Message:
Fix build without kbd at zstty, simplify.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/sun2/dev/zsvar.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/sun2/dev/zsvar.h
diff -u src/sys/arch/sun2/dev/zsvar.h:1.8 src/sys/arch/sun2/dev/zsvar.h:1.9
--- src/sys/arch/sun2/dev/zsvar.h:1.8	Thu Jul  7 06:55:38 2016
+++ src/sys/arch/sun2/dev/zsvar.h	Fri Mar 13 01:48:16 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: zsvar.h,v 1.8 2016/07/07 06:55:38 msaitoh Exp $	*/
+/*	$NetBSD: zsvar.h,v 1.9 2020/03/13 01:48:16 rin Exp $	*/
 
 /*
  * Copyright (c) 1992, 1993
@@ -44,15 +44,18 @@
 #include 
 #include 
 
+#ifdef _KERNEL_OPT
+#include "kbd.h"
+#endif
+
+#if NKBD > 0
 /*
  * Need to override cn_console_dev() for zstty and zskbd.
  */
-#ifdef cn_isconsole
-#undef cn_isconsole
-#endif
 extern struct consdev *cn_hw;
-extern struct consdev *cn_tab;
+#undef cn_isconsole
 #define cn_isconsole(d)	((d) == cn_tab->cn_dev || (d) == cn_hw->cn_dev)
+#endif
 
 struct zsc_softc {
 	device_t		zsc_dev;	/* base device */



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

2020-03-07 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Sun Mar  8 06:32:41 UTC 2020

Modified Files:
src/sys/arch/sun2/conf: GENERIC NFS

Log Message:
Fix comments on root devices.


To generate a diff of this commit:
cvs rdiff -u -r1.104 -r1.105 src/sys/arch/sun2/conf/GENERIC
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/sun2/conf/NFS

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/sun2/conf/GENERIC
diff -u src/sys/arch/sun2/conf/GENERIC:1.104 src/sys/arch/sun2/conf/GENERIC:1.105
--- src/sys/arch/sun2/conf/GENERIC:1.104	Sun Mar  8 06:25:10 2020
+++ src/sys/arch/sun2/conf/GENERIC	Sun Mar  8 06:32:41 2020
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.104 2020/03/08 06:25:10 rin Exp $
+# $NetBSD: GENERIC,v 1.105 2020/03/08 06:32:41 rin Exp $
 #
 # GENERIC machine description file
 # 
@@ -19,7 +19,7 @@
 # device.
 
 # Supports Sun2 (2/120, 2/170, 2/50, ...)
-# Supports root on: ie0, sd*, ...
+# Supports root on: sd*, ... (FFS)
 
 include 	"arch/sun2/conf/std.sun2"
 
@@ -29,7 +29,7 @@ options 	INSECURE		# allow modload(8) in
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		"GENERIC-$Revision: 1.104 $"
+#ident 		"GENERIC-$Revision: 1.105 $"
 
 makeoptions	COPTS="-Os -fno-inline-small-functions"
 	# bootloader has size limit (~2MB)

Index: src/sys/arch/sun2/conf/NFS
diff -u src/sys/arch/sun2/conf/NFS:1.1 src/sys/arch/sun2/conf/NFS:1.2
--- src/sys/arch/sun2/conf/NFS:1.1	Sun Mar  8 06:23:18 2020
+++ src/sys/arch/sun2/conf/NFS	Sun Mar  8 06:32:41 2020
@@ -1,9 +1,9 @@
-# $NetBSD: NFS,v 1.1 2020/03/08 06:23:18 rin Exp $
+# $NetBSD: NFS,v 1.2 2020/03/08 06:32:41 rin Exp $
 #
 # GENERIC machine description file for NFS root instead of FFS
 
 # Supports Sun2 (2/120, 2/170, 2/50, ...)
-# Supports root on: ie0, sd*, ...
+# Supports root on: ie0, ... (NFS)
 
 include 	"arch/sun2/conf/GENERIC"
 no file-system	FFS



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

2020-03-07 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Sun Mar  8 06:25:10 UTC 2020

Modified Files:
src/sys/arch/sun2/conf: GENERIC

Log Message:
Retire md(4) in favor of tmpfs provided by module,
though both are not useful for 8MB RAM system...


To generate a diff of this commit:
cvs rdiff -u -r1.103 -r1.104 src/sys/arch/sun2/conf/GENERIC

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/sun2/conf/GENERIC
diff -u src/sys/arch/sun2/conf/GENERIC:1.103 src/sys/arch/sun2/conf/GENERIC:1.104
--- src/sys/arch/sun2/conf/GENERIC:1.103	Sun Mar  8 06:23:18 2020
+++ src/sys/arch/sun2/conf/GENERIC	Sun Mar  8 06:25:10 2020
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.103 2020/03/08 06:23:18 rin Exp $
+# $NetBSD: GENERIC,v 1.104 2020/03/08 06:25:10 rin Exp $
 #
 # GENERIC machine description file
 # 
@@ -29,7 +29,7 @@ options 	INSECURE		# allow modload(8) in
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		"GENERIC-$Revision: 1.103 $"
+#ident 		"GENERIC-$Revision: 1.104 $"
 
 makeoptions	COPTS="-Os -fno-inline-small-functions"
 	# bootloader has size limit (~2MB)
@@ -228,7 +228,7 @@ options 	SCSI_OLD_NOINQUIRY
 #pseudo-device   accf_http		# "httpready" accept filter
 
 ## Memory-disk device.
-pseudo-device	md		
+#pseudo-device	md		
 
  Network interfaces.
 



CVS commit: src/sys/arch/sun2/sun2

2020-03-07 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Sun Mar  8 06:06:47 UTC 2020

Modified Files:
src/sys/arch/sun2/sun2: machdep.c

Log Message:
Support module(7).


To generate a diff of this commit:
cvs rdiff -u -r1.81 -r1.82 src/sys/arch/sun2/sun2/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/sun2/sun2/machdep.c
diff -u src/sys/arch/sun2/sun2/machdep.c:1.81 src/sys/arch/sun2/sun2/machdep.c:1.82
--- src/sys/arch/sun2/sun2/machdep.c:1.81	Sun Mar  8 06:05:05 2020
+++ src/sys/arch/sun2/sun2/machdep.c	Sun Mar  8 06:06:46 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: machdep.c,v 1.81 2020/03/08 06:05:05 rin Exp $	*/
+/*	$NetBSD: machdep.c,v 1.82 2020/03/08 06:06:46 rin Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1990, 1993
@@ -149,7 +149,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.81 2020/03/08 06:05:05 rin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.82 2020/03/08 06:06:46 rin Exp $");
 
 #include "opt_ddb.h"
 #include "opt_fpu_emulate.h"
@@ -172,6 +172,7 @@ __KERNEL_RCSID(0, "$NetBSD: machdep.c,v 
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -1167,3 +1168,13 @@ mm_md_kernacc(void *ptr, vm_prot_t prot,
 		return 0;
 	return EFAULT;
 }
+
+#ifdef MODULAR
+/*
+ * Push any modules loaded by the bootloader etc.
+ */
+void
+module_init_md(void)
+{
+}
+#endif



CVS commit: src/sys/arch/sun2/sun2

2020-03-07 Thread Rin Okuyama
Module Name:src
Committed By:   rin
Date:   Sun Mar  8 06:05:05 UTC 2020

Modified Files:
src/sys/arch/sun2/sun2: machdep.c

Log Message:
Sort headers.


To generate a diff of this commit:
cvs rdiff -u -r1.80 -r1.81 src/sys/arch/sun2/sun2/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/sun2/sun2/machdep.c
diff -u src/sys/arch/sun2/sun2/machdep.c:1.80 src/sys/arch/sun2/sun2/machdep.c:1.81
--- src/sys/arch/sun2/sun2/machdep.c:1.80	Tue Dec 31 13:07:12 2019
+++ src/sys/arch/sun2/sun2/machdep.c	Sun Mar  8 06:05:05 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: machdep.c,v 1.80 2019/12/31 13:07:12 ad Exp $	*/
+/*	$NetBSD: machdep.c,v 1.81 2020/03/08 06:05:05 rin Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1990, 1993
@@ -149,67 +149,67 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.80 2019/12/31 13:07:12 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.81 2020/03/08 06:05:05 rin Exp $");
 
 #include "opt_ddb.h"
-#include "opt_kgdb.h"
 #include "opt_fpu_emulate.h"
+#include "opt_kgdb.h"
 #include "opt_modular.h"
 
 #include 
-#include 
-#include 
-#include 
 #include 
-#include 
 #include 
-#include 
+#include 
+#include 
 #include 
-#include 
+#include 
+#include 		/* for MID_* */
 #include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
 #include 
+#include 
 #include 
-#include 
+#include 
+#include 
+#include 
+#include 
+#include 
 #include 
-#include 
-#include 
-#include 		/* for MID_* */
-#include 
-#include 
 #include 
-#include 
-#include 
-#include 
+
 #ifdef	KGDB
 #include 
 #endif
 
 #include  /* XXX: not _extern ... need vm_map_create */
 
-#include 
-
 #include 
 #include 
 
-#include 
+#define _SUN68K_BUS_DMA_PRIVATE
+#include 
+#include 
 #include 
 #include 
 #include 
+#include 
 #include 
-#include 
 #include 
+#include 
+#include 
 #include 
 #include 
-#define _SUN68K_BUS_DMA_PRIVATE
-#include 
-#include 
-#include 
-#include 
+#include 
 
 #if defined(DDB)
 #include 
-#include 
 #include 
+#include 
 #endif
 
 #include 



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

2019-04-03 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Apr  3 16:30:29 UTC 2019

Modified Files:
src/sys/arch/sun2/conf: RAMDISK

Log Message:
Gut more stuff so we fit. Last working RAMDISK kernel was 6.1.5.
Nobody runs this stuff anymore, so consider that netbsd 9 might be
the last sun2 release.


To generate a diff of this commit:
cvs rdiff -u -r1.59 -r1.60 src/sys/arch/sun2/conf/RAMDISK

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/sun2/conf/RAMDISK
diff -u src/sys/arch/sun2/conf/RAMDISK:1.59 src/sys/arch/sun2/conf/RAMDISK:1.60
--- src/sys/arch/sun2/conf/RAMDISK:1.59	Wed Aug  1 16:04:14 2018
+++ src/sys/arch/sun2/conf/RAMDISK	Wed Apr  3 12:30:28 2019
@@ -1,4 +1,4 @@
-# $NetBSD: RAMDISK,v 1.59 2018/08/01 20:04:14 maxv Exp $
+# $NetBSD: RAMDISK,v 1.60 2019/04/03 16:30:28 christos Exp $
 
 # RAMDISK: Root/swap on ramdisk
 # This kernel is used to:
@@ -27,7 +27,7 @@ maxusers	2
 #options 	SYSVSEM		# System V semaphores
 #options 	SYSVSHM		# System V shared memory
 #options 	INSECURE	# disable kernel security level
-options 	USERCONF	# userconf(4) support
+#options 	USERCONF	# userconf(4) support
 options 	PIPE_SOCKETPAIR	# smaller, but slower pipe(2)
 #options 	SYSCTL_INCLUDE_DESCR	# Include sysctl descriptions in kernel
 
@@ -51,12 +51,12 @@ options 	PIPE_SOCKETPAIR	# smaller, but 
 #options 	COMPAT_SUNOS	# can run SunOS 4.1.1 executables
 #options 	COMPAT_AOUT_M68K # support for NetBSD a.out executables
 #options 	EXEC_AOUT	# support for a.out executables
-options		COMPAT_BSDPTY	# /dev/[pt]ty?? ptys.
+#options		COMPAT_BSDPTY	# /dev/[pt]ty?? ptys.
 
 # Filesystem options
 file-system	FFS		# Berkeley Fast Filesystem
-file-system	NFS		# Sun NFS client support
-file-system	CD9660		# ISO 9660 + Rock Ridge file system
+#file-system	NFS		# Sun NFS client support
+#file-system	CD9660		# ISO 9660 + Rock Ridge file system
 #file-system	FDESC		# /dev/fd/*
 #file-system	KERNFS		# /kern
 #file-system	NULLFS		# loopback file system
@@ -70,7 +70,7 @@ file-system	CD9660		# ISO 9660 + Rock Ri
 #options 	QUOTA		# legacy UFS quotas
 #options 	QUOTA2		# new, in-filesystem UFS quotas
 #options 	FFS_EI		# FFS Endian Independent support
-options 	NFS_V2_ONLY	# Exclude NFS3 code to save space
+#options 	NFS_V2_ONLY	# Exclude NFS3 code to save space
 options 	FFS_NO_SNAPSHOT	# No FFS snapshot support
 
 # Networking options
@@ -172,7 +172,7 @@ scsibus* at sc?
 scsibus* at si?
 sd*	at scsibus? target ? lun ?		# SCSI disks
 st*	at scsibus? target ? lun ?		# SCSI tapes
-cd*	at scsibus? target ? lun ?		# SCSI CD-ROMs
+#cd*	at scsibus? target ? lun ?		# SCSI CD-ROMs
 #ch*	at scsibus? target ? lun ?		# SCSI changer devices
 #ss*	at scsibus? target ? lun ?		# SCSI scanners
 #ses*	at scsibus? target ? lun ?		# SCSI SES/SAF-TE
@@ -219,7 +219,7 @@ pcons0	at mainbus0			# PROM console
  Miscellaneous.
 pseudo-device	loop			# network loopback
 #pseudo-device	bpfilter		# packet filter
-pseudo-device	sl			# CSLIP
+#pseudo-device	sl			# CSLIP
 #pseudo-device	ppp			# PPP
 #pseudo-device	tun			# network tunneling over tty
 #pseudo-device	gre			# generic L3 over IP tunnel



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

2018-05-31 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Fri Jun  1 01:19:06 UTC 2018

Modified Files:
src/sys/arch/sun2/conf: FOURMEG

Log Message:
disable a few more things and return another 1% of memory.


To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/sys/arch/sun2/conf/FOURMEG

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/sun2/conf/FOURMEG
diff -u src/sys/arch/sun2/conf/FOURMEG:1.61 src/sys/arch/sun2/conf/FOURMEG:1.62
--- src/sys/arch/sun2/conf/FOURMEG:1.61	Thu Sep 14 07:58:43 2017
+++ src/sys/arch/sun2/conf/FOURMEG	Fri Jun  1 01:19:06 2018
@@ -1,4 +1,4 @@
-# $NetBSD: FOURMEG,v 1.61 2017/09/14 07:58:43 mrg Exp $
+# $NetBSD: FOURMEG,v 1.62 2018/06/01 01:19:06 mrg Exp $
 
 # FOURMEG Sun2 (2/120, 2/170, 2/50, ...)
 # Supports root on: ie0, sd*, ...
@@ -7,9 +7,9 @@ include "arch/sun2/conf/std.sun2"
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		"FOURMEG-$Revision: 1.61 $"
+#ident 		"FOURMEG-$Revision: 1.62 $"
 
-makeoptions	COPTS="-Os"	# optimize for size
+makeoptions	COPTS="-Os -fno-inline-small-functions"	# optimize for size
 
 # Machines to be supported by this kernel
 #options 	FPU_EMULATE
@@ -18,12 +18,12 @@ makeoptions	COPTS="-Os"	# optimize for s
 maxusers	4
 
 # Standard system options
-options 	KTRACE		# system call tracing
+#options 	KTRACE		# system call tracing
 #options 	SYSVMSG		# System V message queues
 #options 	SYSVSEM		# System V semaphores
 #options 	SYSVSHM		# System V shared memory
 #options 	INSECURE	# disable kernel security level
-options 	USERCONF	# userconf(4) support
+#options 	USERCONF	# userconf(4) support
 options		PIPE_SOCKETPAIR	# smaller, but slower pipe(2)
 #options 	SYSCTL_INCLUDE_DESCR	# Include sysctl descriptions in kernel
 
@@ -43,7 +43,7 @@ options		PIPE_SOCKETPAIR	# smaller, but 
 #options 	SCSIVERBOSE		# Verbose SCSI errors
 
 # Compatibility options
-include 	"conf/compat_netbsd70.config"
+#include 	"conf/compat_netbsd16.config"
 #options 	COMPAT_SUNOS	# can run SunOS 4.1.1 executables
 #options 	COMPAT_AOUT_M68K # support for NetBSD a.out executables
 #options 	EXEC_AOUT	# support for a.out executables
@@ -223,3 +223,8 @@ pseudo-device	pty			# pseudo-terminals
 #options 	RAID_AUTOCONFIG		# auto-configuration of RAID components
 #pseudo-device	fss			# file system snapshot device
 pseudo-device	clockctl		# user control of clock subsystem
+
+no options AIO
+no options BUFQ_FCFS
+no options RFC2292
+no options MQUEUE



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

2018-03-07 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Wed Mar  7 15:20:50 UTC 2018

Modified Files:
src/sys/arch/sun2/conf: Makefile.sun2

Log Message:
Remove more unused functions with COMPAT_AS=library


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/arch/sun2/conf/Makefile.sun2

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/sun2/conf/Makefile.sun2
diff -u src/sys/arch/sun2/conf/Makefile.sun2:1.21 src/sys/arch/sun2/conf/Makefile.sun2:1.22
--- src/sys/arch/sun2/conf/Makefile.sun2:1.21	Sat Mar  3 03:19:18 2018
+++ src/sys/arch/sun2/conf/Makefile.sun2	Wed Mar  7 15:20:50 2018
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.sun2,v 1.21 2018/03/03 03:19:18 mrg Exp $
+# $NetBSD: Makefile.sun2,v 1.22 2018/03/07 15:20:50 maya Exp $
 
 # Makefile for NetBSD
 #
@@ -38,11 +38,13 @@ AFLAGS+=	-x assembler-with-cpp
 ##
 ## (3) libkern and compat
 ##
-OPT_MODULAR=   %MODULAR%
+OPT_MODULAR=	%MODULAR%
 .if !empty(OPT_MODULAR)
-KERN_AS=   obj
+KERN_AS=	obj
+COMPAT_AS=	obj
 .else
-KERN_AS=   library
+KERN_AS=	library
+COMPAT_AS=	library
 .endif
 # XXX lib/libkern/arch/m68k/Makefile.inc needs to know that
 # XXX our MACHINE_ARCH is m68000, and not m68k.  --fredette



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

2018-03-02 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sat Mar  3 03:19:19 UTC 2018

Modified Files:
src/sys/arch/sun2/conf: Makefile.sun2

Log Message:
sun2/sun3:
- build libkern as an archive for non modular builds.  from maya@
sun3:
- cut down GENERIC a bunch to bring below 2MB.
- reduce UBC_NWINS, MAXEXEC, and PAGER_MAP_DEFAULT_SIZE to recover
  enough lost VA to actually run basic tests.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/sun2/conf/Makefile.sun2

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/sun2/conf/Makefile.sun2
diff -u src/sys/arch/sun2/conf/Makefile.sun2:1.20 src/sys/arch/sun2/conf/Makefile.sun2:1.21
--- src/sys/arch/sun2/conf/Makefile.sun2:1.20	Fri Jan 21 15:59:09 2011
+++ src/sys/arch/sun2/conf/Makefile.sun2	Sat Mar  3 03:19:18 2018
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.sun2,v 1.20 2011/01/21 15:59:09 joerg Exp $
+# $NetBSD: Makefile.sun2,v 1.21 2018/03/03 03:19:18 mrg Exp $
 
 # Makefile for NetBSD
 #
@@ -38,7 +38,12 @@ AFLAGS+=	-x assembler-with-cpp
 ##
 ## (3) libkern and compat
 ##
-KERN_AS=	obj
+OPT_MODULAR=   %MODULAR%
+.if !empty(OPT_MODULAR)
+KERN_AS=   obj
+.else
+KERN_AS=   library
+.endif
 # XXX lib/libkern/arch/m68k/Makefile.inc needs to know that
 # XXX our MACHINE_ARCH is m68000, and not m68k.  --fredette
 KERNMISCMAKEFLAGS=	MACHINE_ARCH=${MACHINE_ARCH}



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

2018-02-10 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Sat Feb 10 07:59:54 UTC 2018

Modified Files:
src/sys/arch/sun2/conf: GENERIC

Log Message:
Remove the last reference to IPSEC_ESP. This option was deleted in
2013.


To generate a diff of this commit:
cvs rdiff -u -r1.99 -r1.100 src/sys/arch/sun2/conf/GENERIC

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/sun2/conf/GENERIC
diff -u src/sys/arch/sun2/conf/GENERIC:1.99 src/sys/arch/sun2/conf/GENERIC:1.100
--- src/sys/arch/sun2/conf/GENERIC:1.99	Tue Jan 23 14:47:56 2018
+++ src/sys/arch/sun2/conf/GENERIC	Sat Feb 10 07:59:54 2018
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.99 2018/01/23 14:47:56 sevan Exp $
+# $NetBSD: GENERIC,v 1.100 2018/02/10 07:59:54 maxv Exp $
 #
 # GENERIC machine description file
 # 
@@ -25,7 +25,7 @@ include 	"arch/sun2/conf/std.sun2"
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		"GENERIC-$Revision: 1.99 $"
+#ident 		"GENERIC-$Revision: 1.100 $"
 
 makeoptions	COPTS="-Os"	# optimize for size
 
@@ -100,7 +100,6 @@ options 	FFS_NO_SNAPSHOT	# No FFS snapsh
 options 	INET		# IP protocol stack support
 #options 	INET6		# IPV6
 #options 	IPSEC		# IP security
-#options 	IPSEC_ESP	# IP security (encryption part; define w/IPSEC)
 #options 	IPSEC_DEBUG	# debug for IP security
 #options 	GATEWAY		# IP packet forwarding
 #options 	TCP_DEBUG	# Record last TCP_NDEBUG packets with SO_DEBUG



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

2014-07-26 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sat Jul 26 17:32:07 UTC 2014

Modified Files:
src/sys/arch/sun2/conf: GENERIC

Log Message:
Shrink GENERIC kernel to fit to bootloader's limit (2MB).

Maybe now we can't call it GENERIC, but it still boots on TME.


To generate a diff of this commit:
cvs rdiff -u -r1.89 -r1.90 src/sys/arch/sun2/conf/GENERIC

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/sun2/conf/GENERIC
diff -u src/sys/arch/sun2/conf/GENERIC:1.89 src/sys/arch/sun2/conf/GENERIC:1.90
--- src/sys/arch/sun2/conf/GENERIC:1.89	Sun Jun 30 21:38:59 2013
+++ src/sys/arch/sun2/conf/GENERIC	Sat Jul 26 17:32:07 2014
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.89 2013/06/30 21:38:59 rmind Exp $
+# $NetBSD: GENERIC,v 1.90 2014/07/26 17:32:07 tsutsui Exp $
 #
 # GENERIC machine description file
 # 
@@ -23,9 +23,9 @@
 
 include 	arch/sun2/conf/std.sun2
 
-options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
+#options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		GENERIC-$Revision: 1.89 $
+#ident 		GENERIC-$Revision: 1.90 $
 
 makeoptions	COPTS=-Os	# optimize for size
 
@@ -43,7 +43,7 @@ options 	SYSVSHM		# System V shared memo
 #options 	INSECURE	# disable kernel security level
 #options 	USERCONF	# userconf(4) support
 #options	PIPE_SOCKETPAIR	# smaller, but slower pipe(2)
-options 	SYSCTL_INCLUDE_DESCR	# Include sysctl descriptions in kernel
+#options 	SYSCTL_INCLUDE_DESCR	# Include sysctl descriptions in kernel
 
 # Enable experimental buffer queue strategy for better responsiveness under 
 # high disk I/O load. Use it with caution - it's not proven to be stable yet.
@@ -68,23 +68,23 @@ options 	DDB
 
 # Compatibility options
 #options 	COMPAT_SUNOS	# can run SunOS 4.1.1 executables
-options 	COMPAT_43	# and 4.3BSD and ...
+#options 	COMPAT_43	# and 4.3BSD and ...
 options 	COMPAT_16	# NetBSD 1.6
 options 	COMPAT_20	# NetBSD 2.0
 options 	COMPAT_30	# NetBSD 3.0
 options 	COMPAT_40	# NetBSD 4.0 compatibility.
 options 	COMPAT_50	# NetBSD 5.0 compatibility.
 options 	COMPAT_60	# NetBSD 6.0 compatibility.
-options 	COMPAT_AOUT_M68K # support for NetBSD a.out executables
+#options 	COMPAT_AOUT_M68K # support for NetBSD a.out executables
 #options 	TCP_COMPAT_42	# 4.2BSD TCP/IP bug compat. Not recommended.
-options 	EXEC_AOUT	# support for a.out executables
+#options 	EXEC_AOUT	# support for a.out executables
 options		COMPAT_BSDPTY	# /dev/[pt]ty?? ptys.
 
 # Filesystem options
 file-system	FFS		# Berkeley Fast Filesystem
 file-system	NFS		# Sun NFS client support
 file-system	CD9660		# ISO 9660 + Rock Ridge file system
-file-system	FDESC		# /dev/fd/*
+#file-system	FDESC		# /dev/fd/*
 file-system	KERNFS		# /kern
 file-system	NULLFS		# loopback file system
 #file-system	OVERLAY		# overlay file system
@@ -92,14 +92,14 @@ file-system	NULLFS		# loopback file syst
 #file-system	UNION		# union file system
 file-system	MFS		# memory-based filesystem
 file-system	PTYFS		# /dev/pts/N support
-file-system	TMPFS		# Efficient memory file-system
+#file-system	TMPFS		# Efficient memory file-system
 #file-system	UDF		# experimental - OSTA UDF CD/DVD file-system
 
-options 	NFSSERVER	# nfs server support
+#options 	NFSSERVER	# nfs server support
 #options 	QUOTA		# legacy UFS quotas
 #options 	QUOTA2		# new, in-filesystem UFS quotas
 #options 	FFS_EI		# FFS Endian Independent support
-options 	WAPBL		# File system journaling support
+#options 	WAPBL		# File system journaling support
 #options	UFS_DIRHASH	# UFS Large Directory Hashing - Experimental
 #options 	NFS_V2_ONLY	# Exclude NFS3 code to save space
 options 	FFS_NO_SNAPSHOT	# No FFS snapshot support
@@ -221,15 +221,15 @@ options 	SCSI_OLD_NOINQUIRY
 
 ## Xylogics 450 or 451 Multibus/VME SMD disk controllers and disks.
 #xyc0	at mbio0 addr 0xee40 ipl 2
-xyc0	at vme0 addr 0xee40 irq 2 vect 0x48
+#xyc0	at vme0 addr 0xee40 irq 2 vect 0x48
 #xyc1	at mbio0 addr 0xee48 ipl 2
-xyc1	at vme0 addr 0xee48 irq 2 vect 0x49
-xy*	at xyc? drive ?
+#xyc1	at vme0 addr 0xee48 irq 2 vect 0x49
+#xy*	at xyc? drive ?
 
 #
 # accept filters
-pseudo-device   accf_data		# dataready accept filter
-pseudo-device   accf_http		# httpready accept filter
+#pseudo-device   accf_data		# dataready accept filter
+#pseudo-device   accf_http		# httpready accept filter
 
 ## Memory-disk device.
 pseudo-device	md		
@@ -292,7 +292,7 @@ pseudo-device	pty			# pseudo-terminals
 # options 	RF_INCLUDE_PARITY_DECLUSTERING=1
 # options	RF_INCLUDE_PARITY_DECLUSTERING_DS=1
 #pseudo-device	fss			# file system snapshot device
-pseudo-device	clockctl		# user control of clock subsystem
+#pseudo-device	clockctl		# user control of clock subsystem
 pseudo-device	ksyms			# /dev/ksyms
 #pseudo-device	pf			# PF packet filter
 #pseudo-device	pflog			# PF log if



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

2014-07-26 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sat Jul 26 17:34:31 UTC 2014

Modified Files:
src/sys/arch/sun2/conf: DISKLESS FOURMEG INSTALL

Log Message:
Comment out options and devices to sync GENERIC rev 1.90.


To generate a diff of this commit:
cvs rdiff -u -r1.51 -r1.52 src/sys/arch/sun2/conf/DISKLESS
cvs rdiff -u -r1.55 -r1.56 src/sys/arch/sun2/conf/FOURMEG
cvs rdiff -u -r1.48 -r1.49 src/sys/arch/sun2/conf/INSTALL

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/sun2/conf/DISKLESS
diff -u src/sys/arch/sun2/conf/DISKLESS:1.51 src/sys/arch/sun2/conf/DISKLESS:1.52
--- src/sys/arch/sun2/conf/DISKLESS:1.51	Sun Jun 30 21:38:59 2013
+++ src/sys/arch/sun2/conf/DISKLESS	Sat Jul 26 17:34:31 2014
@@ -1,4 +1,4 @@
-# $NetBSD: DISKLESS,v 1.51 2013/06/30 21:38:59 rmind Exp $
+# $NetBSD: DISKLESS,v 1.52 2014/07/26 17:34:31 tsutsui Exp $
 
 # DISKLESS Sun2 (2/120, 2/170, 2/50, ...)
 # Supports root on: ie0, ec0
@@ -7,7 +7,7 @@ include arch/sun2/conf/std.sun2
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		DISKLESS-$Revision: 1.51 $
+#ident 		DISKLESS-$Revision: 1.52 $
 
 makeoptions	COPTS=-Os	# optimize for size
 
@@ -15,7 +15,7 @@ makeoptions	COPTS=-Os	# optimize for s
 #options 	FPU_EMULATE
 
 # Needs to be set per system.  i.e change these as you see fit
-maxusers	8
+maxusers	4
 
 # Standard system options
 options 	KTRACE		# system call tracing
@@ -23,7 +23,7 @@ options 	SYSVMSG		# System V message que
 options 	SYSVSEM		# System V semaphores
 options 	SYSVSHM		# System V shared memory
 #options 	INSECURE	# disable kernel security level
-options 	USERCONF	# userconf(4) support
+#options 	USERCONF	# userconf(4) support
 #options	PIPE_SOCKETPAIR	# smaller, but slower pipe(2)
 #options 	SYSCTL_INCLUDE_DESCR	# Include sysctl descriptions in kernel
 
@@ -45,26 +45,28 @@ options 	DDB
 
 # Compatibility options
 #options 	COMPAT_SUNOS	# can run SunOS 4.1.1 executables
-options 	COMPAT_43	# and 4.3BSD and ...
+#options 	COMPAT_43	# and 4.3BSD and ...
 options 	COMPAT_16	# NetBSD 1.6
 options 	COMPAT_20	# NetBSD 2.0
 options 	COMPAT_30	# NetBSD 3.0
 options 	COMPAT_40	# NetBSD 4.0 compatibility.
+options 	COMPAT_50	# NetBSD 5.0 compatibility.
+options 	COMPAT_60	# NetBSD 6.0 compatibility.
 #options 	COMPAT_AOUT_M68K # support for NetBSD a.out executables
 #options 	TCP_COMPAT_42	# 4.2BSD TCP/IP bug compat. Not recommended.
-options 	EXEC_AOUT	# support for a.out executables
+#options 	EXEC_AOUT	# support for a.out executables
 options		COMPAT_BSDPTY	# /dev/[pt]ty?? ptys.
 
 # Filesystem options
 #file-system	FFS		# Berkeley Fast Filesystem
 file-system	NFS		# Sun NFS client support
 #file-system	CD9660		# ISO 9660 + Rock Ridge file system
-file-system	FDESC		# /dev/fd/*
+#file-system	FDESC		# /dev/fd/*
 file-system	KERNFS		# /kern
 file-system	NULLFS		# loopback file system
-file-system	OVERLAY		# overlay file system
+#file-system	OVERLAY		# overlay file system
 #file-system	PROCFS		# /proc
-file-system	UNION		# union file system
+#file-system	UNION		# union file system
 file-system	MFS		# memory-based filesystem
 file-system	PTYFS		# /dev/pts/N support
 
@@ -229,4 +231,4 @@ pseudo-device	pty			# pseudo-terminals
 #options 	RAID_AUTOCONFIG		# auto-configuration of RAID components
 #pseudo-device	fss			# file system snapshot device
 
-pseudo-device	clockctl		# user control of clock subsystem
+#pseudo-device	clockctl		# user control of clock subsystem

Index: src/sys/arch/sun2/conf/FOURMEG
diff -u src/sys/arch/sun2/conf/FOURMEG:1.55 src/sys/arch/sun2/conf/FOURMEG:1.56
--- src/sys/arch/sun2/conf/FOURMEG:1.55	Sun Jun 30 21:38:59 2013
+++ src/sys/arch/sun2/conf/FOURMEG	Sat Jul 26 17:34:31 2014
@@ -1,4 +1,4 @@
-# $NetBSD: FOURMEG,v 1.55 2013/06/30 21:38:59 rmind Exp $
+# $NetBSD: FOURMEG,v 1.56 2014/07/26 17:34:31 tsutsui Exp $
 
 # FOURMEG Sun2 (2/120, 2/170, 2/50, ...)
 # Supports root on: ie0, sd*, ...
@@ -7,7 +7,7 @@ include arch/sun2/conf/std.sun2
 
 #options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		FOURMEG-$Revision: 1.55 $
+#ident 		FOURMEG-$Revision: 1.56 $
 
 makeoptions	COPTS=-Os	# optimize for size
 
@@ -50,9 +50,11 @@ options 	COMPAT_16	# NetBSD 1.6
 options 	COMPAT_20	# NetBSD 2.0
 options 	COMPAT_30	# NetBSD 3.0
 options 	COMPAT_40	# NetBSD 4.0 compatibility.
+options 	COMPAT_50	# NetBSD 5.0 compatibility.
+options 	COMPAT_60	# NetBSD 6.0 compatibility.
 #options 	COMPAT_AOUT_M68K # support for NetBSD a.out executables
 #options 	TCP_COMPAT_42	# 4.2BSD TCP/IP bug compat. Not recommended.
-options 	EXEC_AOUT	# support for a.out executables
+#options 	EXEC_AOUT	# support for a.out executables
 options		COMPAT_BSDPTY	# /dev/[pt]ty?? ptys.
 
 # Filesystem options
@@ -178,10 +180,10 @@ options 	SCSI_OLD_NOINQUIRY
 
 ## Xylogics 450 or 451 Multibus/VME SMD disk controllers and disks.
 #xyc0	at mbio0 addr 0xee40 ipl 2
-xyc0	at vme0 

CVS commit: src/sys/arch/sun2/sun2

2014-03-24 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Mon Mar 24 18:50:08 UTC 2014

Modified Files:
src/sys/arch/sun2/sun2: locore.s

Log Message:
avoid local redefinitions


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/sun2/sun2/locore.s

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/sun2/sun2/locore.s
diff -u src/sys/arch/sun2/sun2/locore.s:1.24 src/sys/arch/sun2/sun2/locore.s:1.25
--- src/sys/arch/sun2/sun2/locore.s:1.24	Tue Nov 15 05:57:04 2011
+++ src/sys/arch/sun2/sun2/locore.s	Mon Mar 24 14:50:08 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: locore.s,v 1.24 2011/11/15 10:57:04 tsutsui Exp $	*/
+/*	$NetBSD: locore.s,v 1.25 2014/03/24 18:50:08 christos Exp $	*/
 
 /*
  * Copyright (c) 1980, 1990, 1993
@@ -400,12 +400,6 @@ Lbrkpt2:
  *   %d0,%d1,%a0,%a1, sr, pc, vo
  */
 
-#define INTERRUPT_SAVEREG \
-	moveml	#0xC0C0,%sp@-
-
-#define INTERRUPT_RESTORE \
-	moveml	%sp@+,#0x0303
-
 /*
  * This is the common auto-vector interrupt handler,
  * for which the CPU provides the vector=0x18+level.
@@ -419,7 +413,7 @@ Lbrkpt2:
 GLOBAL(_isr_autovec)
 	INTERRUPT_SAVEREG
 	jbsr	_C_LABEL(isr_autovec)
-	INTERRUPT_RESTORE
+	INTERRUPT_RESTOREREG
 	jra	_ASM_LABEL(rei)
 
 /* clock: see clock.c */
@@ -431,7 +425,7 @@ GLOBAL(_isr_autovec)
 GLOBAL(_isr_clock)
 	INTERRUPT_SAVEREG
 	jbsr	_C_LABEL(clock_intr)
-	INTERRUPT_RESTORE
+	INTERRUPT_RESTOREREG
 	jra	_ASM_LABEL(rei)
 
 | Handler for all vectored interrupts (i.e. VME interrupts)
@@ -443,12 +437,9 @@ GLOBAL(_isr_clock)
 GLOBAL(_isr_vectored)
 	INTERRUPT_SAVEREG
 	jbsr	_C_LABEL(isr_vectored)
-	INTERRUPT_RESTORE
+	INTERRUPT_RESTOREREG
 	jra	_ASM_LABEL(rei)
 
-#undef	INTERRUPT_SAVEREG
-#undef	INTERRUPT_RESTORE
-
 /* interrupt counters (needed by vmstat) */
 GLOBAL(intrnames)
 	.asciz	spur	| 0



CVS commit: src/sys/arch/sun2

2014-03-24 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Mon Mar 24 18:50:31 UTC 2014

Modified Files:
src/sys/arch/sun2/dev: if_ie_obio.c
src/sys/arch/sun2/sun2: machdep.c pmap.c promlib.c

Log Message:
- remove unused
- use cpu_{g,s}etmodel


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/sun2/dev/if_ie_obio.c
cvs rdiff -u -r1.76 -r1.77 src/sys/arch/sun2/sun2/machdep.c
cvs rdiff -u -r1.46 -r1.47 src/sys/arch/sun2/sun2/pmap.c
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/sun2/sun2/promlib.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/sun2/dev/if_ie_obio.c
diff -u src/sys/arch/sun2/dev/if_ie_obio.c:1.15 src/sys/arch/sun2/dev/if_ie_obio.c:1.16
--- src/sys/arch/sun2/dev/if_ie_obio.c:1.15	Fri Jun  3 12:28:40 2011
+++ src/sys/arch/sun2/dev/if_ie_obio.c	Mon Mar 24 14:50:31 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_ie_obio.c,v 1.15 2011/06/03 16:28:40 tsutsui Exp $	*/
+/*	$NetBSD: if_ie_obio.c,v 1.16 2014/03/24 18:50:31 christos Exp $	*/
 
 /*-
  * Copyright (c) 1997 The NetBSD Foundation, Inc.
@@ -73,7 +73,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: if_ie_obio.c,v 1.15 2011/06/03 16:28:40 tsutsui Exp $);
+__KERNEL_RCSID(0, $NetBSD: if_ie_obio.c,v 1.16 2014/03/24 18:50:31 christos Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -260,7 +260,6 @@ ie_obio_attach(device_t parent, device_t
 	int rseg;
 	int error;
 	paddr_t pa;
-	struct intrhand *ih;
 	bus_size_t memsize;
 	u_long iebase;
 	uint8_t myaddr[ETHER_ADDR_LEN];
@@ -393,6 +392,6 @@ ie_obio_attach(device_t parent, device_t
 	i82586_attach(sc, onboard, myaddr, media, NMEDIA, media[0]);
 
 	/* Establish interrupt channel */
-	ih = bus_intr_establish(oba-oba_bustag, oba-oba_pri, IPL_NET, 0,
-i82586_intr, sc);
+	bus_intr_establish(oba-oba_bustag, oba-oba_pri, IPL_NET, 0,
+	i82586_intr, sc);
 }

Index: src/sys/arch/sun2/sun2/machdep.c
diff -u src/sys/arch/sun2/sun2/machdep.c:1.76 src/sys/arch/sun2/sun2/machdep.c:1.77
--- src/sys/arch/sun2/sun2/machdep.c:1.76	Fri Aug 10 10:52:26 2012
+++ src/sys/arch/sun2/sun2/machdep.c	Mon Mar 24 14:50:31 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: machdep.c,v 1.76 2012/08/10 14:52:26 tsutsui Exp $	*/
+/*	$NetBSD: machdep.c,v 1.77 2014/03/24 18:50:31 christos Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1990, 1993
@@ -149,7 +149,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.76 2012/08/10 14:52:26 tsutsui Exp $);
+__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.77 2014/03/24 18:50:31 christos Exp $);
 
 #include opt_ddb.h
 #include opt_kgdb.h
@@ -179,6 +179,7 @@ __KERNEL_RCSID(0, $NetBSD: machdep.c,v 
 #include sys/vnode.h
 #include sys/syscallargs.h
 #include sys/ksyms.h
+#include sys/cpu.h
 #ifdef	KGDB
 #include sys/kgdb.h
 #endif
@@ -366,7 +367,6 @@ cpu_startup(void)
  */
 char	machine[16] = MACHINE;		/* from machine/param.h */
 char	kernel_arch[16] = sun2;	/* XXX needs a sysctl node */
-char	cpu_model[120];
 
 /*
  * Determine which Sun2 model we are running on.
@@ -378,9 +378,9 @@ identifycpu(void)
 
 	/* Other stuff? (VAC, mc6888x version, etc.) */
 	/* Note: miniroot cares about the kernel_arch part. */
-	sprintf(cpu_model, %s %s, kernel_arch, cpu_string);
+	cpu_setmodel(%s %s, kernel_arch, cpu_string);
 
-	printf(Model: %s\n, cpu_model);
+	printf(Model: %s\n, cpu_getmodel());
 }
 
 /*
@@ -879,7 +879,7 @@ _bus_dmamap_load(bus_dma_tag_t t, bus_dm
 	int pagesz = PAGE_SIZE;
 	bus_addr_t dva;
 	pmap_t pmap;
-	int rv;
+	int rv __diagused;
 
 	/*
 	 * Make sure that on error condition we return no valid mappings.

Index: src/sys/arch/sun2/sun2/pmap.c
diff -u src/sys/arch/sun2/sun2/pmap.c:1.46 src/sys/arch/sun2/sun2/pmap.c:1.47
--- src/sys/arch/sun2/sun2/pmap.c:1.46	Mon Jan  7 11:58:09 2013
+++ src/sys/arch/sun2/sun2/pmap.c	Mon Mar 24 14:50:31 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.46 2013/01/07 16:58:09 chs Exp $	*/
+/*	$NetBSD: pmap.c,v 1.47 2014/03/24 18:50:31 christos Exp $	*/
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -82,7 +82,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.46 2013/01/07 16:58:09 chs Exp $);
+__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.47 2014/03/24 18:50:31 christos Exp $);
 
 #include opt_ddb.h
 #include opt_pmap_debug.h
@@ -1324,15 +1324,12 @@ pv_link(pmap_t pmap, int pte, vaddr_t va
 	paddr_t pa;
 	pv_entry_t *head, pv;
 	u_char *pv_flags;
-	int flags;
 
 	if (!pv_initialized)
 		return 0;
 
 	CHECK_SPL();
 
-	/* Only the non-cached bit is of interest here. */
-	flags = (pte  PG_NC) ? PV_NC : 0;
 	pa = PG_PA(pte);
 
 #ifdef PMAP_DEBUG
@@ -1357,6 +1354,8 @@ pv_link(pmap_t pmap, int pte, vaddr_t va
 	/*
 	 * Does this new mapping cause VAC alias problems?
 	 */
+	/* Only the non-cached bit is of interest here. */
+	int flags = (pte  PG_NC) ? PV_NC : 0;
 
 	*pv_flags |= flags;
 	if ((*pv_flags  PV_NC) == 0) {
@@ -3070,9 +3069,8 @@ out:
 void 
 pmap_protect_mmu(pmap_t pmap, 

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

2013-01-09 Thread Havard Eidnes
Module Name:src
Committed By:   he
Date:   Wed Jan  9 08:11:09 UTC 2013

Modified Files:
src/sys/arch/sun2/include: pmap.h

Log Message:
The pmap_prefer() function grew an additional argument with the introduction
of top-down VM; fix the prototype accordingly.


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/sun2/include/pmap.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/sun2/include/pmap.h
diff -u src/sys/arch/sun2/include/pmap.h:1.25 src/sys/arch/sun2/include/pmap.h:1.26
--- src/sys/arch/sun2/include/pmap.h:1.25	Mon Jan  7 16:58:08 2013
+++ src/sys/arch/sun2/include/pmap.h	Wed Jan  9 08:11:09 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.h,v 1.25 2013/01/07 16:58:08 chs Exp $	*/
+/*	$NetBSD: pmap.h,v 1.26 2013/01/09 08:11:09 he Exp $	*/
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -50,7 +50,7 @@ struct pmap {
 int _pmap_fault(struct vm_map *, vaddr_t, vm_prot_t);
 
 /* This lets us have some say in choosing VA locations. */
-extern void pmap_prefer(vaddr_t, vaddr_t *);
+extern void pmap_prefer(vaddr_t, vaddr_t *, int);
 #define PMAP_PREFER(fo, ap, sz, td) pmap_prefer((fo), (ap), (td))
 
 /* This needs to be a macro for kern_sysctl.c */



CVS commit: src/sys/arch/sun2

2012-10-13 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sat Oct 13 06:28:54 UTC 2012

Modified Files:
src/sys/arch/sun2/dev: zs.c
src/sys/arch/sun2/sun2: obmem.c

Log Message:
struct device * - device_t, struct cfdata * - cfdata_t  (from chs@)


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/sun2/dev/zs.c
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/sun2/sun2/obmem.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/sun2/dev/zs.c
diff -u src/sys/arch/sun2/dev/zs.c:1.20 src/sys/arch/sun2/dev/zs.c:1.21
--- src/sys/arch/sun2/dev/zs.c:1.20	Wed Oct 26 00:56:59 2011
+++ src/sys/arch/sun2/dev/zs.c	Sat Oct 13 06:28:54 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: zs.c,v 1.20 2011/10/26 00:56:59 mrg Exp $	*/
+/*	$NetBSD: zs.c,v 1.21 2012/10/13 06:28:54 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -38,7 +38,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: zs.c,v 1.20 2011/10/26 00:56:59 mrg Exp $);
+__KERNEL_RCSID(0, $NetBSD: zs.c,v 1.21 2012/10/13 06:28:54 tsutsui Exp $);
 
 #include opt_ddb.h
 #include opt_kgdb.h
@@ -170,7 +170,7 @@ zs_attach(struct zsc_softc *zsc, struct 
 	 */
 	for (channel = 0; channel  2; channel++) {
 		struct zschan *zc;
-		struct device *child;
+		device_t child;
 
 		zsc_args.channel = channel;
 		zsc_args.hwflags = 0;

Index: src/sys/arch/sun2/sun2/obmem.c
diff -u src/sys/arch/sun2/sun2/obmem.c:1.17 src/sys/arch/sun2/sun2/obmem.c:1.18
--- src/sys/arch/sun2/sun2/obmem.c:1.17	Sun Jul  6 13:29:50 2008
+++ src/sys/arch/sun2/sun2/obmem.c	Sat Oct 13 06:28:54 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: obmem.c,v 1.17 2008/07/06 13:29:50 tsutsui Exp $	*/
+/*	$NetBSD: obmem.c,v 1.18 2012/10/13 06:28:54 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: obmem.c,v 1.17 2008/07/06 13:29:50 tsutsui Exp $);
+__KERNEL_RCSID(0, $NetBSD: obmem.c,v 1.18 2012/10/13 06:28:54 tsutsui Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -77,7 +77,7 @@ static struct sun68k_bus_space_tag obmem
 }; 
 
 static int 
-obmem_match(struct device *parent, struct cfdata *cf, void *aux)
+obmem_match(device_t parent, cfdata_t cf, void *aux)
 {
 	struct mainbus_attach_args *ma = aux;
 



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

2012-08-11 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sat Aug 11 17:03:26 UTC 2012

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

Log Message:
Poor sun2 has only 14MB KVA space so reduce NKMEMPAGES_MIN_DEFAULT and
NKMEMPAGES_MAX_DEFAULT values accordingly.

XXX: netbsd-6 GENERIC still gets panic: pool_get: kmem-4096: page empty


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/sun2/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/sun2/include/param.h
diff -u src/sys/arch/sun2/include/param.h:1.14 src/sys/arch/sun2/include/param.h:1.15
--- src/sys/arch/sun2/include/param.h:1.14	Fri Feb 10 17:35:48 2012
+++ src/sys/arch/sun2/include/param.h	Sat Aug 11 17:03:26 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: param.h,v 1.14 2012/02/10 17:35:48 para Exp $	*/
+/*	$NetBSD: param.h,v 1.15 2012/08/11 17:03:26 tsutsui Exp $	*/
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -90,8 +90,8 @@
  * Minimum and maximum sizes of the kernel malloc arena in PAGE_SIZE-sized
  * logical pages.
  */
-#define	NKMEMPAGES_MIN_DEFAULT	((8 * 1024 * 1024)  PAGE_SHIFT)
-#define	NKMEMPAGES_MAX_DEFAULT	((32 * 1024 * 1024)  PAGE_SHIFT)
+#define	NKMEMPAGES_MIN_DEFAULT	((4 * 1024 * 1024)  PAGE_SHIFT)
+#define	NKMEMPAGES_MAX_DEFAULT	((8 * 1024 * 1024)  PAGE_SHIFT)
 
 #if defined(_KERNEL)  !defined(_LOCORE)
 



CVS commit: src/sys/arch/sun2

2012-08-10 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Fri Aug 10 14:52:26 UTC 2012

Modified Files:
src/sys/arch/sun2/dev: consinit.c
src/sys/arch/sun2/sun2: locore2.c machdep.c

Log Message:
Move cn_tab initialization from late cpu_startup(9) to
early _bootstrap() in locore2.c.
Tested on TME emulating 2/120.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/sun2/dev/consinit.c
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/sun2/sun2/locore2.c
cvs rdiff -u -r1.75 -r1.76 src/sys/arch/sun2/sun2/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/sun2/dev/consinit.c
diff -u src/sys/arch/sun2/dev/consinit.c:1.8 src/sys/arch/sun2/dev/consinit.c:1.9
--- src/sys/arch/sun2/dev/consinit.c:1.8	Mon Jul 30 17:27:20 2012
+++ src/sys/arch/sun2/dev/consinit.c	Fri Aug 10 14:52:26 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: consinit.c,v 1.8 2012/07/30 17:27:20 christos Exp $	*/
+/*	$NetBSD: consinit.c,v 1.9 2012/08/10 14:52:26 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 2001 Matthew Fredette
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: consinit.c,v 1.8 2012/07/30 17:27:20 christos Exp $);
+__KERNEL_RCSID(0, $NetBSD: consinit.c,v 1.9 2012/08/10 14:52:26 tsutsui Exp $);
 
 #include opt_ddb.h
 #include opt_kgdb.h
@@ -95,16 +95,6 @@ struct consdev consdev_prom = {
 	NULL,
 };
 
-/*
- * The console table pointer is statically initialized
- * to point to the PROM (output only) table, so that
- * early calls to printf will work. This has been moved
- * to cpu_startup()
- */
-#if 0
-struct consdev *cn_tab = consdev_prom;
-#endif
-
 void 
 prom_cnprobe(struct consdev *cd)
 {

Index: src/sys/arch/sun2/sun2/locore2.c
diff -u src/sys/arch/sun2/sun2/locore2.c:1.25 src/sys/arch/sun2/sun2/locore2.c:1.26
--- src/sys/arch/sun2/sun2/locore2.c:1.25	Sun Jul 17 20:54:48 2011
+++ src/sys/arch/sun2/sun2/locore2.c	Fri Aug 10 14:52:26 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: locore2.c,v 1.25 2011/07/17 20:54:48 joerg Exp $	*/
+/*	$NetBSD: locore2.c,v 1.26 2012/08/10 14:52:26 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: locore2.c,v 1.25 2011/07/17 20:54:48 joerg Exp $);
+__KERNEL_RCSID(0, $NetBSD: locore2.c,v 1.26 2012/08/10 14:52:26 tsutsui Exp $);
 
 #include opt_ddb.h
 #include opt_modular.h
@@ -44,6 +44,8 @@ __KERNEL_RCSID(0, $NetBSD: locore2.c,v 
 
 #include uvm/uvm_extern.h
 
+#include dev/cons.h
+
 #include machine/cpu.h
 #include machine/db_machdep.h
 #include machine/dvma.h
@@ -255,6 +257,7 @@ _verify_hardware(void)
 void 
 _bootstrap(void)
 {
+	extern struct consdev consdev_prom;	/* XXX */
 	vaddr_t va;
 
 	/* First, Clear BSS. */
@@ -263,6 +266,12 @@ _bootstrap(void)
 	/* Initialize the PROM. */
 	prom_init();
 
+	/*
+	 * Initialize console to point to the PROM (output only) table
+	 * for early printf calls.
+	 */
+	cn_tab = consdev_prom;
+
 	/* Copy the IDPROM from control space. */
 	idprom_init();
 

Index: src/sys/arch/sun2/sun2/machdep.c
diff -u src/sys/arch/sun2/sun2/machdep.c:1.75 src/sys/arch/sun2/sun2/machdep.c:1.76
--- src/sys/arch/sun2/sun2/machdep.c:1.75	Mon Jul 30 17:27:20 2012
+++ src/sys/arch/sun2/sun2/machdep.c	Fri Aug 10 14:52:26 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: machdep.c,v 1.75 2012/07/30 17:27:20 christos Exp $	*/
+/*	$NetBSD: machdep.c,v 1.76 2012/08/10 14:52:26 tsutsui Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1990, 1993
@@ -149,7 +149,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.75 2012/07/30 17:27:20 christos Exp $);
+__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.76 2012/08/10 14:52:26 tsutsui Exp $);
 
 #include opt_ddb.h
 #include opt_kgdb.h
@@ -258,7 +258,6 @@ static vaddr_t dumppage;
 
 static void identifycpu(void);
 static void initcpu(void);
-extern struct consdev *cn_tab, consdev_prom;
 
 /*
  * cpu_startup: allocate memory for variable-sized tables,
@@ -275,7 +274,6 @@ cpu_startup(void)
 	vaddr_t minaddr, maxaddr;
 	char pbuf[9];
 
-	cn_tab = consdev_prom;
 	/*
 	 * Initialize message buffer (for kernel printf).
 	 * This is put in physical pages four through seven



CVS commit: src/sys/arch/sun2

2012-07-30 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Mon Jul 30 17:27:20 UTC 2012

Modified Files:
src/sys/arch/sun2/dev: consinit.c
src/sys/arch/sun2/sun2: machdep.c

Log Message:
move console initialization to cpu_startup() so that we avoid multiple common.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/sun2/dev/consinit.c
cvs rdiff -u -r1.74 -r1.75 src/sys/arch/sun2/sun2/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/sun2/dev/consinit.c
diff -u src/sys/arch/sun2/dev/consinit.c:1.7 src/sys/arch/sun2/dev/consinit.c:1.8
--- src/sys/arch/sun2/dev/consinit.c:1.7	Sun Dec 27 03:41:50 2009
+++ src/sys/arch/sun2/dev/consinit.c	Mon Jul 30 13:27:20 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: consinit.c,v 1.7 2009/12/27 08:41:50 tsutsui Exp $	*/
+/*	$NetBSD: consinit.c,v 1.8 2012/07/30 17:27:20 christos Exp $	*/
 
 /*-
  * Copyright (c) 2001 Matthew Fredette
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: consinit.c,v 1.7 2009/12/27 08:41:50 tsutsui Exp $);
+__KERNEL_RCSID(0, $NetBSD: consinit.c,v 1.8 2012/07/30 17:27:20 christos Exp $);
 
 #include opt_ddb.h
 #include opt_kgdb.h
@@ -98,9 +98,12 @@ struct consdev consdev_prom = {
 /*
  * The console table pointer is statically initialized
  * to point to the PROM (output only) table, so that
- * early calls to printf will work.
+ * early calls to printf will work. This has been moved
+ * to cpu_startup()
  */
+#if 0
 struct consdev *cn_tab = consdev_prom;
+#endif
 
 void 
 prom_cnprobe(struct consdev *cd)

Index: src/sys/arch/sun2/sun2/machdep.c
diff -u src/sys/arch/sun2/sun2/machdep.c:1.74 src/sys/arch/sun2/sun2/machdep.c:1.75
--- src/sys/arch/sun2/sun2/machdep.c:1.74	Sat Jul 28 15:08:25 2012
+++ src/sys/arch/sun2/sun2/machdep.c	Mon Jul 30 13:27:20 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: machdep.c,v 1.74 2012/07/28 19:08:25 matt Exp $	*/
+/*	$NetBSD: machdep.c,v 1.75 2012/07/30 17:27:20 christos Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1990, 1993
@@ -149,7 +149,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.74 2012/07/28 19:08:25 matt Exp $);
+__KERNEL_RCSID(0, $NetBSD: machdep.c,v 1.75 2012/07/30 17:27:20 christos Exp $);
 
 #include opt_ddb.h
 #include opt_kgdb.h
@@ -258,6 +258,7 @@ static vaddr_t dumppage;
 
 static void identifycpu(void);
 static void initcpu(void);
+extern struct consdev *cn_tab, consdev_prom;
 
 /*
  * cpu_startup: allocate memory for variable-sized tables,
@@ -274,6 +275,7 @@ cpu_startup(void)
 	vaddr_t minaddr, maxaddr;
 	char pbuf[9];
 
+	cn_tab = consdev_prom;
 	/*
 	 * Initialize message buffer (for kernel printf).
 	 * This is put in physical pages four through seven



CVS commit: src/sys/arch/sun2/sun2

2012-01-31 Thread Lars Heidieker
Module Name:src
Committed By:   para
Date:   Tue Jan 31 22:47:08 UTC 2012

Modified Files:
src/sys/arch/sun2/sun2: pmap.c

Log Message:
unbreak the sun2 pmap


To generate a diff of this commit:
cvs rdiff -u -r1.44 -r1.45 src/sys/arch/sun2/sun2/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/sun2/sun2/pmap.c
diff -u src/sys/arch/sun2/sun2/pmap.c:1.44 src/sys/arch/sun2/sun2/pmap.c:1.45
--- src/sys/arch/sun2/sun2/pmap.c:1.44	Fri Jun  3 17:03:52 2011
+++ src/sys/arch/sun2/sun2/pmap.c	Tue Jan 31 22:47:08 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.44 2011/06/03 17:03:52 tsutsui Exp $	*/
+/*	$NetBSD: pmap.c,v 1.45 2012/01/31 22:47:08 para Exp $	*/
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -82,7 +82,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.44 2011/06/03 17:03:52 tsutsui Exp $);
+__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.45 2012/01/31 22:47:08 para Exp $);
 
 #include opt_ddb.h
 #include opt_pmap_debug.h
@@ -90,7 +90,7 @@ __KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.4
 #include sys/param.h
 #include sys/systm.h
 #include sys/proc.h
-#include sys/malloc.h
+#include sys/kmem.h
 #include sys/pool.h
 #include sys/queue.h
 #include sys/kcore.h
@@ -1820,7 +1820,7 @@ void 
 pmap_user_init(pmap_t pmap)
 {
 	int i;
-	pmap-pm_segmap = malloc(sizeof(char)*NUSEG, M_VMPMAP, M_WAITOK);
+	pmap-pm_segmap = kmem_alloc(sizeof(char)*NUSEG, KM_SLEEP);
 	for (i = 0; i  NUSEG; i++) {
 		pmap-pm_segmap[i] = SEGINV;
 	}
@@ -1871,7 +1871,7 @@ pmap_release(struct pmap *pmap)
 #endif
 		context_free(pmap);
 	}
-	free(pmap-pm_segmap, M_VMPMAP);
+	kmem_free(pmap-pm_segmap, sizeof(char)*NUSEG);
 	pmap-pm_segmap = NULL;
 
 	splx(s);



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

2011-10-25 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Wed Oct 26 00:57:37 UTC 2011

Modified Files:
src/sys/arch/sun2/conf: GENERIC

Log Message:
revert previous.


To generate a diff of this commit:
cvs rdiff -u -r1.79 -r1.80 src/sys/arch/sun2/conf/GENERIC

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/sun2/conf/GENERIC
diff -u src/sys/arch/sun2/conf/GENERIC:1.79 src/sys/arch/sun2/conf/GENERIC:1.80
--- src/sys/arch/sun2/conf/GENERIC:1.79	Wed Oct 26 00:56:59 2011
+++ src/sys/arch/sun2/conf/GENERIC	Wed Oct 26 00:57:36 2011
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.79 2011/10/26 00:56:59 mrg Exp $
+# $NetBSD: GENERIC,v 1.80 2011/10/26 00:57:36 mrg Exp $
 #
 # GENERIC machine description file
 # 
@@ -25,7 +25,7 @@ include 	arch/sun2/conf/std.sun2
 
 options 	INCLUDE_CONFIG_FILE	# embed config file in kernel binary
 
-#ident 		GENERIC-$Revision: 1.79 $
+#ident 		GENERIC-$Revision: 1.80 $
 
 makeoptions	COPTS=-Os	# optimize for size
 
@@ -54,12 +54,11 @@ options 	SYSCTL_INCLUDE_DESCR	# Include 
 # Which kernel debugger?  Uncomment either this:
 options 	DDB
 # ... or these for KGDB (gdb remote target)
-makeoptions	DEBUG=-g	# debugging symbols for gdb
+#makeoptions	DEBUG=-g	# debugging symbols for gdb
 #options 	KGDB
 #options 	KGDB_DEV=0x0C00	# ttya=0C00 ttyb=0C01
 
 # Other debugging options
-options 	DDB_COMMANDONENTER=trace
 #options 	DDB_HISTORY_SIZE=100	# enable history editing in DDB
 #options 	DEBUG		# kernel debugging code
 #options 	DIAGNOSTIC	# extra kernel sanity checking



CVS commit: src/sys/arch/sun2/sun2

2011-06-14 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Tue Jun 14 15:51:36 UTC 2011

Modified Files:
src/sys/arch/sun2/sun2: mm_md.c

Log Message:
Remove duplicated functions that are implemented in machdep.c.

XXX: why do only sun2 and sun3 (and sun3x) have separate mm_md.c?


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

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

Modified files:

Index: src/sys/arch/sun2/sun2/mm_md.c
diff -u src/sys/arch/sun2/sun2/mm_md.c:1.2 src/sys/arch/sun2/sun2/mm_md.c:1.3
--- src/sys/arch/sun2/sun2/mm_md.c:1.2	Sun Jun 12 03:35:47 2011
+++ src/sys/arch/sun2/sun2/mm_md.c	Tue Jun 14 15:51:35 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: mm_md.c,v 1.2 2011/06/12 03:35:47 rmind Exp $	*/
+/*	$NetBSD: mm_md.c,v 1.3 2011/06/14 15:51:35 tsutsui Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1990, 1993
@@ -76,7 +76,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: mm_md.c,v 1.2 2011/06/12 03:35:47 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: mm_md.c,v 1.3 2011/06/14 15:51:35 tsutsui Exp $);
 
 #include sys/param.h
 #include sys/errno.h
@@ -91,45 +91,6 @@
 #define DEV_LEDS	13 	/* minor device 13 is leds */
 
 int
-mm_md_physacc(paddr_t pa, vm_prot_t prot)
-{
-
-	/* Allow access only in managed RAM. */
-	if (pa  avail_start || pa = avail_end)
-		return EFAULT;
-	return 0;
-}
-
-bool
-mm_md_direct_mapped_phys(paddr_t paddr, vaddr_t *vaddr)
-{
-
-	if (paddr = avail_start)
-		return false;
-	*vaddr = paddr;
-	return true;
-}
-
-/*
- * Allow access to the PROM mapping similiar to uvm_kernacc().
- */
-int
-mm_md_kernacc(void *ptr, vm_prot_t prot, bool *handled)
-{
-
-	if ((vaddr_t)ptr  SUN2_PROM_BASE || (vaddr_t)ptr  SUN2_MONEND) {
-		*handled = false;
-		return 0;
-	}
-
-	*handled = true;
-	/* Read in the PROM itself is OK, write not. */
-	if ((prot  VM_PROT_WRITE) == 0)
-		return 0;
-	return EFAULT;
-}
-
-int
 mm_md_readwrite(dev_t dev, struct uio *uio)
 {
 



CVS commit: src/sys/arch/sun2/dev

2009-12-27 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Sun Dec 27 08:41:50 UTC 2009

Modified Files:
src/sys/arch/sun2/dev: consinit.c

Log Message:
Fix missing parenthesis in #ifdef notyet block. PR port-sun2/42524


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/sun2/dev/consinit.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/sun2/dev/consinit.c
diff -u src/sys/arch/sun2/dev/consinit.c:1.6 src/sys/arch/sun2/dev/consinit.c:1.7
--- src/sys/arch/sun2/dev/consinit.c:1.6	Sun Dec 11 12:19:16 2005
+++ src/sys/arch/sun2/dev/consinit.c	Sun Dec 27 08:41:50 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: consinit.c,v 1.6 2005/12/11 12:19:16 christos Exp $	*/
+/*	$NetBSD: consinit.c,v 1.7 2009/12/27 08:41:50 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 2001 Matthew Fredette
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: consinit.c,v 1.6 2005/12/11 12:19:16 christos Exp $);
+__KERNEL_RCSID(0, $NetBSD: consinit.c,v 1.7 2009/12/27 08:41:50 tsutsui Exp $);
 
 #include opt_ddb.h
 #include opt_kgdb.h
@@ -271,7 +271,7 @@
 		DBPRINT((stdout package = %x\r\n, prom_stdout_node));
 		DBPRINT((buffer @ %p\r\n, buffer));
 	
-		if (prom_stdin_node  prom_node_has_property(prom_stdin_node, keyboard) {
+		if (prom_stdin_node  prom_node_has_property(prom_stdin_node, keyboard)) {
 #if NKBD == 0		
 			printf(cninit: kdb/display not configured\n);
 #endif



CVS commit: src/sys/arch/sun2

2009-12-11 Thread Izumi Tsutsui
Module Name:src
Committed By:   tsutsui
Date:   Fri Dec 11 13:56:16 UTC 2009

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

Log Message:
Refactoring MD segment related definitions on m68k ports:
- move macro SEGSHIFT, NBSG, and SEGOFFSET from machine/param.h
  to machine/pmap.h where they should belong
- don't use m68k_round_seg() and m68k_trunc_seg() in sun2 pmap sources
  and instead define and use sun2_round_seg() and sun2_trunc_seg()
  since they are quite pmap implementation dependent


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/sun2/include/param.h
cvs rdiff -u -r1.21 -r1.22 src/sys/arch/sun2/include/pmap.h
cvs rdiff -u -r1.42 -r1.43 src/sys/arch/sun2/sun2/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/sun2/include/param.h
diff -u src/sys/arch/sun2/include/param.h:1.10 src/sys/arch/sun2/include/param.h:1.11
--- src/sys/arch/sun2/include/param.h:1.10	Wed Jul  2 17:28:57 2008
+++ src/sys/arch/sun2/include/param.h	Fri Dec 11 13:56:15 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: param.h,v 1.10 2008/07/02 17:28:57 ad Exp $	*/
+/*	$NetBSD: param.h,v 1.11 2009/12/11 13:56:15 tsutsui Exp $	*/
 
 /*
  * Copyright (c) 1982, 1986, 1990, 1993
@@ -102,10 +102,6 @@
 #define	KERNBASE	0x6000	/* start of kernel virtual */
 #define	KERN_END	0x00E0	/* end of kernel virtual */
 
-#define SEGSHIFT	15	/* LOG2(NBSG) */
-#define NBSG		(1  SEGSHIFT)	/* bytes/segment */
-#define	SEGOFSET	(NBSG-1)	/* byte offset into segment */
-
 #define	MAXBSIZE	0x4000		/* max FS block size */
 #define	MAXPHYS		0xe000
 

Index: src/sys/arch/sun2/include/pmap.h
diff -u src/sys/arch/sun2/include/pmap.h:1.21 src/sys/arch/sun2/include/pmap.h:1.22
--- src/sys/arch/sun2/include/pmap.h:1.21	Tue Dec  9 20:45:45 2008
+++ src/sys/arch/sun2/include/pmap.h	Fri Dec 11 13:56:15 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.h,v 1.21 2008/12/09 20:45:45 pooka Exp $	*/
+/*	$NetBSD: pmap.h,v 1.22 2009/12/11 13:56:15 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -104,4 +104,13 @@
 
 void pmap_procwr(struct proc *, vaddr_t, size_t);
 
+/* MMU specific segment value */
+#define	SEGSHIFT	15	/* LOG2(NBSG) */
+#define	NBSG		(1  SEGSHIFT)	/* bytes/segment */
+#define	SEGOFSET	(NBSG - 1)	/* byte offset into segment */
+
+#define	sun2_round_seg(x)	vaddr_t)(x)) + SEGOFSET)  ~SEGOFSET)
+#define	sun2_trunc_seg(x)	((vaddr_t)(x)  ~SEGOFSET)
+#define	sun2_seg_offset(x)	((vaddr_t)(x)  SEGOFSET)
+
 #endif	/* _MACHINE_PMAP_H */

Index: src/sys/arch/sun2/sun2/pmap.c
diff -u src/sys/arch/sun2/sun2/pmap.c:1.42 src/sys/arch/sun2/sun2/pmap.c:1.43
--- src/sys/arch/sun2/sun2/pmap.c:1.42	Sat Nov 21 04:16:52 2009
+++ src/sys/arch/sun2/sun2/pmap.c	Fri Dec 11 13:56:16 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.42 2009/11/21 04:16:52 rmind Exp $	*/
+/*	$NetBSD: pmap.c,v 1.43 2009/12/11 13:56:16 tsutsui Exp $	*/
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -82,7 +82,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.42 2009/11/21 04:16:52 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: pmap.c,v 1.43 2009/12/11 13:56:16 tsutsui Exp $);
 
 #include opt_ddb.h
 #include opt_pmap_debug.h
@@ -1510,7 +1510,7 @@
 	 * Determine the range of kernel virtual space available.
 	 * It is segment-aligned to simplify PMEG management.
 	 */
-	virtual_avail = m68k_round_seg(nextva);
+	virtual_avail = sun2_round_seg(nextva);
 	virtual_end = VM_MAX_KERNEL_ADDRESS;
 
 	/*
@@ -2029,7 +2029,7 @@
 		new_pte |= PG_NC;
 	}
 
-	segva = m68k_trunc_seg(pgva);
+	segva = sun2_trunc_seg(pgva);
 	do_pv = true;
 
 	/* Do we have a PMEG? */
@@ -2173,7 +2173,7 @@
 		return;
 	}
 
-	segva = m68k_trunc_seg(pgva);
+	segva = sun2_trunc_seg(pgva);
 	do_pv = true;
 
 	/*
@@ -2365,7 +2365,7 @@
 		new_pte |= PG_NC;
 	}
 
-	segva = m68k_trunc_seg(va);
+	segva = sun2_trunc_seg(va);
 
 	s = splvm();
 
@@ -2437,7 +2437,7 @@
 	set_context(KERNEL_CONTEXT);
 	segnum = VA_SEGNUM(va);
 	for (eva = va + len; va  eva; va = neva, segnum++) {
-		neva = m68k_trunc_seg(va) + NBSG;
+		neva = sun2_trunc_seg(va) + NBSG;
 		if (neva  eva) {
 			neva = eva;
 		}
@@ -2445,7 +2445,7 @@
 			continue;
 		}
 
-		segva = m68k_trunc_seg(va);
+		segva = sun2_trunc_seg(va);
 		sme = get_segmap(segva);
 		pmegp = pmeg_p(sme);
 
@@ -2594,7 +2594,7 @@
 	if (pmap-pm_segmap[VA_SEGNUM(pgva)] == SEGINV)
 		return (0);
 
-	segva = m68k_trunc_seg(pgva);
+	segva = sun2_trunc_seg(pgva);
 	chkpte = PG_VALID;
 	if (ftype  VM_PROT_WRITE)
 		chkpte |= PG_WRITE;
@@ -3006,7 +3006,7 @@
 	va = sva;
 	segnum = VA_SEGNUM(va);
 	while (va  eva) {
-		neva = m68k_trunc_seg(va) + NBSG;
+		neva = sun2_trunc_seg(va) + NBSG;
 		if (neva  eva)
 			neva = eva;
 		if (pmap-pm_segmap[segnum] != SEGINV)
@@ -3030,7 +3030,7 @@
 	s = splvm();
 
 #ifdef	DIAGNOSTIC
-	if (m68k_trunc_seg(sva) != 

CVS commit: src/sys/arch/sun2/sun2

2009-11-28 Thread Havard Eidnes
Module Name:src
Committed By:   he
Date:   Sat Nov 28 21:37:28 UTC 2009

Modified Files:
src/sys/arch/sun2/sun2: locore2.c

Log Message:
Cast a vaddr_t (integral type) to void* before passing to memset.


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/sun2/sun2/locore2.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/sun2/sun2/locore2.c
diff -u src/sys/arch/sun2/sun2/locore2.c:1.23 src/sys/arch/sun2/sun2/locore2.c:1.24
--- src/sys/arch/sun2/sun2/locore2.c:1.23	Fri Nov 27 03:23:14 2009
+++ src/sys/arch/sun2/sun2/locore2.c	Sat Nov 28 21:37:28 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: locore2.c,v 1.23 2009/11/27 03:23:14 rmind Exp $	*/
+/*	$NetBSD: locore2.c,v 1.24 2009/11/28 21:37:28 he Exp $	*/
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: locore2.c,v 1.23 2009/11/27 03:23:14 rmind Exp $);
+__KERNEL_RCSID(0, $NetBSD: locore2.c,v 1.24 2009/11/28 21:37:28 he Exp $);
 
 #include opt_ddb.h
 #include opt_modular.h
@@ -187,7 +187,7 @@
 	 * (The fault handler may reference lwp0 stuff.)
 	 */
 	uvm_lwp_setuarea(lwp0, nextva);
-	memset(nextva, 0, USPACE);
+	memset((void *)nextva, 0, USPACE);
 
 	nextva += USPACE;