Skip to contentSkip to conversation

dra7: add support for two PCIe ports

PATCH Superseded Kishon Vijay Abraham I 4 participants 8 messages Jul 21, 2016 – Jul 22, 2016

Subsystems (5)

v1 of 4 Superseded Latest is v4 →

lore
Share & tools
lore
#0 lore raw

cover dra7: add support for two PCIe ports

This series adds patches to support 2 PCIe ports simultaneously on dra7 based boards.
None of the supported boards exposes 2 PCIe ports. However these are mandatory changes that would be required in order to support 2 PCIe ports.

This series has been tested to see if there are regressions with 1 PCIe port. Though testing of 2 PCIe ports is not done while sending this patch series, it has been verified in few of the customer boards.

Kishon Vijay Abraham I (2):
ARM: dts: DRA7: Add "linux,pci-domain" property for pci dt nodes
ARM: DRA7: select PCI_DOMAINS config

 arch/arm/boot/dts/dra7.dtsi |    2 ++
 arch/arm/mach-omap2/Kconfig |    1 +
 2 files changed, 3 insertions(+)
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/2 ARM: dts: DRA7: Add "linux,pci-domain" property for pci dt nodes

Since DRA7 has multiple PCIe Rootcomplex, add "linux,pci-domain" property to assign a PCI domain number to each of the host bridges.

---
 arch/arm/boot/dts/dra7.dtsi |    2 ++
 1 file changed, 2 insertions(+)
arch/arm/boot/dts/dra7.dtsi +2 -0
index 3a8f397..b275f80 100644
@@ -253,6 +253,7 @@
 					  0x82000000 0 0x20013000 0x13000 0 0xffed000>;
 				#interrupt-cells = <1>;
 				num-lanes = <1>;
+				linux,pci-domain = <0>;
 				ti,hwmods = "pcie1";
 				phys = <&pcie1_phy>;
 				phy-names = "pcie-phy0";
@@ -288,6 +289,7 @@
 					  0x82000000 0 0x30013000 0x13000 0 0xffed000>;
 				#interrupt-cells = <1>;
 				num-lanes = <1>;
+				linux,pci-domain = <1>;
 				ti,hwmods = "pcie2";
 				phys = <&pcie2_phy>;
 				phy-names = "pcie-phy0";
Signature · 1 line
1.7.9.5
#2 lore raw

PATCH 2/2 ARM: DRA7: select PCI_DOMAINS config

In reply to Kishon Vijay Abraham I

PCI_DOMAINS is required for DRA7x SoCs since there are 2 PCIe controllers and without PCI_DOMAINS config, only one PCIe controller gets registered.

---
 arch/arm/mach-omap2/Kconfig |    1 +
 1 file changed, 1 insertion(+)
arch/arm/mach-omap2/Kconfig +1 -0
index 1a648e9..8e6e2c0 100644
@@ -86,6 +86,7 @@ config SOC_DRA7XX
 	select OMAP_INTERCONNECT_BARRIER
 	select PM_OPP if PM
 	select ZONE_DMA if ARM_LPAE
+	select PCI_DOMAINS if PCI
 
 config ARCH_OMAP2PLUS
 	bool
Signature · 1 line
1.7.9.5
#3 lore raw

Re: [PATCH 2/2] ARM: DRA7: select PCI_DOMAINS config

arch/arm/mach-omap2/Kconfig config SOC_DRA7XX · line 92

Quoted 13 lines · CEST Kishon Vijay Abraham I
arch/arm/mach-omap2/Kconfig +1 -0
index 1a648e9..8e6e2c0 100644
@@ -86,6 +86,7 @@ config SOC_DRA7XX
        select OMAP_INTERCONNECT_BARRIER
        select PM_OPP if PM
        select ZONE_DMA if ARM_LPAE
+       select PCI_DOMAINS if PCI
 
 config ARCH_OMAP2PLUS
        bool

Should we just set this unconditionally for ARCH_MULTIPLATFORM maybe?

Arnd

maintainer
#4 lore raw

Re: [PATCH 2/2] ARM: DRA7: select PCI_DOMAINS config

