npx.c (24203) | npx.c (25083) |
---|---|
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.39 1997/02/22 09:36:57 peter Exp $ | 35 * $Id: npx.c,v 1.40 1997/03/24 11:23:58 bde Exp $ |
36 */ 37 38#include "npx.h" 39#if NNPX > 0 40 41#include "opt_cpu.h" 42#include "opt_math_emulate.h" 43 --- 4 unchanged lines hidden (view full) --- 48#include <sys/conf.h> 49#include <sys/file.h> 50#include <sys/proc.h> 51#ifdef NPX_DEBUG 52#include <sys/syslog.h> 53#endif 54#include <sys/signalvar.h> 55 | 36 */ 37 38#include "npx.h" 39#if NNPX > 0 40 41#include "opt_cpu.h" 42#include "opt_math_emulate.h" 43 --- 4 unchanged lines hidden (view full) --- 48#include <sys/conf.h> 49#include <sys/file.h> 50#include <sys/proc.h> 51#ifdef NPX_DEBUG 52#include <sys/syslog.h> 53#endif 54#include <sys/signalvar.h> 55 |
56#include <machine/asmacros.h> |
|
56#include <machine/cpu.h> 57#include <machine/pcb.h> 58#include <machine/md_var.h> 59#include <machine/trap.h> 60#include <machine/clock.h> 61#include <machine/specialreg.h> 62 63#include <i386/isa/icu.h> --- 78 unchanged lines hidden (view full) --- 142static bool_t npx_irq13; 143static volatile u_int npx_traps_while_probing; 144 145/* 146 * Special interrupt handlers. Someday intr0-intr15 will be used to count 147 * interrupts. We'll still need a special exception 16 handler. The busy 148 * latch stuff in probeintr() can be moved to npxprobe(). 149 */ | 57#include <machine/cpu.h> 58#include <machine/pcb.h> 59#include <machine/md_var.h> 60#include <machine/trap.h> 61#include <machine/clock.h> 62#include <machine/specialreg.h> 63 64#include <i386/isa/icu.h> --- 78 unchanged lines hidden (view full) --- 143static bool_t npx_irq13; 144static volatile u_int npx_traps_while_probing; 145 146/* 147 * Special interrupt handlers. Someday intr0-intr15 will be used to count 148 * interrupts. We'll still need a special exception 16 handler. The busy 149 * latch stuff in probeintr() can be moved to npxprobe(). 150 */ |
151 |
|
150inthand_t probeintr; 151asm 152(" 153 .text | 152inthand_t probeintr; 153asm 154(" 155 .text |
154_probeintr: | 156 .p2align 2,0x90 157" __XSTRING(CNAME(probeintr)) ": |
155 ss | 158 ss |
156 incl _npx_intrs_while_probing | 159 incl " __XSTRING(CNAME(npx_intrs_while_probing)) " |
157 pushl %eax 158 movb $0x20,%al # EOI (asm in strings loses cpp features) 159 outb %al,$0xa0 # IO_ICU2 160 outb %al,$0x20 # IO_ICU1 161 movb $0,%al 162 outb %al,$0xf0 # clear BUSY# latch 163 popl %eax 164 iret 165"); 166 167inthand_t probetrap; 168asm 169(" 170 .text | 160 pushl %eax 161 movb $0x20,%al # EOI (asm in strings loses cpp features) 162 outb %al,$0xa0 # IO_ICU2 163 outb %al,$0x20 # IO_ICU1 164 movb $0,%al 165 outb %al,$0xf0 # clear BUSY# latch 166 popl %eax 167 iret 168"); 169 170inthand_t probetrap; 171asm 172(" 173 .text |
171_probetrap: | 174 .p2align 2,0x90 175" __XSTRING(CNAME(probetrap)) ": |
172 ss | 176 ss |
173 incl _npx_traps_while_probing | 177 incl " __XSTRING(CNAME(npx_traps_while_probing)) " |
174 fnclex 175 iret 176"); 177 178/* 179 * Probe routine. Initialize cr0 to give correct behaviour for [f]wait 180 * whether the device exists or not (XXX should be elsewhere). Set flags 181 * to tell npxattach() what to do. Modify device struct if npx doesn't --- 425 unchanged lines hidden --- | 178 fnclex 179 iret 180"); 181 182/* 183 * Probe routine. Initialize cr0 to give correct behaviour for [f]wait 184 * whether the device exists or not (XXX should be elsewhere). Set flags 185 * to tell npxattach() what to do. Modify device struct if npx doesn't --- 425 unchanged lines hidden --- |