npx.c (27567) | npx.c (27993) |
---|---|
1/*- 2 * Copyright (c) 1990 William Jolitz. 3 * Copyright (c) 1991 The Regents of the University of California. 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: --- 18 unchanged lines hidden (view full) --- 27 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 * SUCH DAMAGE. 33 * 34 * from: @(#)npx.c 7.2 (Berkeley) 5/12/91 | 1/*- 2 * Copyright (c) 1990 William Jolitz. 3 * Copyright (c) 1991 The Regents of the University of California. 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: --- 18 unchanged lines hidden (view full) --- 27 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 * SUCH DAMAGE. 33 * 34 * from: @(#)npx.c 7.2 (Berkeley) 5/12/91 |
35 * $Id: npx.c,v 1.3 1997/07/20 23:30:38 smp Exp smp $ | 35 * $Id: npx.c,v 1.49 1997/07/21 07:57:50 fsmp Exp $ |
36 */ 37 38#include "npx.h" 39#if NNPX > 0 40 41#include "opt_cpu.h" 42#include "opt_math_emulate.h" 43 --- 466 unchanged lines hidden (view full) --- 510 fnstsw(&curpcb->pcb_savefpu.sv_ex_sw); 511 fnclex(); 512 fnop(); 513 514 /* 515 * Pass exception to process. 516 */ 517 frame = (struct intrframe *)&unit; /* XXX */ | 36 */ 37 38#include "npx.h" 39#if NNPX > 0 40 41#include "opt_cpu.h" 42#include "opt_math_emulate.h" 43 --- 466 unchanged lines hidden (view full) --- 510 fnstsw(&curpcb->pcb_savefpu.sv_ex_sw); 511 fnclex(); 512 fnop(); 513 514 /* 515 * Pass exception to process. 516 */ 517 frame = (struct intrframe *)&unit; /* XXX */ |
518 if (ISPL(frame->if_cs) == SEL_UPL) { | 518 if ((ISPL(frame->if_cs) == SEL_UPL) || (frame->if_eflags & PSL_VM)) { |
519 /* 520 * Interrupt is essentially a trap, so we can afford to call 521 * the SIGFPE handler (if any) as soon as the interrupt 522 * returns. 523 * 524 * XXX little or nothing is gained from this, and plenty is 525 * lost - the interrupt frame has to contain the trap frame 526 * (this is otherwise only necessary for the rescheduling trap --- 129 unchanged lines hidden --- | 519 /* 520 * Interrupt is essentially a trap, so we can afford to call 521 * the SIGFPE handler (if any) as soon as the interrupt 522 * returns. 523 * 524 * XXX little or nothing is gained from this, and plenty is 525 * lost - the interrupt frame has to contain the trap frame 526 * (this is otherwise only necessary for the rescheduling trap --- 129 unchanged lines hidden --- |