summaryrefslogtreecommitdiff
path: root/sys/arch/i386/isa
diff options
context:
space:
mode:
authorDale Rahn <drahn@cvs.openbsd.org>2003-04-17 03:42:15 +0000
committerDale Rahn <drahn@cvs.openbsd.org>2003-04-17 03:42:15 +0000
commitd36015cb7ad92f7024a5754fc18618f0b0e13139 (patch)
treef134d2cf17198d6d3a9b68105527ee84adb387e4 /sys/arch/i386/isa
parentddb3879f13964f6a99cf09d238b853194cbab068 (diff)
i386 changes to move to ELF. asm cleanup. Change MAXDSIZ to 512M for 1Gsep.
DARPA funded work.
Diffstat (limited to 'sys/arch/i386/isa')
-rw-r--r--sys/arch/i386/isa/icu.s8
-rw-r--r--sys/arch/i386/isa/npx.c12
-rw-r--r--sys/arch/i386/isa/vector.s84
3 files changed, 59 insertions, 45 deletions
diff --git a/sys/arch/i386/isa/icu.s b/sys/arch/i386/isa/icu.s
index 57b11456f29..3aff719725a 100644
--- a/sys/arch/i386/isa/icu.s
+++ b/sys/arch/i386/isa/icu.s
@@ -1,4 +1,4 @@
-/* $OpenBSD: icu.s,v 1.18 2001/12/04 00:00:36 niklas Exp $ */
+/* $OpenBSD: icu.s,v 1.19 2003/04/17 03:42:14 drahn Exp $ */
/* $NetBSD: icu.s,v 1.45 1996/01/07 03:59:34 mycroft Exp $ */
/*-
@@ -139,7 +139,7 @@ IDTVEC(softtty)
call _C_LABEL(comsoft)
movl %ebx,_C_LABEL(cpl)
#endif
- jmp %esi
+ jmp *%esi
#define DONETISR(s, c) \
.globl _C_LABEL(c) ;\
@@ -155,7 +155,7 @@ IDTVEC(softnet)
xchgl _C_LABEL(netisr),%edi
#include <net/netisr_dispatch.h>
movl %ebx,_C_LABEL(cpl)
- jmp %esi
+ jmp *%esi
#undef DONETISR
IDTVEC(softclock)
@@ -163,5 +163,5 @@ IDTVEC(softclock)
movl %eax,_C_LABEL(cpl)
call _C_LABEL(softclock)
movl %ebx,_C_LABEL(cpl)
- jmp %esi
+ jmp *%esi
diff --git a/sys/arch/i386/isa/npx.c b/sys/arch/i386/isa/npx.c
index a976ea241b1..6b66cb3bc31 100644
--- a/sys/arch/i386/isa/npx.c
+++ b/sys/arch/i386/isa/npx.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: npx.c,v 1.25 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: npx.c,v 1.26 2003/04/17 03:42:14 drahn Exp $ */
/* $NetBSD: npx.c,v 1.57 1996/05/12 23:12:24 mycroft Exp $ */
#if 0
@@ -152,9 +152,9 @@ extern int i386_fpu_fdivbug;
*/
void probeintr(void);
asm (".text\n\t"
-"_probeintr:\n\t"
+"probeintr:\n\t"
"ss\n\t"
- "incl _npx_intrs_while_probing\n\t"
+ "incl npx_intrs_while_probing\n\t"
"pushl %eax\n\t"
"movb $0x20,%al # EOI (asm in strings loses cpp features)\n\t"
"outb %al,$0xa0 # IO_ICU2\n\t"
@@ -166,9 +166,9 @@ asm (".text\n\t"
void probetrap(void);
asm (".text\n\t"
-"_probetrap:\n\t"
+"probetrap:\n\t"
"ss\n\t"
- "incl _npx_traps_while_probing\n\t"
+ "incl npx_traps_while_probing\n\t"
"fnclex\n\t"
"iret\n\t");
@@ -307,7 +307,7 @@ npxprobe(parent, match, aux)
int npx586bug1(int, int);
asm (".text\n\t"
-"_npx586bug1:\n\t"
+"npx586bug1:\n\t"
"fildl 4(%esp) # x\n\t"
"fildl 8(%esp) # y\n\t"
"fld %st(1)\n\t"
diff --git a/sys/arch/i386/isa/vector.s b/sys/arch/i386/isa/vector.s
index 1407c3166fe..93a7bab51da 100644
--- a/sys/arch/i386/isa/vector.s
+++ b/sys/arch/i386/isa/vector.s
@@ -1,4 +1,4 @@
-/* $OpenBSD: vector.s,v 1.15 2001/12/06 21:09:13 niklas Exp $ */
+/* $OpenBSD: vector.s,v 1.16 2003/04/17 03:42:14 drahn Exp $ */
/* $NetBSD: vector.s,v 1.32 1996/01/07 21:29:47 mycroft Exp $ */
/*
@@ -85,16 +85,16 @@
#ifdef ICU_HARDWARE_MASK
#define MASK(irq_num, icu) \
- movb _imen + IRQ_BYTE(irq_num),%al ;\
+ movb _C_LABEL(imen) + IRQ_BYTE(irq_num),%al ;\
orb $IRQ_BIT(irq_num),%al ;\
- movb %al,_imen + IRQ_BYTE(irq_num) ;\
+ movb %al,_C_LABEL(imen) + IRQ_BYTE(irq_num) ;\
FASTER_NOP ;\
outb %al,$(icu+1)
#define UNMASK(irq_num, icu) \
cli ;\
- movb _imen + IRQ_BYTE(irq_num),%al ;\
+ movb _C_LABEL(imen) + IRQ_BYTE(irq_num),%al ;\
andb $~IRQ_BIT(irq_num),%al ;\
- movb %al,_imen + IRQ_BYTE(irq_num) ;\
+ movb %al,_C_LABEL(imen) + IRQ_BYTE(irq_num) ;\
FASTER_NOP ;\
outb %al,$(icu+1) ;\
sti
@@ -130,7 +130,7 @@
* scattered cld's?
*/
- .globl _isa_strayintr
+ .globl _C_LABEL(isa_strayintr)
/*
* Normal vectors.
@@ -154,7 +154,7 @@ IDTVEC(recurse/**/irq_num) ;\
pushl %cs ;\
pushl %esi ;\
cli ;\
-_Xintr/**/irq_num/**/: ;\
+_C_LABEL(Xintr)/**/irq_num/**/: ;\
pushl $0 /* dummy error code */ ;\
pushl $T_ASTFLT /* trap # for doing ASTs */ ;\
INTRENTRY ;\
@@ -162,26 +162,26 @@ _Xintr/**/irq_num/**/: ;\
MASK(irq_num, icu) /* mask it in hardware */ ;\
ack(irq_num) /* and allow other intrs */ ;\
incl MY_COUNT+V_INTR /* statistical info */ ;\
- movl _C_LABEL(iminlevel) + (irq_num) * 4, %eax ;\
+ movl _C_LABEL(iminlevel) + (irq_num) * 4, %eax ;\
movzbl _C_LABEL(cpl),%ebx ;\
cmpl %eax,%ebx ;\
jae _C_LABEL(Xhold/**/irq_num)/* currently masked; hold it */;\
-_Xresume/**/irq_num/**/: ;\
+_C_LABEL(Xresume)/**/irq_num/**/: ;\
movzbl _C_LABEL(cpl),%eax /* cpl to restore on exit */ ;\
pushl %eax ;\
- movl _C_LABEL(imaxlevel) + (irq_num) * 4,%eax ;\
+ movl _C_LABEL(imaxlevel) + (irq_num) * 4,%eax ;\
movl %eax,_C_LABEL(cpl) /* block enough for this irq */ ;\
sti /* safe to take intrs now */ ;\
- movl _intrhand + (irq_num) * 4,%ebx /* head of chain */ ;\
+ movl _C_LABEL(intrhand) + (irq_num) * 4,%ebx /* head of chain */ ;\
testl %ebx,%ebx ;\
- jz _Xstray/**/irq_num /* no handlears; we're stray */ ;\
+ jz _C_LABEL(Xstray)/**/irq_num /* no handlears; we're stray */ ;\
STRAY_INITIALIZE /* nobody claimed it yet */ ;\
7: movl IH_ARG(%ebx),%eax /* get handler arg */ ;\
testl %eax,%eax ;\
jnz 4f ;\
movl %esp,%eax /* 0 means frame pointer */ ;\
4: pushl %eax ;\
- call IH_FUN(%ebx) /* call it */ ;\
+ call *IH_FUN(%ebx) /* call it */ ;\
addl $4,%esp /* toss the arg */ ;\
STRAY_INTEGRATE /* maybe he claimed it */ ;\
orl %eax,%eax /* should it be counted? */ ;\
@@ -192,14 +192,14 @@ _Xresume/**/irq_num/**/: ;\
jnz 7b ;\
STRAY_TEST /* see if it's a stray */ ;\
6: UNMASK(irq_num, icu) /* unmask it in hardware */ ;\
- jmp _Xdoreti /* lower spl and do ASTs */ ;\
+ jmp _C_LABEL(Xdoreti) /* lower spl and do ASTs */ ;\
IDTVEC(stray/**/irq_num) ;\
pushl $irq_num ;\
- call _isa_strayintr ;\
+ call _C_LABEL(isa_strayintr) ;\
addl $4,%esp ;\
jmp 6b ;\
IDTVEC(hold/**/irq_num) ;\
- orb $IRQ_BIT(irq_num),_ipending + IRQ_BYTE(irq_num) ;\
+ orb $IRQ_BIT(irq_num),_C_LABEL(ipending) + IRQ_BYTE(irq_num) ;\
INTRFASTEXIT
#if defined(DEBUG) && defined(notdef)
@@ -209,7 +209,7 @@ IDTVEC(hold/**/irq_num) ;\
orl %eax,%esi
#define STRAY_TEST \
testl %esi,%esi ;\
- jz _Xstray/**/irq_num
+ jz _C_LABEL(Xstray)/**/irq_num
#else /* !DEBUG */
#define STRAY_INITIALIZE
#define STRAY_INTEGRATE
@@ -245,37 +245,51 @@ INTR(15, IO_ICU2, ACK2)
*/
/* interrupt service routine entry points */
IDTVEC(intr)
- .long _Xintr0, _Xintr1, _Xintr2, _Xintr3, _Xintr4, _Xintr5, _Xintr6
- .long _Xintr7, _Xintr8, _Xintr9, _Xintr10, _Xintr11, _Xintr12
- .long _Xintr13, _Xintr14, _Xintr15
+ .long _C_LABEL(Xintr0), _C_LABEL(Xintr1), _C_LABEL(Xintr2)
+ .long _C_LABEL(Xintr3), _C_LABEL(Xintr4), _C_LABEL(Xintr5)
+ .long _C_LABEL(Xintr6), _C_LABEL(Xintr7), _C_LABEL(Xintr8)
+ .long _C_LABEL(Xintr9), _C_LABEL(Xintr10), _C_LABEL(Xintr11)
+ .long _C_LABEL(Xintr12), _C_LABEL(Xintr13)
+ .long _C_LABEL(Xintr14), _C_LABEL(Xintr15)
/*
* These tables are used by Xdoreti() and Xspllower().
*/
/* resume points for suspended interrupts */
IDTVEC(resume)
- .long _Xresume0, _Xresume1, _Xresume2, _Xresume3, _Xresume4
- .long _Xresume5, _Xresume6, _Xresume7, _Xresume8, _Xresume9
- .long _Xresume10, _Xresume11, _Xresume12, _Xresume13, _Xresume14
- .long _Xresume15
+ .long _C_LABEL(Xresume0), _C_LABEL(Xresume1)
+ .long _C_LABEL(Xresume2), _C_LABEL(Xresume3)
+ .long _C_LABEL(Xresume4), _C_LABEL(Xresume5)
+ .long _C_LABEL(Xresume6), _C_LABEL(Xresume7)
+ .long _C_LABEL(Xresume8), _C_LABEL(Xresume9)
+ .long _C_LABEL(Xresume10), _C_LABEL(Xresume11)
+ .long _C_LABEL(Xresume12), _C_LABEL(Xresume13)
+ .long _C_LABEL(Xresume14), _C_LABEL(Xresume15)
/* for soft interrupts */
.long 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
- .long _Xsofttty, _Xsoftnet, _Xsoftclock
+ .long _C_LABEL(Xsofttty), _C_LABEL(Xsoftnet)
+ .long _C_LABEL(Xsoftclock)
/* fake interrupts to resume from splx() */
IDTVEC(recurse)
- .long _Xrecurse0, _Xrecurse1, _Xrecurse2, _Xrecurse3, _Xrecurse4
- .long _Xrecurse5, _Xrecurse6, _Xrecurse7, _Xrecurse8, _Xrecurse9
- .long _Xrecurse10, _Xrecurse11, _Xrecurse12, _Xrecurse13, _Xrecurse14
- .long _Xrecurse15
+ .long _C_LABEL(Xrecurse0), _C_LABEL(Xrecurse1)
+ .long _C_LABEL(Xrecurse2), _C_LABEL(Xrecurse3)
+ .long _C_LABEL(Xrecurse4), _C_LABEL(Xrecurse5)
+ .long _C_LABEL(Xrecurse6), _C_LABEL(Xrecurse7)
+ .long _C_LABEL(Xrecurse8), _C_LABEL(Xrecurse9)
+ .long _C_LABEL(Xrecurse10), _C_LABEL(Xrecurse11)
+ .long _C_LABEL(Xrecurse12), _C_LABEL(Xrecurse13)
+ .long _C_LABEL(Xrecurse14), _C_LABEL(Xrecurse15)
/* for soft interrupts */
.long 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
- .long _Xsofttty, _Xsoftnet, _Xsoftclock
+ .long _C_LABEL(Xsofttty), _C_LABEL(Xsoftnet)
+ .long _C_LABEL(Xsoftclock)
/* Some bogus data, to keep vmstat happy, for now. */
- .globl _intrnames, _eintrnames, _intrcnt, _eintrcnt
-_intrnames:
+ .globl _C_LABEL(intrnames), _C_LABEL(eintrnames)
+ .globl _C_LABEL(intrcnt), _C_LABEL(eintrcnt)
+_C_LABEL(intrnames):
.long 0
-_eintrnames:
-_intrcnt:
+_C_LABEL(eintrnames):
+_C_LABEL(intrcnt):
.long 0
-_eintrcnt:
+_C_LABEL(eintrcnt):