Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/mipsco/mipsco Cleanup includes



details:   https://anonhg.NetBSD.org/src/rev/abf3b253997f
branches:  trunk
changeset: 339106:abf3b253997f
user:      matt <matt%NetBSD.org@localhost>
date:      Fri Jun 26 22:55:40 2015 +0000

description:
Cleanup includes
Use cpu_startup_common()

diffstat:

 sys/arch/mipsco/mipsco/machdep.c |  84 +++++++--------------------------------
 1 files changed, 16 insertions(+), 68 deletions(-)

diffs (133 lines):

diff -r 5daf0040dc90 -r abf3b253997f sys/arch/mipsco/mipsco/machdep.c
--- a/sys/arch/mipsco/mipsco/machdep.c  Fri Jun 26 22:55:06 2015 +0000
+++ b/sys/arch/mipsco/mipsco/machdep.c  Fri Jun 26 22:55:40 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: machdep.c,v 1.78 2014/06/08 07:01:30 he Exp $  */
+/*     $NetBSD: machdep.c,v 1.79 2015/06/26 22:55:40 matt Exp $        */
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -39,66 +39,48 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.78 2014/06/08 07:01:30 he Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.79 2015/06/26 22:55:40 matt Exp $");
 
 /* from: Utah Hdr: machdep.c 1.63 91/04/24 */
 
 #include "opt_ddb.h"
 #include "opt_kgdb.h"
 #include "opt_modular.h"
+#include "opt_execfmt.h"
+
+#include "zsc.h"                       /* XXX */
+#include "com.h"                       /* XXX */
+#include "ksyms.h"
 
 #include <sys/param.h>
-#include <sys/systm.h>
-#include <sys/signalvar.h>
-#include <sys/kernel.h>
-#include <sys/proc.h>
-#include <sys/buf.h>
-#include <sys/reboot.h>
+#include <sys/boot_flag.h>
 #include <sys/conf.h>
-#include <sys/file.h>
-#include <sys/callout.h>
-#include <sys/malloc.h>
-#include <sys/mbuf.h>
-#include <sys/msgbuf.h>
-#include <sys/ioctl.h>
+#include <sys/cpu.h>
 #include <sys/device.h>
-#include <sys/exec.h>
-#include <sys/mount.h>
-#include <sys/syscallargs.h>
+#include <sys/intr.h>
 #include <sys/kcore.h>
 #include <sys/ksyms.h>
-#include <sys/cpu.h>
+#include <sys/kernel.h>
+#include <sys/reboot.h>
+#include <sys/systm.h>
 
 #include <uvm/uvm_extern.h>
 
 #include <ufs/mfs/mfs_extern.h>                /* mfs_initminiroot() */
 
-#include <machine/cpu.h>
-#include <machine/reg.h>
-#include <machine/psl.h>
-#include <machine/pte.h>
+#include <dev/clock_subr.h>
+#include <dev/cons.h>
 
 #ifdef DDB
 #include <machine/db_machdep.h>
 #include <ddb/db_extern.h>
 #endif
 
-#include <machine/intr.h>
 #include <machine/mainboard.h>
 #include <machine/sysconf.h>
 #include <machine/autoconf.h>
 #include <machine/bootinfo.h>
 #include <machine/prom.h>
-#include <dev/clock_subr.h>
-#include <dev/cons.h>
-
-#include <sys/boot_flag.h>
-
-#include "opt_execfmt.h"
-
-#include "zsc.h"                       /* XXX */
-#include "com.h"                       /* XXX */
-#include "ksyms.h"
 
 /* maps for VM objects */
 
@@ -328,41 +310,7 @@
 void
 cpu_startup(void)
 {
-       vaddr_t minaddr, maxaddr;
-       char pbuf[9];
-#ifdef DEBUG
-       extern int pmapdebug;
-       int opmapdebug = pmapdebug;
-
-       pmapdebug = 0;
-#endif
-
-       /*
-        * Good {morning,afternoon,evening,night}.
-        */
-       printf("%s%s", copyright, version);
-       printf("%s\n", cpu_getmodel());
-       format_bytes(pbuf, sizeof(pbuf), ctob(physmem));
-       printf("total memory = %s\n", pbuf);
-
-       minaddr = 0;
-       /*
-        * Allocate a submap for physio
-        */
-       phys_map = uvm_km_suballoc(kernel_map, &minaddr, &maxaddr,
-                                  VM_PHYS_SIZE, true, false, NULL);
-
-       /*
-        * No need to allocate an mbuf cluster submap.  Mbuf clusters
-        * are allocated via the pool allocator, and we use KSEG to
-        * map those pages.
-        */
-
-#ifdef DEBUG
-       pmapdebug = opmapdebug;
-#endif
-       format_bytes(pbuf, sizeof(pbuf), ptoa(uvmexp.free));
-       printf("avail memory = %s\n", pbuf);
+       cpu_startup_common();
 }
 
 /*



Home | Main Index | Thread Index | Old Index