/* pci-mmconfig.c */
+struct pci_mmcfg_region {
+ u64 address;
+ u16 pci_segment;
+ u8 start_bus_number;
+ u8 end_bus_number;
+};
+
extern int __init pci_mmcfg_arch_init(void);
extern void __init pci_mmcfg_arch_free(void);
-extern struct acpi_mcfg_allocation *pci_mmcfg_config;
+extern struct pci_mmcfg_region *pci_mmcfg_config;
extern int pci_mmcfg_config_num;
#define PCI_MMCFG_BUS_OFFSET(bus) ((bus) << 20)
pci_mmcfg_config = NULL;
}
-static __init struct acpi_mcfg_allocation *pci_mmconfig_add(int segment,
- int start, int end, u64 addr)
+static __init struct pci_mmcfg_region *pci_mmconfig_add(int segment, int start,
+ int end, u64 addr)
{
- struct acpi_mcfg_allocation *new;
+ struct pci_mmcfg_region *new;
int new_num = pci_mmcfg_config_num + 1;
int i = pci_mmcfg_config_num;
names = (void *)&res[pci_mmcfg_config_num];
for (i = 0; i < pci_mmcfg_config_num; i++, res++) {
- struct acpi_mcfg_allocation *cfg = &pci_mmcfg_config[i];
+ struct pci_mmcfg_region *cfg = &pci_mmcfg_config[i];
num_buses = cfg->end_bus_number - cfg->start_bus_number + 1;
res->name = names;
snprintf(names, PCI_MMCFG_RESOURCE_NAME_LEN,
static int __initdata known_bridge;
/* The physical address of the MMCONFIG aperture. Set from ACPI tables. */
-struct acpi_mcfg_allocation *pci_mmcfg_config;
+struct pci_mmcfg_region *pci_mmcfg_config;
int pci_mmcfg_config_num;
static int __init acpi_mcfg_check_entry(struct acpi_table_mcfg *mcfg,
*/
static u32 get_base_addr(unsigned int seg, int bus, unsigned devfn)
{
- struct acpi_mcfg_allocation *cfg;
+ struct pci_mmcfg_region *cfg;
int cfg_num;
for (cfg_num = 0; cfg_num < pci_mmcfg_config_num; cfg_num++) {
/* Static virtual mapping of the MMCONFIG aperture */
struct mmcfg_virt {
- struct acpi_mcfg_allocation *cfg;
+ struct pci_mmcfg_region *cfg;
char __iomem *virt;
};
static struct mmcfg_virt *pci_mmcfg_virt;
static char __iomem *get_virt(unsigned int seg, unsigned bus)
{
- struct acpi_mcfg_allocation *cfg;
+ struct pci_mmcfg_region *cfg;
int cfg_num;
for (cfg_num = 0; cfg_num < pci_mmcfg_config_num; cfg_num++) {
.write = pci_mmcfg_write,
};
-static void __iomem * __init mcfg_ioremap(struct acpi_mcfg_allocation *cfg)
+static void __iomem * __init mcfg_ioremap(struct pci_mmcfg_region *cfg)
{
void __iomem *addr;
u64 start, size;