31 #ifndef CPU_X86_DRIVERS_LEGACY_PC_PCI_H_
32 #define CPU_X86_DRIVERS_LEGACY_PC_PCI_H_
37 #include "prot-domains.h"
40 #define PCI_CONFIG_REG_BAR0 0x10
41 #define PCI_CONFIG_REG_BAR1 0x14
75 #define PCI_CMD_2_BUS_MST_EN BIT(2)
77 #define PCI_CMD_1_MEM_SPACE_EN BIT(1)
105 void pci_init(
pci_driver_t ATTR_KERN_ADDR_SPACE *c_this,
110 void pci_irq_agent_set_pirq(IRQAGENT agent, INTR_PIN pin, PIRQ pirq);
111 void pci_pirq_set_irq(PIRQ pirq, uint8_t irq, uint8_t route_to_legacy);
112 void pci_root_complex_init(
void);
113 void pci_root_complex_lock(
void);
115 #define PCI_MMIO_READL(c_this, dest, reg_addr) \
117 *((volatile uint32_t ATTR_MMIO_ADDR_SPACE *) \
118 (((uintptr_t)PROT_DOMAINS_MMIO(c_this)) + (reg_addr))))
119 #define PCI_MMIO_WRITEL(c_this, reg_addr, src) \
120 MMIO_WRITEL(*((volatile uint32_t ATTR_MMIO_ADDR_SPACE *) \
121 (((uintptr_t)PROT_DOMAINS_MMIO(c_this)) + (reg_addr))), \
uint32_t func
Function number.
static uip_ds6_addr_t * addr
Pointer to a router list entry.
PCI configuration address.
uint32_t dev
Device number.
Data associated with each protection domain that is owned by clients of that domain and used to ident...
uint32_t en_mapping
Must be set to perform PCI configuration access.
uint32_t reg_off
Register/offset number.