> 
> I just ran across this:
> 
> Debugger("isp_attach")
> Stopped at      Debugger+0x37:  movl    $0,in_Debugger
> db> cont
> whoa, other_cpus: 0x00000002, stopped_cpus: 0x00000000
> panic: stop_cpus() failed
> mp_lock = 00000002; cpuid = 0; lapic.id = 00000000
> Automatic reboot in 15 seconds - press a key on the console to abort
> 
> 
> Whuffo?

The kernel probably entered the debugger after the AP had been started
but before it accepts any interrupts.

- Tor Egge

Index: sys/i386/i386/db_interface.c
===================================================================
RCS file: /home/ncvs/src/sys/i386/i386/db_interface.c,v
retrieving revision 1.46
diff -u -r1.46 db_interface.c
--- db_interface.c      1999/08/28 00:43:42     1.46
+++ db_interface.c      1999/09/24 23:43:34
@@ -167,7 +167,7 @@
 #endif /* VERBOSE_CPUSTOP_ON_DDBBREAK */
 
        /* Restart all the CPUs we previously stopped */
-       if (stopped_cpus != other_cpus) {
+       if (stopped_cpus != other_cpus && smp_started != 0) {
                db_printf("whoa, other_cpus: 0x%08x, stopped_cpus: 0x%08x\n",
                          other_cpus, stopped_cpus);
                panic("stop_cpus() failed");
Index: sys/i386/include/smp.h
===================================================================
RCS file: /home/ncvs/src/sys/i386/include/smp.h,v
retrieving revision 1.47
diff -u -r1.47 smp.h
--- smp.h       1999/08/28 00:44:25     1.47
+++ smp.h       1999/09/24 23:39:47
@@ -177,6 +177,7 @@
 /* global data in init_smp.c */
 extern int                     invltlb_ok;
 extern int                     smp_active;
+extern int                     smp_started;
 extern volatile int            smp_idle_loops;
 
 #endif /* !LOCORE */

Reply via email to