diff options
Diffstat (limited to 'include/hw/pci/pci.h')
-rw-r--r-- | include/hw/pci/pci.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/hw/pci/pci.h b/include/hw/pci/pci.h index 5b36334..483d5c7 100644 --- a/include/hw/pci/pci.h +++ b/include/hw/pci/pci.h @@ -735,6 +735,11 @@ void lsi53c8xx_handle_legacy_cmdline(DeviceState *lsi_dev); qemu_irq pci_allocate_irq(PCIDevice *pci_dev); void pci_set_irq(PCIDevice *pci_dev, int level); +static inline int pci_intx(PCIDevice *pci_dev) +{ + return pci_get_byte(pci_dev->config + PCI_INTERRUPT_PIN) - 1; +} + static inline void pci_irq_assert(PCIDevice *pci_dev) { pci_set_irq(pci_dev, 1); |