PCI-to-PCI bridge.
Definition in file pcibridge.c.
static int pcibridge_probe |
( |
struct pci_device * |
pci | ) |
|
|
static |
Probe PCI device.
- Parameters
-
- Return values
-
Definition at line 67 of file pcibridge.c.
74 bridge =
zalloc (
sizeof ( *bridge ) );
88 DBGC ( bridge,
"BRIDGE " PCI_FMT " bus %02x to [%02x,%02x) mem " #define PCI_MEM_BASE
Memory base and limit.
struct arbelprm_rc_send_wqe rc
uint8_t subordinate
Subordinate bus.
#define list_add(new, head)
Add a new entry to the head of a list.
int pci_read_config_word(struct pci_device *pci, unsigned int where, uint16_t *value)
Read 16-bit word from PCI configuration space.
static void pci_set_drvdata(struct pci_device *pci, void *priv)
Set PCI driver-private data.
#define ENOMEM
Not enough space.
#define PCI_PRIMARY
Primary bus number.
int pci_read_config_dword(struct pci_device *pci, unsigned int where, uint32_t *value)
Read 32-bit dword from PCI configuration space.
struct pci_device * pci
PCI device.
#define cpu_to_le32s(ptr)
static void(* free)(struct refcnt *refcnt))
void * zalloc(size_t size)
Allocate cleared memory.
#define PCI_FMT
PCI device debug message format.
uint8_t primary
Primary bus.
uint32_t memlimit
Memory limit.
uint8_t secondary
Secondary bus.
struct list_head list
List of bridges.
#define PCI_ARGS(pci)
PCI device debug message arguments.
uint32_t membase
Memory base.
References base, pci_bridge::buses, cpu_to_le32s, DBGC, ENOMEM, free, limit, pci_bridge::list, list_add, pci_bridge::membase, pci_bridge::memlimit, pci_bridge::pci, PCI_ARGS, PCI_FMT, PCI_MEM_BASE, PCI_MEM_LIMIT, PCI_MEM_MASK, PCI_PRIMARY, pci_read_config_dword(), pci_read_config_word(), pci_set_drvdata(), pci_bridge::primary, rc, pci_bridge::secondary, pci_bridge::subordinate, and zalloc().