aboutsummaryrefslogtreecommitdiff
path: root/hw/pci.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/pci.c')
-rw-r--r--hw/pci.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/pci.c b/hw/pci.c
index 2fed66f0a1..6035c890a8 100644
--- a/hw/pci.c
+++ b/hw/pci.c
@@ -494,7 +494,7 @@ PIIX3State *piix3_state;
static inline int pci_slot_get_pirq(PCIDevice *pci_dev, int irq_num)
{
int slot_addend;
- slot_addend = (pci_dev->devfn >> 3);
+ slot_addend = (pci_dev->devfn >> 3) - 1;
return (irq_num + slot_addend) & 3;
}