Skip to contentSkip to conversation

ARM: mvebu: coherency: fix registration of PCI bus notifier when !PCI

PATCH New Thomas Petazzoni 2 participants 2 messages May 20, 2014 – May 22, 2014

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: mvebu: coherency: fix registration of PCI bus notifier when !PCI

Commit b0063aad5dd8 ("ARM: mvebu: use hardware I/O coherency also for PCI devices") added a reference to the pci_bus_type variable, but this variable is only available when CONFIG_PCI is enabled. Therefore, there is now a build failure in !CONFIG_PCI situations.

This commit fixes that by enclosing the entire initcall into a IS_ENABLED(CONFIG_PCI) condition.

---
This applies on top of mvebu/soc. No need to push for 3.15-rc, the patch being fixed is only for 3.16.

---
 arch/arm/mach-mvebu/coherency.c | 2 ++
 1 file changed, 2 insertions(+)
arch/arm/mach-mvebu/coherency.c +2 -0
index a222507..477202f 100644
@@ -422,6 +422,7 @@ static int __init coherency_late_init(void)
 
 postcore_initcall(coherency_late_init);
 
+#if IS_ENABLED(CONFIG_PCI)
 static int __init coherency_pci_init(void)
 {
 	if (coherency_available())
@@ -431,3 +432,4 @@ static int __init coherency_pci_init(void)
 }
 
 arch_initcall(coherency_pci_init);
+#endif
Signature · 1 line
1.9.3
Applied
#1 lore raw

PATCH 1/1 ARM: mvebu: coherency: fix registration of PCI bus notifier when !PCI

Quoted 10 lines · Thomas Petazzoni

Commit b0063aad5dd8 ("ARM: mvebu: use hardware I/O coherency also for PCI devices") added a reference to the pci_bus_type variable, but this variable is only available when CONFIG_PCI is enabled. Therefore, there is now a build failure in !CONFIG_PCI situations.

This commit fixes that by enclosing the entire initcall into a IS_ENABLED(CONFIG_PCI) condition.

Quoted 8 lines

---
This applies on top of mvebu/soc. No need to push for 3.15-rc, the patch being fixed is only for 3.16.

---
 arch/arm/mach-mvebu/coherency.c | 2 ++
 1 file changed, 2 insertions(+)

Applied to mvebu/soc

thx,

Jason.