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/kern/subr_smp.c 74912 2001-03-28 09:03:24Z jhb $ |
26 */ 27 28#include "opt_cpu.h" 29 30#ifdef SMP 31#include <machine/smptests.h> 32#else 33#error --- 2229 unchanged lines hidden (view full) --- 2263 while (!aps_ready) 2264 /* spin */ ; 2265 2266 /* 2267 * Set curproc to our per-cpu idleproc so that mutexes have 2268 * something unique to lock with. 2269 */ 2270 PCPU_SET(curproc, PCPU_GET(idleproc)); |
2271 PCPU_SET(spinlocks, NULL); |
2272 2273 /* lock against other AP's that are waking up */ 2274 mtx_lock_spin(&ap_boot_mtx); 2275 2276 /* BSP may have changed PTD while we're waiting for the lock */ 2277 cpu_invltlb(); 2278 2279 smp_cpus++; --- 622 unchanged lines hidden --- |