diff options
Diffstat (limited to 'sys/dev/pci/pci_pci.c')
-rw-r--r-- | sys/dev/pci/pci_pci.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/sys/dev/pci/pci_pci.c b/sys/dev/pci/pci_pci.c index d0ac287..1b9a3eb 100644 --- a/sys/dev/pci/pci_pci.c +++ b/sys/dev/pci/pci_pci.c @@ -82,8 +82,8 @@ static device_method_t pcib_methods[] = { DEVMETHOD(pcib_alloc_msi, pcib_alloc_msi), DEVMETHOD(pcib_release_msi, pcib_release_msi), DEVMETHOD(pcib_alloc_msix, pcib_alloc_msix), - DEVMETHOD(pcib_remap_msix, pcib_remap_msix), DEVMETHOD(pcib_release_msix, pcib_release_msix), + DEVMETHOD(pcib_map_msi, pcib_map_msi), { 0, 0 } }; @@ -547,7 +547,7 @@ pcib_route_interrupt(device_t pcib, device_t dev, int pin) return(intnum); } -/* Pass request to alloc MSI messages up to the parent bridge. */ +/* Pass request to alloc MSI/MSI-X messages up to the parent bridge. */ int pcib_alloc_msi(device_t pcib, device_t dev, int count, int maxcount, int *irqs) { @@ -561,7 +561,7 @@ pcib_alloc_msi(device_t pcib, device_t dev, int count, int maxcount, int *irqs) irqs)); } -/* Pass request to release MSI messages up to the parent bridge. */ +/* Pass request to release MSI/MSI-X messages up to the parent bridge. */ int pcib_release_msi(device_t pcib, device_t dev, int count, int *irqs) { @@ -573,7 +573,7 @@ pcib_release_msi(device_t pcib, device_t dev, int count, int *irqs) /* Pass request to alloc an MSI-X message up to the parent bridge. */ int -pcib_alloc_msix(device_t pcib, device_t dev, int index, int *irq) +pcib_alloc_msix(device_t pcib, device_t dev, int *irq) { struct pcib_softc *sc = device_get_softc(dev); device_t bus; @@ -581,27 +581,28 @@ pcib_alloc_msix(device_t pcib, device_t dev, int index, int *irq) if (sc->flags & PCIB_DISABLE_MSI) return (ENXIO); bus = device_get_parent(pcib); - return (PCIB_ALLOC_MSIX(device_get_parent(bus), dev, index, irq)); + return (PCIB_ALLOC_MSIX(device_get_parent(bus), dev, irq)); } -/* Pass request to remap an MSI-X message up to the parent bridge. */ +/* Pass request to release an MSI-X message up to the parent bridge. */ int -pcib_remap_msix(device_t pcib, device_t dev, int index, int irq) +pcib_release_msix(device_t pcib, device_t dev, int irq) { device_t bus; bus = device_get_parent(pcib); - return (PCIB_REMAP_MSIX(device_get_parent(bus), dev, index, irq)); + return (PCIB_RELEASE_MSIX(device_get_parent(bus), dev, irq)); } -/* Pass request to release an MSI-X message up to the parent bridge. */ +/* Pass request to map MSI/MSI-X message up to parent bridge. */ int -pcib_release_msix(device_t pcib, device_t dev, int irq) +pcib_map_msi(device_t pcib, device_t dev, int irq, uint64_t *addr, + uint32_t *data) { device_t bus; bus = device_get_parent(pcib); - return (PCIB_RELEASE_MSIX(device_get_parent(bus), dev, irq)); + return (PCIB_MAP_MSI(device_get_parent(bus), dev, irq, addr, data)); } /* |