mptable.h (75421) | mptable.h (75570) |
---|---|
1/* 2 * Copyright (c) 1996, by Steve Passe 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 8 unchanged lines hidden (view full) --- 17 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23 * SUCH DAMAGE. 24 * | 1/* 2 * Copyright (c) 1996, by Steve Passe 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 8 unchanged lines hidden (view full) --- 17 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23 * SUCH DAMAGE. 24 * |
25 * $FreeBSD: head/sys/i386/include/mptable.h 75421 2001-04-11 17:06:02Z jhb $ | 25 * $FreeBSD: head/sys/i386/include/mptable.h 75570 2001-04-17 04:18:08Z jhb $ |
26 */ 27 28#include "opt_cpu.h" 29 30#ifdef SMP 31#include <machine/smptests.h> 32#else 33#error --- 318 unchanged lines hidden (view full) --- 352#ifdef USE_COMLOCK 353/* locks com (tty) data/hardware accesses: a FASTINTR() */ 354struct mtx com_mtx; 355#endif /* USE_COMLOCK */ 356 357/* lock around the MP rendezvous */ 358static struct mtx smp_rv_mtx; 359 | 26 */ 27 28#include "opt_cpu.h" 29 30#ifdef SMP 31#include <machine/smptests.h> 32#else 33#error --- 318 unchanged lines hidden (view full) --- 352#ifdef USE_COMLOCK 353/* locks com (tty) data/hardware accesses: a FASTINTR() */ 354struct mtx com_mtx; 355#endif /* USE_COMLOCK */ 356 357/* lock around the MP rendezvous */ 358static struct mtx smp_rv_mtx; 359 |
360/* only 1 CPU can panic at a time :) */ 361struct mtx panic_mtx; 362 | |
363static void 364init_locks(void) 365{ 366 /* 367 * XXX The mcount mutex probably needs to be statically initialized, 368 * since it will be used even in the function calls that get us to this 369 * point. 370 */ 371 mtx_init(&mcount_mtx, "mcount", MTX_DEF); 372 373 mtx_init(&smp_rv_mtx, "smp rendezvous", MTX_SPIN); | 360static void 361init_locks(void) 362{ 363 /* 364 * XXX The mcount mutex probably needs to be statically initialized, 365 * since it will be used even in the function calls that get us to this 366 * point. 367 */ 368 mtx_init(&mcount_mtx, "mcount", MTX_DEF); 369 370 mtx_init(&smp_rv_mtx, "smp rendezvous", MTX_SPIN); |
374 mtx_init(&panic_mtx, "panic", MTX_DEF); | |
375 376#ifdef USE_COMLOCK 377 mtx_init(&com_mtx, "com", MTX_SPIN); 378#endif /* USE_COMLOCK */ 379 380 mtx_init(&ap_boot_mtx, "ap boot", MTX_SPIN); 381} 382 --- 2552 unchanged lines hidden --- | 371 372#ifdef USE_COMLOCK 373 mtx_init(&com_mtx, "com", MTX_SPIN); 374#endif /* USE_COMLOCK */ 375 376 mtx_init(&ap_boot_mtx, "ap boot", MTX_SPIN); 377} 378 --- 2552 unchanged lines hidden --- |