MIPS: asm: pci: define arch-specific 'pci_remap_iospace()' dependent on 'CONFIG_PCI_DRIVERS_GENERIC'
Subsystems (2)
PATCH 1/1 MIPS: asm: pci: define arch-specific 'pci_remap_iospace()' dependent on 'CONFIG_PCI_DRIVERS_GENERIC'
Some MIPS defconfigs that don't define 'CONFIG_PCI_DRIVERS_GENERIC' but define 'CONFIG_PCI_DRIVERS_LEGACY' or none of them, can fail when they are built since definition for 'pci_remap_iospace' is being done in include file 'arch/mips/include/asm/pci.h' and the specific function implemented in 'arch/mips/pci/pci-generic.c'. MIPS PCI drivers that don't use generic PCI core APIs don't really need 'pci_remap_iospace' to be defined at all. Hence, change definition for 'pci_remap_iospace' to be dependent on the preprocessor 'CONFIG_PCI_DRIVERS_GENERIC' definition to avoid possible build problems.
---
Hi Greg, Thomas, Stephen,
I guess this should also go through the staging-tree.
Thanks in advance for your time.
Best regards,
Sergio Paracuellos
arch/mips/include/asm/pci.h | 2 ++ 1 file changed, 2 insertions(+)
arch/mips/include/asm/pci.h +2 -0
@@ -20,7 +20,9 @@#include <linux/list.h> #include <linux/of.h> +#ifdef CONFIG_PCI_DRIVERS_GENERIC #define pci_remap_iospace pci_remap_iospace +#endif #ifdef CONFIG_PCI_DRIVERS_LEGACY
Signature · 1 line
2.33.0
Quoted 10 lines · Sergio Paracuellos
Some MIPS defconfigs that don't define '
CONFIG_PCI_DRIVERS_GENERIC' but define 'CONFIG_PCI_DRIVERS_LEGACY' or none of them, can fail when they are built since definition for 'pci_remap_iospace' is being done in include file 'arch/mips/include/asm/pci.h' and the specific function implemented in 'arch/mips/pci/pci-generic.c'. MIPS PCI drivers that don't use generic PCI core APIs don't really need 'pci_remap_iospace' to be defined at all. Hence, change definition for 'pci_remap_iospace' to be dependent on the preprocessor 'CONFIG_PCI_DRIVERS_GENERIC' definition to avoid possible build problems.
Quoted 8 lines
CC Thomas Bogendoerfer <[email protected]>Fixes 9f76779f2418 ("MIPS: implement architecture-specific 'pci_remap_iospace()'")Reported-by Stephen Rothwell <[email protected]>Signed-off-by Sergio Paracuellos <[email protected]>---
Hi Greg, Thomas, Stephen,I guess this should also go through the staging-tree.
Now queued up, thanks!
greg k-h
Quoted 19 lines · Greg KH
Quoted 17 lines · Sergio Paracuellos
Some MIPS defconfigs that don't define '
CONFIG_PCI_DRIVERS_GENERIC' but define 'CONFIG_PCI_DRIVERS_LEGACY' or none of them, can fail when they are built since definition for 'pci_remap_iospace' is being done in include file 'arch/mips/include/asm/pci.h' and the specific function implemented in 'arch/mips/pci/pci-generic.c'. MIPS PCI drivers that don't use generic PCI core APIs don't really need 'pci_remap_iospace' to be defined at all. Hence, change definition for 'pci_remap_iospace' to be dependent on the preprocessor 'CONFIG_PCI_DRIVERS_GENERIC' definition to avoid possible build problems.CC Thomas Bogendoerfer <[email protected]>Fixes 9f76779f2418 ("MIPS: implement architecture-specific 'pci_remap_iospace()'")Reported-by Stephen Rothwell <[email protected]>Signed-off-by Sergio Paracuellos <[email protected]>---
Hi Greg, Thomas, Stephen,
Quoted 3 lines
Quoted 1 line
I guess this should also go through the staging-tree.
Now queued up, thanks!
Thanks, Greg!
Best regards,
Sergio Paracuellos
Quoted 2 lines
greg k-h