pci_map_irq
![]() |
![]() |
![]() |
![]() |
pci_map_irq()
Map an interrupt pin to an IRQ
Synopsis:
#include <hw/pci.h>
int pci_map_irq( unsigned bus,
unsigned dev_func,
short intno,
short intpin );
Arguments:
- bus
- The bus number of the device.
- dev_func
- The device or function number of the device. The device number is in bits 7 through 3, and the function number is in bits 2 through 0.
- intno
- The interrupt to be mapped (e.g. 0 - 15 on x86).
- intpin
- The PCI interrupt pin (0x0a - 0x0d).
Library:
libc
Use the -l c option to qcc to link against this library. This library is usually included automatically.
Description:
The pci_map_irq() function maps a PCI interrupt pin to a specific interrupt request (IRQ).
Returns:
- PCI_SUCCESS
- Success.
- PCI_SET_FAILED
- The PCI server was unable to map the intno/intpin.
- PCI_UNSUPPORTED_FUNCTION
- This function isn't supported.
- -1
- You haven't called pci_attach(), or the call to it failed.
Classification:
| Safety: | |
|---|---|
| Cancellation point | Yes |
| Interrupt handler | No |
| Signal handler | Yes |
| Thread | Yes |
See also:
pci_attach(), pci_attach_device(), pci_detach(), pci_detach_device(), pci_find_class(), pci_find_device(), pci_present(), pci_read_config(), pci_read_config8(), pci_read_config16(), pci_read_config32(), pci_rescan_bus(), pci_write_config(), pci_write_config8(), pci_write_config16(), pci_write_config32()
![]() |
![]() |
![]() |
![]() |
![[Previous]](../prev.gif)
![[Contents]](../contents.gif)
![[Index]](../keyword_index.gif)
![[Next]](../next.gif)
