Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/pmax/pmax Move intr_init() (which initializes evcnt...



details:   https://anonhg.NetBSD.org/src/rev/41e2fe7503af
branches:  trunk
changeset: 763905:41e2fe7503af
user:      tsutsui <tsutsui%NetBSD.org@localhost>
date:      Wed Apr 06 15:31:08 2011 +0000

description:
Move intr_init() (which initializes evcnt(9) for interrupts)
from early machdep.c:mach_init() to autoconf.c:cpu_configure().

evcnt_init() isn't called yet when mach_init() is invoked from locore.S
and interrupts won't be enabled before cpu_configure(9).

Problem reported by Erik Bertelsen on port-pmax:
http://mail-index.NetBSD.org/port-pmax/2011/04/06/msg000093.html

diffstat:

 sys/arch/pmax/pmax/autoconf.c |  7 +++++--
 sys/arch/pmax/pmax/machdep.c  |  7 ++-----
 2 files changed, 7 insertions(+), 7 deletions(-)

diffs (56 lines):

diff -r 49d2561ee321 -r 41e2fe7503af sys/arch/pmax/pmax/autoconf.c
--- a/sys/arch/pmax/pmax/autoconf.c     Wed Apr 06 14:51:12 2011 +0000
+++ b/sys/arch/pmax/pmax/autoconf.c     Wed Apr 06 15:31:08 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: autoconf.c,v 1.76 2011/02/20 07:50:25 matt Exp $       */
+/*     $NetBSD: autoconf.c,v 1.77 2011/04/06 15:31:48 tsutsui Exp $    */
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: autoconf.c,v 1.76 2011/02/20 07:50:25 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: autoconf.c,v 1.77 2011/04/06 15:31:48 tsutsui Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -77,6 +77,9 @@
        /* Kick off autoconfiguration. */
        (void)splhigh();
 
+       /* Interrupt initialization. */
+       intr_init();
+
        if (config_rootfound("mainbus", NULL) == NULL)
                panic("no mainbus found");
 
diff -r 49d2561ee321 -r 41e2fe7503af sys/arch/pmax/pmax/machdep.c
--- a/sys/arch/pmax/pmax/machdep.c      Wed Apr 06 14:51:12 2011 +0000
+++ b/sys/arch/pmax/pmax/machdep.c      Wed Apr 06 15:31:08 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: machdep.c,v 1.242 2011/02/20 07:50:25 matt Exp $       */
+/*     $NetBSD: machdep.c,v 1.243 2011/04/06 15:31:08 tsutsui Exp $    */
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.242 2011/02/20 07:50:25 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.243 2011/04/06 15:31:08 tsutsui Exp $");
 
 #include "opt_ddb.h"
 #include "opt_modular.h"
@@ -315,9 +315,6 @@
        /* Machine specific initialization. */
        (*sysinit[systype].init)();
 
-       /* Interrupt initialization. */
-       intr_init();
-
        /* Find out how much memory is available. */
        physmem = (*platform.memsize)(kernend);
 



Home | Main Index | Thread Index | Old Index