ARM: Dove: allow PCI to be disabled
PATCH 1/1 ARM: Dove: allow PCI to be disabled
Allow PCI support for Dove to be disabled. Some platforms do not have anything connected to the PCIe ports, so requiring PCI support to be built into the kernel just wastes space, and presents a lot more config options than are necessary.
However, select USB_ARCH_HAS_EHCI so that we can still have EHCI support.
--- arch/arm/Kconfig | 3 ++- arch/arm/mach-dove/Makefile | 3 ++- arch/arm/mach-dove/common.h | 4 ++++ 3 files changed, 8 insertions(+), 2 deletions(-)
arch/arm/Kconfig +2 -1
@@ -536,14 +536,15 @@ config ARCH_IXP4XX config ARCH_DOVE bool "Marvell Dove" select CPU_V7 - select PCI select ARCH_REQUIRE_GPIOLIB select GENERIC_CLOCKEVENTS + select MIGHT_HAVE_PCI select NEED_MACH_IO_H select PLAT_ORION select CLKDEV_LOOKUP select NEED_MACH_MEMORY_H select COMMON_CLK + select USB_ARCH_HAS_EHCI help Support for the Marvell Dove SoC 88AP510
arch/arm/mach-dove/Makefile +2 -1
@@ -1,4 +1,5 @@ -obj-y += common.o addr-map.o irq.o pcie.o mpp.o clock.o dump_cp15_regs.o +obj-y += common.o addr-map.o irq.o mpp.o clock.o dump_cp15_regs.o +obj-$(CONFIG_PCI) += pcie.o obj-$(CONFIG_MACH_DOVE_DB) += dove-db-setup.o obj-$(CONFIG_MACH_CM_A510) += cm-a510.o
arch/arm/mach-dove/common.h +4 -0
@@ -29,7 +29,11 @@ void dove_setup_cpu_mbus(void);void dove_ge00_init (struct mv643xx_eth_platform_data *eth_data);void dove_hwmon_init (void );void dove_sata_init (struct mv_sata_platform_data *sata_data); +#ifdef CONfig_PCIvoid dove_pcie_init (int init_port0,int init_port1); +#else +static inline void dove_pcie_init (int init_port0,int init_port1) { } +#endif void dove_ehci0_init (void );void dove_ehci1_init (void );void dove_uart0_init (void );
PATCH 1/1 ARM: Dove: allow PCI to be disabled
Quoted 52 lines · Russell King - ARM Linux
Allow PCI support for Dove to be disabled. Some platforms do not have anything connected to the PCIe ports, so requiring PCI support to be built into the kernel just wastes space, and presents a lot more config options than are necessary.
However, select
USB_ARCH_HAS_EHCIso that we can still have EHCI support.Signed-off-by Russell King <[email protected]>--- arch/arm/Kconfig | 3 ++- arch/arm/mach-dove/Makefile | 3 ++- arch/arm/mach-dove/common.h | 4 ++++ 3 files changed, 8 insertions(+), 2 deletions(-)arch/arm/Kconfig +2
-1@@ -536,14 +536,15 @@ config ARCH_IXP4XX config ARCH_DOVE bool "Marvell Dove" select CPU_V7 - select PCI select ARCH_REQUIRE_GPIOLIB select GENERIC_CLOCKEVENTS + select MIGHT_HAVE_PCI select NEED_MACH_IO_H select PLAT_ORION select CLKDEV_LOOKUP select NEED_MACH_MEMORY_H select COMMON_CLK + select USB_ARCH_HAS_EHCI help Support for the Marvell Dove SoC 88AP510arch/arm/mach-dove/Makefile +2
-1@@ -1,4 +1,5 @@ -obj-y += common.o addr-map.o irq.o pcie.o mpp.o clock.o dump_cp15_regs.o +obj-y += common.o addr-map.o irq.o mpp.o clock.o dump_cp15_regs.o +obj-$(CONFIG_PCI) += pcie.o obj-$(CONFIG_MACH_DOVE_DB) += dove-db-setup.o obj-$(CONFIG_MACH_CM_A510) += cm-a510.oarch/arm/mach-dove/common.h +0
-0
arch/arm/mach-dove/common.h void dove_setup_cpu_mbus(void); · line 32
Quoted 4 lines
arch/arm/mach-dove/common.h +1
-0@@ -29,7 +29,11 @@ void dove_setup_cpu_mbus(void);void dove_ge00_init (struct mv643xx_eth_platform_data *eth_data);void dove_hwmon_init (void );void dove_sata_init (struct mv_sata_platform_data *sata_data); +#ifdef CONfig_PCI
ummm... ^^^^^^ is this a typo? (/me dives into a trench)
arch/arm/mach-dove/common.h void dove_setup_cpu_mbus(void); · line 39
Quoted 7 lines
arch/arm/mach-dove/common.h +3
-0void dove_pcie_init (int init_port0,int init_port1); +#else +static inline void dove_pcie_init (int init_port0,int init_port1) { } +#endif void dove_ehci0_init (void );void dove_ehci1_init (void );void dove_uart0_init (void );
thx,
Jason.
PATCH 1/1 ARM: Dove: allow PCI to be disabled
Quoted 4 lines · Jason Cooper
Quoted 1 line · Russell King - ARM Linux
+#ifdef
CONfig_PCIummm... ^^^^^^ is this a typo? (/me dives into a trench)
No, it's your imagination playing tricks again. :) I'll get a new patch out when I'm in a state that I can redo the git commit without destroying the current state of my development git tree.
(which may be a while as I'm trying to sort out why ubuntu 12.04 userspace seems to be a total disaster on the cubox.)