kernel - Fix UP build
authorMatthew Dillon <dillon@apollo.backplane.com>
Sun, 29 Aug 2010 20:48:31 +0000 (13:48 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sun, 29 Aug 2010 20:49:46 +0000 (13:49 -0700)
* Declare panic_cpu_gd whether UP or SMP.

* Properly reinit the spinlock whether UP or SMP

Reported-by: swildner
sys/kern/kern_shutdown.c

index 5c1a08e..05cdd91 100644 (file)
@@ -148,9 +148,7 @@ const char *panicstr;
 int dumping;                           /* system is dumping */
 static struct dumperinfo dumper;       /* selected dumper */
 
-#ifdef SMP
 globaldata_t panic_cpu_gd;             /* which cpu took the panic */
-#endif
 
 int bootverbose = 0;                   /* note: assignment to force non-bss */
 SYSCTL_INT(_debug, OID_AUTO, bootverbose, CTLFLAG_RW,
@@ -726,8 +724,8 @@ panic(const char *fmt, ...)
        }
 #else
        panic_cpu_gd = gd;
-       kvcreinitspin();
 #endif
+       kvcreinitspin();
        /*
         * Setup
         */