diff options
author | jhb <jhb@FreeBSD.org> | 2003-09-10 01:07:04 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2003-09-10 01:07:04 +0000 |
commit | 16813b69977310dc2533b60862f5e68f7e19e983 (patch) | |
tree | 90ea25ec88f9daad93e8c3cb1af55a4653f71050 /sys/i386/isa/npx.c | |
parent | 2bba7f535951f7aa2ad42629ab3c624b9a84fafa (diff) | |
download | FreeBSD-src-16813b69977310dc2533b60862f5e68f7e19e983.zip FreeBSD-src-16813b69977310dc2533b60862f5e68f7e19e983.tar.gz |
Add constants for entries in the IDT and use those instead of magic
numbers.
Diffstat (limited to 'sys/i386/isa/npx.c')
-rw-r--r-- | sys/i386/isa/npx.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/i386/isa/npx.c b/sys/i386/isa/npx.c index a254d47..fbd4643 100644 --- a/sys/i386/isa/npx.c +++ b/sys/i386/isa/npx.c @@ -284,8 +284,9 @@ npx_probe(dev) u_short control; u_short status; - save_idt_npxtrap = idt[16]; - setidt(16, probetrap, SDT_SYS386TGT, SEL_KPL, GSEL(GCODE_SEL, SEL_KPL)); + save_idt_npxtrap = idt[IDT_MF]; + setidt(IDT_MF, probetrap, SDT_SYS386TGT, SEL_KPL, + GSEL(GCODE_SEL, SEL_KPL)); ioport_rid = 0; ioport_res = bus_alloc_resource(dev, SYS_RES_IOPORT, &ioport_rid, IO_NPX, IO_NPX, IO_NPXSIZE, RF_ACTIVE); @@ -411,7 +412,7 @@ npx_probe(dev) * Bad, we are stuck with IRQ13. */ npx_irq13 = 1; - idt[16] = save_idt_npxtrap; + idt[IDT_MF] = save_idt_npxtrap; return (0); } /* @@ -426,7 +427,7 @@ npx_probe(dev) */ /* FALLTHROUGH */ no_irq13: - idt[16] = save_idt_npxtrap; + idt[IDT_MF] = save_idt_npxtrap; bus_teardown_intr(dev, irq_res, irq_cookie); /* |