Deleted Added
full compact
mp_machdep.c (208494) mp_machdep.c (208833)
1/*-
2 * Copyright (c) 1996, by Steve Passe
3 * Copyright (c) 2003, by Peter Wemm
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

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

20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 */
26
27#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 1996, by Steve Passe
3 * Copyright (c) 2003, by Peter Wemm
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

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

20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 */
26
27#include <sys/cdefs.h>
28__FBSDID("$FreeBSD: head/sys/amd64/amd64/mp_machdep.c 208494 2010-05-24 11:40:49Z mav $");
28__FBSDID("$FreeBSD: head/sys/amd64/amd64/mp_machdep.c 208833 2010-06-05 15:59:59Z kib $");
29
30#include "opt_cpu.h"
31#include "opt_kstack_pages.h"
32#include "opt_mp_watchdog.h"
33#include "opt_sched.h"
34
35#include <sys/param.h>
36#include <sys/systm.h>

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

1242{
1243 struct savefpu *stopfpu;
1244 register_t cr3, rf;
1245 int cpu = PCPU_GET(cpuid);
1246 int cpumask = PCPU_GET(cpumask);
1247
1248 rf = intr_disable();
1249 cr3 = rcr3();
29
30#include "opt_cpu.h"
31#include "opt_kstack_pages.h"
32#include "opt_mp_watchdog.h"
33#include "opt_sched.h"
34
35#include <sys/param.h>
36#include <sys/systm.h>

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

1242{
1243 struct savefpu *stopfpu;
1244 register_t cr3, rf;
1245 int cpu = PCPU_GET(cpuid);
1246 int cpumask = PCPU_GET(cpumask);
1247
1248 rf = intr_disable();
1249 cr3 = rcr3();
1250 stopfpu = &stopxpcbs[cpu]->xpcb_pcb.pcb_save;
1250 stopfpu = stopxpcbs[cpu]->xpcb_pcb.pcb_save;
1251 if (savectx2(stopxpcbs[cpu])) {
1252 fpugetregs(curthread, stopfpu);
1253 wbinvd();
1254 atomic_set_int(&stopped_cpus, cpumask);
1255 } else
1256 fpusetregs(curthread, stopfpu);
1257
1258 /* Wait for resume */

--- 175 unchanged lines hidden ---
1251 if (savectx2(stopxpcbs[cpu])) {
1252 fpugetregs(curthread, stopfpu);
1253 wbinvd();
1254 atomic_set_int(&stopped_cpus, cpumask);
1255 } else
1256 fpusetregs(curthread, stopfpu);
1257
1258 /* Wait for resume */

--- 175 unchanged lines hidden ---