From f0633753fc76793fe9d572d65ccd6eef08738481 Mon Sep 17 00:00:00 2001 From: OBattler Date: Fri, 10 Jul 2020 03:14:15 +0200 Subject: [PATCH] Fixed STPC PCI IRQ steering again. --- src/chipset/stpc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/chipset/stpc.c b/src/chipset/stpc.c index 30a4ab988..81262b993 100644 --- a/src/chipset/stpc.c +++ b/src/chipset/stpc.c @@ -626,9 +626,9 @@ stpc_reg_write(uint16_t addr, uint8_t val, void *priv) break; case 0x52: case 0x53: case 0x54: case 0x55: - stpc_log("STPC: Set IRQ routing: INT %c -> %d\n", 0x41 + (dev->reg_offset & 0x03), (val & 0x80) ? (val & 0xf) : -1); + stpc_log("STPC: Set IRQ routing: INT %c -> %d\n", 0x41 + ((dev->reg_offset - 2) & 0x03), (val & 0x80) ? (val & 0xf) : -1); val &= 0x8f; - pci_set_irq_routing(PCI_INTA + (dev->reg_offset & 0x03), (val & 0x80) ? (val & 0xf) : PCI_IRQ_DISABLED); + pci_set_irq_routing(PCI_INTA + ((dev->reg_offset - 2) & 0x03), (val & 0x80) ? (val & 0xf) : PCI_IRQ_DISABLED); break; case 0x56: case 0x57: