Attention is currently required from: Shelley Chen, Furquan Shaikh, Kyösti Mälkki. Hello Shelley Chen, Furquan Shaikh, Kyösti Mälkki,
I'd like you to do a code review. Please visit
https://review.coreboot.org/c/coreboot/+/58331
to review the following change.
Change subject: [RFC] pci_mmio_cfg: Move guard around pci_s_* functions to x86 ......................................................................
[RFC] pci_mmio_cfg: Move guard around pci_s_* functions to x86
There is no platform in our tree that requires the PCI MMIO ops but doesn't want the pci_s_* definitions. The only case where we include the `pci_mmio_cfg.h` header but don't want the pci_s_* functions to use MMIO is on older x86 platforms, so move the guard there.
Change-Id: Iaeed6ab43ad61b7c0e14572b12bf4ec06b6a26af Signed-off-by: Nico Huber nico.huber@secunet.com --- M src/arch/x86/include/arch/pci_ops.h M src/include/device/pci_mmio_cfg.h 2 files changed, 4 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/31/58331/1
diff --git a/src/arch/x86/include/arch/pci_ops.h b/src/arch/x86/include/arch/pci_ops.h index 317e597..abbd35c 100644 --- a/src/arch/x86/include/arch/pci_ops.h +++ b/src/arch/x86/include/arch/pci_ops.h @@ -4,6 +4,8 @@ #define ARCH_I386_PCI_OPS_H
#include <arch/pci_io_cfg.h> +#if CONFIG(MMCONF_SUPPORT) #include <device/pci_mmio_cfg.h> +#endif
#endif /* ARCH_I386_PCI_OPS_H */ diff --git a/src/include/device/pci_mmio_cfg.h b/src/include/device/pci_mmio_cfg.h index 8798405..e873abc 100644 --- a/src/include/device/pci_mmio_cfg.h +++ b/src/include/device/pci_mmio_cfg.h @@ -105,6 +105,8 @@ #error "CONFIG_MMCONF_LENGTH does not correspond with CONFIG_MMCONF_BUS_NUMBER!" #endif
+#endif + /* Avoid name collisions as different stages have different signature * for these functions. The _s_ stands for simple, fundamental IO or * MMIO variant. @@ -146,6 +148,4 @@ pci_mmio_write_config32(dev, reg, value); }
-#endif - #endif /* _PCI_MMIO_CFG_H */