diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2018-07-04 20:46:23 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2018-07-04 20:46:23 +0000 |
commit | 5122a3c63dc86357891a0e94d2a3f20ae1098312 (patch) | |
tree | 450e14d17a4f288ad09664503fd9cf7e8141b621 /sys/arch/amd64/pci | |
parent | 11362c6c7cabcf7e045553f2434744084bf45d08 (diff) |
Properly pass around the PCI "chipset tag" in acpi(4) and refactor
acpimcfg(4) to call an MD initialization functions that sets up a tag for
PCI ECAM.
ok guenther@, mlarkin@, krw@
Diffstat (limited to 'sys/arch/amd64/pci')
-rw-r--r-- | sys/arch/amd64/pci/pci_machdep.c | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/sys/arch/amd64/pci/pci_machdep.c b/sys/arch/amd64/pci/pci_machdep.c index 2ea97e1ab36..5e05c750a0c 100644 --- a/sys/arch/amd64/pci/pci_machdep.c +++ b/sys/arch/amd64/pci/pci_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pci_machdep.c,v 1.67 2017/10/14 04:44:43 jsg Exp $ */ +/* $OpenBSD: pci_machdep.c,v 1.68 2018/07/04 20:46:22 kettenis Exp $ */ /* $NetBSD: pci_machdep.c,v 1.3 2003/05/07 21:33:58 fvdl Exp $ */ /*- @@ -99,9 +99,8 @@ */ bus_addr_t pci_mcfg_addr; int pci_mcfg_min_bus, pci_mcfg_max_bus; -bus_space_tag_t pci_mcfgt = X86_BUS_SPACE_MEM; +bus_space_tag_t pci_mcfgt; bus_space_handle_t pci_mcfgh[256]; -void pci_mcfg_map_bus(int); struct mutex pci_conf_lock = MUTEX_INITIALIZER(IPL_HIGH); @@ -141,6 +140,17 @@ struct bus_dma_tag pci_bus_dma_tag = { _bus_dmamem_mmap, }; +pci_chipset_tag_t +pci_mcfg_init(bus_space_tag_t iot, bus_addr_t addr, int min_bus, int max_bus) +{ + pci_mcfgt = iot; + pci_mcfg_addr = addr; + pci_mcfg_min_bus = min_bus; + pci_mcfg_max_bus = max_bus; + + return NULL; +} + void pci_attach_hook(struct device *parent, struct device *self, struct pcibus_attach_args *pba) |