15 #if CONFIG(HAVE_ACPI_TABLES)
16 static const char *pcie_acpi_name(
const struct device *dev)
39 port->bus->secondary == 0 &&
51 static const struct peg_config default_config = { 0 };
54 return &default_config;
59 printk(
BIOS_ERR,
"%s: Found PEG function %u, which doesn't exist on Haswell\n",
61 return &default_config;
63 return &
config->peg_cfg[func];
72 const bool slot_implemented = !peg_cfg->
is_onboard;
74 if (slot_implemented) {
85 slotcap &= ~(0x1fff << 19);
86 if (slot_implemented) {
88 if (slot_number == 0) {
90 slot_number = func + 1;
92 slotcap |= slot_number << 19;
96 slotcap &= ~(3 << 15);
104 slotcap &= ~(0xff << 7);
161 #if CONFIG(HAVE_ACPI_TABLES)
162 .acpi_name = pcie_acpi_name,
167 0x0c01, 0x0c05, 0x0c09, 0x0c0d,
168 0x0d01, 0x0d05, 0x0d09,
171 static const struct pci_driver pch_pcie
__pci_driver = {
#define assert(statement)
#define printk(level,...)
static __always_inline void pci_or_config32(const struct device *dev, u16 reg, u32 ormask)
static __always_inline void pci_write_config32(const struct device *dev, u16 reg, u32 val)
static __always_inline void pci_and_config16(const struct device *dev, u16 reg, u16 andmask)
static __always_inline void pci_update_config32(const struct device *dev, u16 reg, u32 mask, u32 or)
static __always_inline void pci_or_config16(const struct device *dev, u16 reg, u16 ormask)
static __always_inline u32 pci_read_config32(const struct device *dev, u16 reg)
static __always_inline void pci_write_config16(const struct device *dev, u16 reg, u16 val)
static __always_inline void pci_and_config32(const struct device *dev, u16 reg, u32 andmask)
#define BIOS_ERR
BIOS_ERR - System in incomplete state.
static struct device_operations device_ops
static const struct peg_config * get_peg_config(struct device *dev, const uint8_t func)
static const unsigned short pci_device_ids[]
static const struct pci_driver pch_pcie __pci_driver
static void peg_enable(struct device *dev)
#define PCI_DEVFN(slot, func)
void pci_dev_init(struct device *dev)
Default handler: only runs the relevant PCI BIOS.
void pci_bus_enable_resources(struct device *dev)
void pci_bus_read_resources(struct device *dev)
void pci_bus_reset(struct bus *bus)
struct pci_operations pci_dev_ops_pci
Default device operation for PCI devices.
void pci_dev_set_resources(struct device *dev)
void pciexp_scan_bridge(struct device *dev)
DEVTREE_CONST struct device * dev
void(* read_resources)(struct device *dev)
enum device_path_type type
DEVTREE_CONST struct bus * bus
DEVTREE_CONST void * chip_info
uint16_t phys_slot_number
uint8_t power_limit_value
uint8_t power_limit_scale