Deleted Added
full compact
mp_machdep.c (78425) mp_machdep.c (78908)
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/amd64/amd64/mp_machdep.c 78425 2001-06-18 19:06:14Z jhb $
25 * $FreeBSD: head/sys/amd64/amd64/mp_machdep.c 78908 2001-06-28 04:03:29Z jhb $
26 */
27
28#include "opt_cpu.h"
29
30#ifdef SMP
31#include <machine/smptests.h>
32#else
33#error

--- 286 unchanged lines hidden (view full) ---

320/*
321 * initialize all the SMP locks
322 */
323
324/* critical region around IO APIC, apic_imen */
325struct mtx imen_mtx;
326
327/* lock region used by kernel profiling */
26 */
27
28#include "opt_cpu.h"
29
30#ifdef SMP
31#include <machine/smptests.h>
32#else
33#error

--- 286 unchanged lines hidden (view full) ---

320/*
321 * initialize all the SMP locks
322 */
323
324/* critical region around IO APIC, apic_imen */
325struct mtx imen_mtx;
326
327/* lock region used by kernel profiling */
328struct mtx mcount_mtx;
328int mcount_lock;
329
330#ifdef USE_COMLOCK
331/* locks com (tty) data/hardware accesses: a FASTINTR() */
332struct mtx com_mtx;
333#endif /* USE_COMLOCK */
334
335static void
336init_locks(void)
337{
329
330#ifdef USE_COMLOCK
331/* locks com (tty) data/hardware accesses: a FASTINTR() */
332struct mtx com_mtx;
333#endif /* USE_COMLOCK */
334
335static void
336init_locks(void)
337{
338 /*
339 * XXX The mcount mutex probably needs to be statically initialized,
340 * since it will be used even in the function calls that get us to this
341 * point.
342 */
343 mtx_init(&mcount_mtx, "mcount", MTX_DEF);
344
345#ifdef USE_COMLOCK
346 mtx_init(&com_mtx, "com", MTX_SPIN);
347#endif /* USE_COMLOCK */
348}
349
350/*
351 * Calculate usable address in base memory for AP trampoline code.

--- 2087 unchanged lines hidden ---
338
339#ifdef USE_COMLOCK
340 mtx_init(&com_mtx, "com", MTX_SPIN);
341#endif /* USE_COMLOCK */
342}
343
344/*
345 * Calculate usable address in base memory for AP trampoline code.

--- 2087 unchanged lines hidden ---