Quoted 11 lines · Arnd Bergmann
Quoted 10 lines · CEST Kishon Vijay Abraham I
arch/arm/mach-omap2/Kconfig +1 -0
index 1a648e9..8e6e2c0 100644
@@ -86,6 +86,7 @@ config SOC_DRA7XX
        select OMAP_INTERCONNECT_BARRIER
        select PM_OPP if PM
        select ZONE_DMA if ARM_LPAE
+       select PCI_DOMAINS if PCI
 
Quoted 5 lines

arch/arm/mach-omap2/Kconfig config SOC_DRA7XX · line 92

Quoted 3 lines
arch/arm/mach-omap2/Kconfig +0 -0
 config ARCH_OMAP2PLUS
        bool

Should we just set this unconditionally for ARCH_MULTIPLATFORM maybe?

Makes sense to me if many SoCs need this.

Regards,

Tony

#5 lore raw

Re: [PATCH 2/2] ARM: DRA7: select PCI_DOMAINS config

Hi,

Quoted 12 lines · Tony Lindgren
Quoted 11 lines · Arnd Bergmann
Quoted 10 lines · CEST Kishon Vijay Abraham I
arch/arm/mach-omap2/Kconfig +1 -0
index 1a648e9..8e6e2c0 100644
@@ -86,6 +86,7 @@ config SOC_DRA7XX
        select OMAP_INTERCONNECT_BARRIER
        select PM_OPP if PM
        select ZONE_DMA if ARM_LPAE
+       select PCI_DOMAINS if PCI
 
Quoted 7 lines
Quoted 5 lines

arch/arm/mach-omap2/Kconfig config SOC_DRA7XX · line 92

Quoted 3 lines
arch/arm/mach-omap2/Kconfig +0 -0
 config ARCH_OMAP2PLUS
        bool

Should we just set this unconditionally for ARCH_MULTIPLATFORM maybe?

Makes sense to me if many SoCs need this.

since it doesn't harm even if a platform has a single PCIe port, it should be okay to set PCI_DOMAINS. I'll resend the following as a separate patch if it's okay.

arch/arm/Kconfig +1 -0
index 90542db..0cccb50 100644
@@ -338,6 +338,7 @@ config ARCH_MULTIPLATFORM
        select MULTI_IRQ_HANDLER
        select SPARSE_IRQ
        select USE_OF
+       select PCI_DOMAINS if PCI
 
 config ARM_SINGLE_ARMV7M
        bool "ARMv7-M based platforms (Cortex-M0/M3/M4)"

Thanks
Kishon

#6 lore raw

Re: [PATCH 2/2] ARM: DRA7: select PCI_DOMAINS config

arch/arm/Kconfig config ARCH_MULTIPLATFORM · line 341

Quoted 9 lines · Kishon Vijay Abraham I
arch/arm/Kconfig +1 -0
index 90542db..0cccb50 100644
@@ -338,6 +338,7 @@ config ARCH_MULTIPLATFORM
        select MULTI_IRQ_HANDLER
        select SPARSE_IRQ
        select USE_OF
+       select PCI_DOMAINS if PCI

Keep the select list in sorted order.

Regards,
Sekhar

#7 lore raw

Re: [PATCH 2/2] ARM: DRA7: select PCI_DOMAINS config

In reply to Kishon Vijay Abraham I
Quoted 10 lines · CEST Kishon Vijay Abraham I

since it doesn't harm even if a platform has a single PCIe port, it should be okay to set PCI_DOMAINS. I'll resend the following as a separate patch if it's okay.

arch/arm/Kconfig +0 -0
index 90542db..0cccb50 100644

arch/arm/Kconfig config ARCH_MULTIPLATFORM · line 342

Quoted 5 lines
arch/arm/Kconfig +1 -0
@@ -338,6 +338,7 @@ config ARCH_MULTIPLATFORM
        select MULTI_IRQ_HANDLER
        select SPARSE_IRQ
        select USE_OF
+       select PCI_DOMAINS if PCI
 

Sounds good, but please remove all other 'select PCI_DOMAINS if PCI' statements in arch/arm then in the same patch.

I have checked that all of them are for ARCH_MULTIPLATFORM based machines.

Arnd