IO_ICU2
bus_space_map(sio_iot, IO_ICU2, 2, 0, &sio_ioh_icu2))
outb(IO_ICU2, 0x11); /* reset; program device, four bytes */
outb(IO_ICU2+1, ICU_OFFSET+8); /* staring at this vector index */
outb(IO_ICU2+1, IRQ_SLAVE);
outb(IO_ICU2+1, 1); /* 8086 mode */
outb(IO_ICU2+1, 0xff); /* leave interrupts masked */
outb(IO_ICU2, 0x68); /* special mask mode (if available) */
outb(IO_ICU2, 0x0a); /* Read IRR by default. */
port = IO_ICU2 + 1;
port = IO_ICU2 + 1;
outb(IO_ICU2 + 1, i8259_imen >> 8);
outb %al,$IO_ICU2 /* do the second ICU first */ ;\
outb %al,$IO_ICU2 /* do the second ICU first */ ;\
#define SET_ICUS() (outb(IO_ICU1 + 1, imen), outb(IO_ICU2 + 1, imen >> 8))
outb(IO_ICU2, 0x11); /* reset; program device, four bytes */
outb(IO_ICU2+1, ICU_OFFSET+8); /* staring at this vector index */
outb(IO_ICU2+1, IRQ_SLAVE);
outb(IO_ICU2+1, 2 | 1); /* auto EOI, 8086 mode */
outb(IO_ICU2+1, 1); /* 8086 mode */
outb(IO_ICU2+1, 0xff); /* leave interrupts masked */
outb(IO_ICU2, 0x68); /* special mask mode (if available) */
outb(IO_ICU2, 0x0a); /* Read IRR by default. */
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_OCW3) =
ocw2 = REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_OCW3);
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_ICW1) =
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_ICW2) = ICW2_VECTOR(8);
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_ICW3) = ICW3_SIC(2);
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_ICW4) = ICW4_8086;
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_OCW1) = 0xff;
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_OCW3) =
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_OCW3) = OCW3_SELECT | OCW3_RR;
REGVAL8(HTB_IO_BASE + IO_ICU2 + PIC_ICW1) = ICW1_SELECT | ICW1_IC4;
REGVAL8(HTB_IO_BASE + IO_ICU2 + PIC_ICW2) = ICW2_VECTOR(8);
REGVAL8(HTB_IO_BASE + IO_ICU2 + PIC_ICW3) = ICW3_SIC(IRQ_CASCADE);
REGVAL8(HTB_IO_BASE + IO_ICU2 + PIC_ICW4) = ICW4_8086;
REGVAL8(HTB_IO_BASE + IO_ICU2 + PIC_OCW1) = 0xff;
REGVAL8(HTB_IO_BASE + IO_ICU2 + PIC_OCW2) =
REGVAL8(HTB_IO_BASE + IO_ICU2 + PIC_OCW1) = imr2;
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + 1) = imr2;
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + PIC_OCW2) =
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + 1) = 0xff;
REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + 2) = 0xff;
imr2 = 0xff & ~REGVAL8(BONITO_PCIIO_BASE + IO_ICU2 + 1);
isr2 = 0xff & REGVAL8(BONITO_PCIIO_BASE + IO_ICU2);
case IO_ICU2:
case IO_ICU2 + 1:
if (port == IO_ICU1 + 1 || port == IO_ICU2 + 1)
case IO_ICU2:
case IO_ICU2 + 1:
if (port == IO_ICU1 + 1 || port == IO_ICU2 + 1)
ioports_map[IO_ICU2] = vcpu_exit_i8259;
ioports_map[IO_ICU2 + 1] = vcpu_exit_i8259;