* [PATCH v3 1/4] dt-bindings: PCI: qcom: Add sa8775p compatible
2023-07-21 17:24 [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Mrinmay Sarkar
@ 2023-07-21 17:24 ` Mrinmay Sarkar
2023-07-24 6:16 ` Manivannan Sadhasivam
2023-07-21 17:24 ` [PATCH v3 2/4] PCI: qcom: Add support for sa8775p SoC Mrinmay Sarkar
` (4 subsequent siblings)
5 siblings, 1 reply; 10+ messages in thread
From: Mrinmay Sarkar @ 2023-07-21 17:24 UTC (permalink / raw)
To: agross, andersson, krzysztof.kozlowski+dt, conor+dt,
konrad.dybcio, mani
Cc: quic_shazhuss, quic_nitegupt, quic_ramkri, quic_nayiluri,
dmitry.baryshkov, Mrinmay Sarkar, Lorenzo Pieralisi,
Krzysztof Wilczyński, Rob Herring, Bjorn Helgaas,
linux-arm-msm, linux-pci, devicetree, linux-kernel
Add sa8775p platform to the binding.
Signed-off-by: Mrinmay Sarkar <quic_msarkar@quicinc.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
.../devicetree/bindings/pci/qcom,pcie.yaml | 28 ++++++++++++++++++++++
1 file changed, 28 insertions(+)
diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml
index 81971be4..eadba38 100644
--- a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml
+++ b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml
@@ -29,6 +29,7 @@ properties:
- qcom,pcie-msm8996
- qcom,pcie-qcs404
- qcom,pcie-sa8540p
+ - qcom,pcie-sa8775p
- qcom,pcie-sc7280
- qcom,pcie-sc8180x
- qcom,pcie-sc8280xp
@@ -211,6 +212,7 @@ allOf:
compatible:
contains:
enum:
+ - qcom,pcie-sa8775p
- qcom,pcie-sc7280
- qcom,pcie-sc8180x
- qcom,pcie-sc8280xp
@@ -748,7 +750,32 @@ allOf:
compatible:
contains:
enum:
+ - qcom,pcie-sa8775p
+ then:
+ properties:
+ clocks:
+ minItems: 5
+ maxItems: 5
+ clock-names:
+ items:
+ - const: aux # Auxiliary clock
+ - const: cfg # Configuration clock
+ - const: bus_master # Master AXI clock
+ - const: bus_slave # Slave AXI clock
+ - const: slave_q2a # Slave Q2A clock
+ resets:
+ maxItems: 1
+ reset-names:
+ items:
+ - const: pci # PCIe core reset
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
- qcom,pcie-sa8540p
+ - qcom,pcie-sa8775p
- qcom,pcie-sc8280xp
then:
required:
@@ -790,6 +817,7 @@ allOf:
contains:
enum:
- qcom,pcie-msm8996
+ - qcom,pcie-sa8775p
- qcom,pcie-sc7280
- qcom,pcie-sc8180x
- qcom,pcie-sdm845
--
2.7.4
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH v3 1/4] dt-bindings: PCI: qcom: Add sa8775p compatible
2023-07-21 17:24 ` [PATCH v3 1/4] dt-bindings: PCI: qcom: Add sa8775p compatible Mrinmay Sarkar
@ 2023-07-24 6:16 ` Manivannan Sadhasivam
0 siblings, 0 replies; 10+ messages in thread
From: Manivannan Sadhasivam @ 2023-07-24 6:16 UTC (permalink / raw)
To: Mrinmay Sarkar
Cc: agross, andersson, krzysztof.kozlowski+dt, conor+dt,
konrad.dybcio, quic_shazhuss, quic_nitegupt, quic_ramkri,
quic_nayiluri, dmitry.baryshkov, Lorenzo Pieralisi,
Krzysztof Wilczyński, Rob Herring, Bjorn Helgaas,
linux-arm-msm, linux-pci, devicetree, linux-kernel
On Fri, Jul 21, 2023 at 10:54:32PM +0530, Mrinmay Sarkar wrote:
> Add sa8775p platform to the binding.
>
> Signed-off-by: Mrinmay Sarkar <quic_msarkar@quicinc.com>
Acked-by: Manivannan Sadhasivam <mani@kernel.org>
- Mani
> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
> .../devicetree/bindings/pci/qcom,pcie.yaml | 28 ++++++++++++++++++++++
> 1 file changed, 28 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml
> index 81971be4..eadba38 100644
> --- a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml
> +++ b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml
> @@ -29,6 +29,7 @@ properties:
> - qcom,pcie-msm8996
> - qcom,pcie-qcs404
> - qcom,pcie-sa8540p
> + - qcom,pcie-sa8775p
> - qcom,pcie-sc7280
> - qcom,pcie-sc8180x
> - qcom,pcie-sc8280xp
> @@ -211,6 +212,7 @@ allOf:
> compatible:
> contains:
> enum:
> + - qcom,pcie-sa8775p
> - qcom,pcie-sc7280
> - qcom,pcie-sc8180x
> - qcom,pcie-sc8280xp
> @@ -748,7 +750,32 @@ allOf:
> compatible:
> contains:
> enum:
> + - qcom,pcie-sa8775p
> + then:
> + properties:
> + clocks:
> + minItems: 5
> + maxItems: 5
> + clock-names:
> + items:
> + - const: aux # Auxiliary clock
> + - const: cfg # Configuration clock
> + - const: bus_master # Master AXI clock
> + - const: bus_slave # Slave AXI clock
> + - const: slave_q2a # Slave Q2A clock
> + resets:
> + maxItems: 1
> + reset-names:
> + items:
> + - const: pci # PCIe core reset
> +
> + - if:
> + properties:
> + compatible:
> + contains:
> + enum:
> - qcom,pcie-sa8540p
> + - qcom,pcie-sa8775p
> - qcom,pcie-sc8280xp
> then:
> required:
> @@ -790,6 +817,7 @@ allOf:
> contains:
> enum:
> - qcom,pcie-msm8996
> + - qcom,pcie-sa8775p
> - qcom,pcie-sc7280
> - qcom,pcie-sc8180x
> - qcom,pcie-sdm845
> --
> 2.7.4
>
--
மணிவண்ணன் சதாசிவம்
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH v3 2/4] PCI: qcom: Add support for sa8775p SoC
2023-07-21 17:24 [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Mrinmay Sarkar
2023-07-21 17:24 ` [PATCH v3 1/4] dt-bindings: PCI: qcom: Add sa8775p compatible Mrinmay Sarkar
@ 2023-07-21 17:24 ` Mrinmay Sarkar
2023-07-22 4:27 ` Bjorn Andersson
2023-07-24 6:17 ` Manivannan Sadhasivam
2023-07-21 17:24 ` [PATCH v3 3/4] arm64: dts: qcom: sa8775p: Add pcie0 and pcie1 nodes Mrinmay Sarkar
` (3 subsequent siblings)
5 siblings, 2 replies; 10+ messages in thread
From: Mrinmay Sarkar @ 2023-07-21 17:24 UTC (permalink / raw)
To: agross, andersson, krzysztof.kozlowski+dt, conor+dt,
konrad.dybcio, mani
Cc: quic_shazhuss, quic_nitegupt, quic_ramkri, quic_nayiluri,
dmitry.baryshkov, Mrinmay Sarkar, Lorenzo Pieralisi,
Krzysztof Wilczyński, Rob Herring, Bjorn Helgaas,
linux-arm-msm, linux-pci, devicetree, linux-kernel
Add support for sa8775p SoC that uses controller version 5.90
reusing the 1.9.0 config.
Signed-off-by: Mrinmay Sarkar <quic_msarkar@quicinc.com>
---
drivers/pci/controller/dwc/pcie-qcom.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/pci/controller/dwc/pcie-qcom.c b/drivers/pci/controller/dwc/pcie-qcom.c
index cee4e40..e2f2940 100644
--- a/drivers/pci/controller/dwc/pcie-qcom.c
+++ b/drivers/pci/controller/dwc/pcie-qcom.c
@@ -1613,6 +1613,7 @@ static const struct of_device_id qcom_pcie_match[] = {
{ .compatible = "qcom,pcie-msm8996", .data = &cfg_2_3_2 },
{ .compatible = "qcom,pcie-qcs404", .data = &cfg_2_4_0 },
{ .compatible = "qcom,pcie-sa8540p", .data = &cfg_1_9_0 },
+ { .compatible = "qcom,pcie-sa8775p", .data = &cfg_1_9_0},
{ .compatible = "qcom,pcie-sc7280", .data = &cfg_1_9_0 },
{ .compatible = "qcom,pcie-sc8180x", .data = &cfg_1_9_0 },
{ .compatible = "qcom,pcie-sc8280xp", .data = &cfg_1_9_0 },
--
2.7.4
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH v3 2/4] PCI: qcom: Add support for sa8775p SoC
2023-07-21 17:24 ` [PATCH v3 2/4] PCI: qcom: Add support for sa8775p SoC Mrinmay Sarkar
@ 2023-07-22 4:27 ` Bjorn Andersson
2023-07-24 6:17 ` Manivannan Sadhasivam
1 sibling, 0 replies; 10+ messages in thread
From: Bjorn Andersson @ 2023-07-22 4:27 UTC (permalink / raw)
To: Mrinmay Sarkar
Cc: agross, krzysztof.kozlowski+dt, conor+dt, konrad.dybcio, mani,
quic_shazhuss, quic_nitegupt, quic_ramkri, quic_nayiluri,
dmitry.baryshkov, Lorenzo Pieralisi, Krzysztof Wilczyński,
Rob Herring, Bjorn Helgaas, linux-arm-msm, linux-pci, devicetree,
linux-kernel
On Fri, Jul 21, 2023 at 10:54:33PM +0530, Mrinmay Sarkar wrote:
> Add support for sa8775p SoC that uses controller version 5.90
> reusing the 1.9.0 config.
>
> Signed-off-by: Mrinmay Sarkar <quic_msarkar@quicinc.com>
Reviewed-by: Bjorn Andersson <andersson@kernel.org>
Regards,
Bjorn
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v3 2/4] PCI: qcom: Add support for sa8775p SoC
2023-07-21 17:24 ` [PATCH v3 2/4] PCI: qcom: Add support for sa8775p SoC Mrinmay Sarkar
2023-07-22 4:27 ` Bjorn Andersson
@ 2023-07-24 6:17 ` Manivannan Sadhasivam
1 sibling, 0 replies; 10+ messages in thread
From: Manivannan Sadhasivam @ 2023-07-24 6:17 UTC (permalink / raw)
To: Mrinmay Sarkar
Cc: agross, andersson, krzysztof.kozlowski+dt, conor+dt,
konrad.dybcio, quic_shazhuss, quic_nitegupt, quic_ramkri,
quic_nayiluri, dmitry.baryshkov, Lorenzo Pieralisi,
Krzysztof Wilczyński, Rob Herring, Bjorn Helgaas,
linux-arm-msm, linux-pci, devicetree, linux-kernel
On Fri, Jul 21, 2023 at 10:54:33PM +0530, Mrinmay Sarkar wrote:
> Add support for sa8775p SoC that uses controller version 5.90
> reusing the 1.9.0 config.
>
> Signed-off-by: Mrinmay Sarkar <quic_msarkar@quicinc.com>
Reviewed-by: Manivannan Sadhasivam <mani@kernel.org>
- Mani
> ---
> drivers/pci/controller/dwc/pcie-qcom.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/pci/controller/dwc/pcie-qcom.c b/drivers/pci/controller/dwc/pcie-qcom.c
> index cee4e40..e2f2940 100644
> --- a/drivers/pci/controller/dwc/pcie-qcom.c
> +++ b/drivers/pci/controller/dwc/pcie-qcom.c
> @@ -1613,6 +1613,7 @@ static const struct of_device_id qcom_pcie_match[] = {
> { .compatible = "qcom,pcie-msm8996", .data = &cfg_2_3_2 },
> { .compatible = "qcom,pcie-qcs404", .data = &cfg_2_4_0 },
> { .compatible = "qcom,pcie-sa8540p", .data = &cfg_1_9_0 },
> + { .compatible = "qcom,pcie-sa8775p", .data = &cfg_1_9_0},
> { .compatible = "qcom,pcie-sc7280", .data = &cfg_1_9_0 },
> { .compatible = "qcom,pcie-sc8180x", .data = &cfg_1_9_0 },
> { .compatible = "qcom,pcie-sc8280xp", .data = &cfg_1_9_0 },
> --
> 2.7.4
>
--
மணிவண்ணன் சதாசிவம்
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH v3 3/4] arm64: dts: qcom: sa8775p: Add pcie0 and pcie1 nodes
2023-07-21 17:24 [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Mrinmay Sarkar
2023-07-21 17:24 ` [PATCH v3 1/4] dt-bindings: PCI: qcom: Add sa8775p compatible Mrinmay Sarkar
2023-07-21 17:24 ` [PATCH v3 2/4] PCI: qcom: Add support for sa8775p SoC Mrinmay Sarkar
@ 2023-07-21 17:24 ` Mrinmay Sarkar
2023-07-21 17:24 ` [PATCH v3 4/4] arm64: dts: qcom: sa8775p-ride: enable pcie nodes Mrinmay Sarkar
` (2 subsequent siblings)
5 siblings, 0 replies; 10+ messages in thread
From: Mrinmay Sarkar @ 2023-07-21 17:24 UTC (permalink / raw)
To: agross, andersson, krzysztof.kozlowski+dt, conor+dt,
konrad.dybcio, mani
Cc: quic_shazhuss, quic_nitegupt, quic_ramkri, quic_nayiluri,
dmitry.baryshkov, Mrinmay Sarkar, Lorenzo Pieralisi,
Krzysztof Wilczyński, Rob Herring, Bjorn Helgaas,
linux-arm-msm, linux-pci, devicetree, linux-kernel
Add pcie dtsi nodes for two controllers found on sa8775p platform.
Signed-off-by: Mrinmay Sarkar <quic_msarkar@quicinc.com>
---
arch/arm64/boot/dts/qcom/sa8775p.dtsi | 204 +++++++++++++++++++++++++++++++++-
1 file changed, 202 insertions(+), 2 deletions(-)
diff --git a/arch/arm64/boot/dts/qcom/sa8775p.dtsi b/arch/arm64/boot/dts/qcom/sa8775p.dtsi
index 59eedfc..7b55cb7 100644
--- a/arch/arm64/boot/dts/qcom/sa8775p.dtsi
+++ b/arch/arm64/boot/dts/qcom/sa8775p.dtsi
@@ -481,8 +481,8 @@
<0>,
<0>,
<0>,
- <0>,
- <0>,
+ <&pcie0_phy>,
+ <&pcie1_phy>,
<0>,
<0>,
<0>;
@@ -2357,4 +2357,204 @@
<GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>,
<GIC_PPI 12 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>;
};
+
+ pcie0: pci@1c00000{
+ compatible = "qcom,pcie-sa8775p";
+ reg = <0x0 0x01c00000 0x0 0x3000>,
+ <0x0 0x40000000 0x0 0xf20>,
+ <0x0 0x40000f20 0x0 0xa8>,
+ <0x0 0x40001000 0x0 0x4000>,
+ <0x0 0x40100000 0x0 0x100000>,
+ <0x0 0x01c03000 0x0 0x1000>;
+ reg-names = "parf", "dbi", "elbi", "atu", "config", "mhi";
+ device_type = "pci";
+
+ #address-cells = <3>;
+ #size-cells = <2>;
+ ranges = <0x01000000 0x0 0x00000000 0x0 0x40200000 0x0 0x100000>,
+ <0x02000000 0x0 0x40300000 0x0 0x40300000 0x0 0x1fd00000>;
+ bus-range = <0x00 0xff>;
+
+ dma-coherent;
+
+ linux,pci-domain = <0>;
+ num-lanes = <2>;
+
+ interrupts = <GIC_SPI 307 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 308 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 309 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 312 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 313 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 314 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 374 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 375 IRQ_TYPE_LEVEL_HIGH>;
+ interrupt-names = "msi0", "msi1", "msi2", "msi3",
+ "msi4", "msi5", "msi6", "msi7";
+ #interrupt-cells = <1>;
+ interrupt-map-mask = <0 0 0 0x7>;
+ interrupt-map = <0 0 0 1 &intc GIC_SPI 434 IRQ_TYPE_LEVEL_HIGH>,
+ <0 0 0 2 &intc GIC_SPI 435 IRQ_TYPE_LEVEL_HIGH>,
+ <0 0 0 3 &intc GIC_SPI 438 IRQ_TYPE_LEVEL_HIGH>,
+ <0 0 0 4 &intc GIC_SPI 439 IRQ_TYPE_LEVEL_HIGH>;
+
+ clocks = <&gcc GCC_PCIE_0_AUX_CLK>,
+ <&gcc GCC_PCIE_0_CFG_AHB_CLK>,
+ <&gcc GCC_PCIE_0_MSTR_AXI_CLK>,
+ <&gcc GCC_PCIE_0_SLV_AXI_CLK>,
+ <&gcc GCC_PCIE_0_SLV_Q2A_AXI_CLK>;
+
+ clock-names = "aux",
+ "cfg",
+ "bus_master",
+ "bus_slave",
+ "slave_q2a";
+
+ assigned-clocks = <&gcc GCC_PCIE_0_AUX_CLK>;
+ assigned-clock-rates = <19200000>;
+
+ interconnects = <&pcie_anoc MASTER_PCIE_0 0 &mc_virt SLAVE_EBI1 0>,
+ <&gem_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_PCIE_0 0>;
+ interconnect-names = "pcie-mem", "cpu-pcie";
+
+ iommu-map = <0x0 &pcie_smmu 0x0000 0x1>,
+ <0x100 &pcie_smmu 0x0001 0x1>;
+
+ resets = <&gcc GCC_PCIE_0_BCR>;
+ reset-names = "pci";
+ power-domains = <&gcc PCIE_0_GDSC>;
+
+ phys = <&pcie0_phy>;
+ phy-names = "pciephy";
+
+ status = "disabled";
+ };
+
+ pcie0_phy: phy@1c04000 {
+ compatible = "qcom,sa8775p-qmp-gen4x2-pcie-phy";
+ reg = <0x0 0x1c04000 0x0 0x2000>;
+
+ clocks = <&gcc GCC_PCIE_0_AUX_CLK>,
+ <&gcc GCC_PCIE_0_CFG_AHB_CLK>,
+ <&gcc GCC_PCIE_CLKREF_EN>,
+ <&gcc GCC_PCIE_0_PHY_RCHNG_CLK>,
+ <&gcc GCC_PCIE_0_PIPE_CLK>,
+ <&gcc GCC_PCIE_0_PIPEDIV2_CLK>,
+ <&gcc GCC_PCIE_0_PHY_AUX_CLK>;
+
+ clock-names = "aux", "cfg_ahb", "ref", "rchng", "pipe",
+ "pipediv2", "phy_aux";
+
+ assigned-clocks = <&gcc GCC_PCIE_0_PHY_RCHNG_CLK>;
+ assigned-clock-rates = <100000000>;
+
+ resets = <&gcc GCC_PCIE_0_PHY_BCR>;
+ reset-names = "phy";
+
+ #clock-cells = <0>;
+ clock-output-names = "pcie_0_pipe_clk";
+
+ #phy-cells = <0>;
+
+ status = "disabled";
+ };
+
+ pcie1: pci@1c10000{
+ compatible = "qcom,pcie-sa8775p";
+ reg = <0x0 0x01c10000 0x0 0x3000>,
+ <0x0 0x60000000 0x0 0xf20>,
+ <0x0 0x60000f20 0x0 0xa8>,
+ <0x0 0x60001000 0x0 0x4000>,
+ <0x0 0x60100000 0x0 0x100000>,
+ <0x0 0x01c13000 0x0 0x1000>;
+ reg-names = "parf", "dbi", "elbi", "atu", "config", "mhi";
+ device_type = "pci";
+
+ #address-cells = <3>;
+ #size-cells = <2>;
+ ranges = <0x01000000 0x0 0x00000000 0x0 0x60200000 0x0 0x100000>,
+ <0x02000000 0x0 0x60300000 0x0 0x60300000 0x0 0x1fd00000>;
+ bus-range = <0x00 0xff>;
+
+ dma-coherent;
+
+ linux,pci-domain = <1>;
+ num-lanes = <4>;
+
+ interrupts = <GIC_SPI 519 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 140 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 141 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 142 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 143 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 144 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 145 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 146 IRQ_TYPE_LEVEL_HIGH>;
+ interrupt-names = "msi0", "msi1", "msi2", "msi3",
+ "msi4", "msi5", "msi6", "msi7";
+ #interrupt-cells = <1>;
+ interrupt-map-mask = <0 0 0 0x7>;
+ interrupt-map = <0 0 0 1 &intc GIC_SPI 148 IRQ_TYPE_LEVEL_HIGH>,
+ <0 0 0 2 &intc GIC_SPI 149 IRQ_TYPE_LEVEL_HIGH>,
+ <0 0 0 3 &intc GIC_SPI 150 IRQ_TYPE_LEVEL_HIGH>,
+ <0 0 0 4 &intc GIC_SPI 151 IRQ_TYPE_LEVEL_HIGH>;
+
+ clocks = <&gcc GCC_PCIE_1_AUX_CLK>,
+ <&gcc GCC_PCIE_1_CFG_AHB_CLK>,
+ <&gcc GCC_PCIE_1_MSTR_AXI_CLK>,
+ <&gcc GCC_PCIE_1_SLV_AXI_CLK>,
+ <&gcc GCC_PCIE_1_SLV_Q2A_AXI_CLK>;
+
+ clock-names = "aux",
+ "cfg",
+ "bus_master",
+ "bus_slave",
+ "slave_q2a";
+
+ assigned-clocks = <&gcc GCC_PCIE_1_AUX_CLK>;
+ assigned-clock-rates = <19200000>;
+
+ interconnects = <&pcie_anoc MASTER_PCIE_1 0 &mc_virt SLAVE_EBI1 0>,
+ <&gem_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_PCIE_1 0>;
+ interconnect-names = "pcie-mem", "cpu-pcie";
+
+ iommu-map = <0x0 &pcie_smmu 0x0080 0x1>,
+ <0x100 &pcie_smmu 0x0081 0x1>;
+
+ resets = <&gcc GCC_PCIE_1_BCR>;
+ reset-names = "pci";
+ power-domains = <&gcc PCIE_1_GDSC>;
+
+ phys = <&pcie1_phy>;
+ phy-names = "pciephy";
+
+ status = "disabled";
+ };
+
+ pcie1_phy: phy@1c14000 {
+ compatible = "qcom,sa8775p-qmp-gen4x4-pcie-phy";
+ reg = <0x0 0x1c14000 0x0 0x4000>;
+
+ clocks = <&gcc GCC_PCIE_1_AUX_CLK>,
+ <&gcc GCC_PCIE_1_CFG_AHB_CLK>,
+ <&gcc GCC_PCIE_CLKREF_EN>,
+ <&gcc GCC_PCIE_1_PHY_RCHNG_CLK>,
+ <&gcc GCC_PCIE_1_PIPE_CLK>,
+ <&gcc GCC_PCIE_1_PIPEDIV2_CLK>,
+ <&gcc GCC_PCIE_1_PHY_AUX_CLK>;
+
+ clock-names = "aux", "cfg_ahb", "ref", "rchng", "pipe",
+ "pipediv2", "phy_aux";
+
+ assigned-clocks = <&gcc GCC_PCIE_1_PHY_RCHNG_CLK>;
+ assigned-clock-rates = <100000000>;
+
+ resets = <&gcc GCC_PCIE_1_PHY_BCR>;
+ reset-names = "phy";
+
+ #clock-cells = <0>;
+ clock-output-names = "pcie_1_pipe_clk";
+
+ #phy-cells = <0>;
+
+ status = "disabled";
+ };
};
--
2.7.4
^ permalink raw reply related [flat|nested] 10+ messages in thread* [PATCH v3 4/4] arm64: dts: qcom: sa8775p-ride: enable pcie nodes
2023-07-21 17:24 [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Mrinmay Sarkar
` (2 preceding siblings ...)
2023-07-21 17:24 ` [PATCH v3 3/4] arm64: dts: qcom: sa8775p: Add pcie0 and pcie1 nodes Mrinmay Sarkar
@ 2023-07-21 17:24 ` Mrinmay Sarkar
2023-07-22 5:17 ` (subset) [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Bjorn Andersson
2023-08-25 18:51 ` Krzysztof Wilczyński
5 siblings, 0 replies; 10+ messages in thread
From: Mrinmay Sarkar @ 2023-07-21 17:24 UTC (permalink / raw)
To: agross, andersson, krzysztof.kozlowski+dt, conor+dt,
konrad.dybcio, mani
Cc: quic_shazhuss, quic_nitegupt, quic_ramkri, quic_nayiluri,
dmitry.baryshkov, Mrinmay Sarkar, Lorenzo Pieralisi,
Krzysztof Wilczyński, Rob Herring, Bjorn Helgaas,
linux-arm-msm, linux-pci, devicetree, linux-kernel
Enable pcie0, pcie1 nodes and their respective phy's.
Signed-off-by: Mrinmay Sarkar <quic_msarkar@quicinc.com>
---
arch/arm64/boot/dts/qcom/sa8775p-ride.dts | 80 +++++++++++++++++++++++++++++++
1 file changed, 80 insertions(+)
diff --git a/arch/arm64/boot/dts/qcom/sa8775p-ride.dts b/arch/arm64/boot/dts/qcom/sa8775p-ride.dts
index 8c2890b..ed76680 100644
--- a/arch/arm64/boot/dts/qcom/sa8775p-ride.dts
+++ b/arch/arm64/boot/dts/qcom/sa8775p-ride.dts
@@ -552,6 +552,86 @@
bias-pull-down;
};
};
+
+ pcie0_default_state: pcie0-default-state {
+ perst-pins {
+ pins = "gpio2";
+ function = "gpio";
+ drive-strength = <2>;
+ bias-pull-down;
+ };
+
+ clkreq-pins {
+ pins = "gpio1";
+ function = "pcie0_clkreq";
+ drive-strength = <2>;
+ bias-pull-up;
+ };
+
+ wake-pins {
+ pins = "gpio0";
+ function = "gpio";
+ drive-strength = <2>;
+ bias-pull-up;
+ };
+ };
+
+ pcie1_default_state: pcie1-default-state {
+ perst-pins {
+ pins = "gpio4";
+ function = "gpio";
+ drive-strength = <2>;
+ bias-pull-down;
+ };
+
+ clkreq-pins {
+ pins = "gpio3";
+ function = "pcie1_clkreq";
+ drive-strength = <2>;
+ bias-pull-up;
+ };
+
+ wake-pins {
+ pins = "gpio5";
+ function = "gpio";
+ drive-strength = <2>;
+ bias-pull-up;
+ };
+ };
+};
+
+&pcie0 {
+ perst-gpios = <&tlmm 2 GPIO_ACTIVE_LOW>;
+ wake-gpios = <&tlmm 0 GPIO_ACTIVE_HIGH>;
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&pcie0_default_state>;
+
+ status = "okay";
+};
+
+&pcie1 {
+ perst-gpios = <&tlmm 4 GPIO_ACTIVE_LOW>;
+ wake-gpios = <&tlmm 5 GPIO_ACTIVE_HIGH>;
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&pcie1_default_state>;
+
+ status = "okay";
+};
+
+&pcie0_phy {
+ vdda-phy-supply = <&vreg_l5a>;
+ vdda-pll-supply = <&vreg_l1c>;
+
+ status = "okay";
+};
+
+&pcie1_phy {
+ vdda-phy-supply = <&vreg_l5a>;
+ vdda-pll-supply = <&vreg_l1c>;
+
+ status = "okay";
};
&uart10 {
--
2.7.4
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: (subset) [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe
2023-07-21 17:24 [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Mrinmay Sarkar
` (3 preceding siblings ...)
2023-07-21 17:24 ` [PATCH v3 4/4] arm64: dts: qcom: sa8775p-ride: enable pcie nodes Mrinmay Sarkar
@ 2023-07-22 5:17 ` Bjorn Andersson
2023-08-25 18:51 ` Krzysztof Wilczyński
5 siblings, 0 replies; 10+ messages in thread
From: Bjorn Andersson @ 2023-07-22 5:17 UTC (permalink / raw)
To: agross, krzysztof.kozlowski+dt, conor+dt, konrad.dybcio, mani,
Mrinmay Sarkar
Cc: quic_shazhuss, quic_nitegupt, quic_ramkri, quic_nayiluri,
dmitry.baryshkov, Lorenzo Pieralisi, Krzysztof Wilczyński,
Rob Herring, Bjorn Helgaas, linux-arm-msm, linux-pci, devicetree,
linux-kernel
On Fri, 21 Jul 2023 22:54:31 +0530, Mrinmay Sarkar wrote:
> Update the relavent DT bindings for PCIe, add new config to the phy
> driver add pcie and phy nodes to the .dtsi file and enable then in
> board .dts file for the sa8775p-ride platform.
>
> v2 -> v3:
> - to align with dt-bindings rectified pcie default state
> - dropped PCIe PHY dt-bindings and PHY driver in this series as its
> already applied [1]
> - To verify DTS against bindings for this series we required [2]
>
> [...]
Applied, thanks!
[3/4] arm64: dts: qcom: sa8775p: Add pcie0 and pcie1 nodes
commit: 489f14be0e0a19225ef8575e4a04b0f9ee77ab3e
[4/4] arm64: dts: qcom: sa8775p-ride: enable pcie nodes
commit: bf3ee3db23ed2e72ee61141ade9a3964b509a8d4
Best regards,
--
Bjorn Andersson <andersson@kernel.org>
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe
2023-07-21 17:24 [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Mrinmay Sarkar
` (4 preceding siblings ...)
2023-07-22 5:17 ` (subset) [PATCH v3 0/4] arm64: qcom: sa8775p: add support for PCIe Bjorn Andersson
@ 2023-08-25 18:51 ` Krzysztof Wilczyński
5 siblings, 0 replies; 10+ messages in thread
From: Krzysztof Wilczyński @ 2023-08-25 18:51 UTC (permalink / raw)
To: Mrinmay Sarkar
Cc: agross, andersson, krzysztof.kozlowski+dt, conor+dt,
konrad.dybcio, mani, quic_shazhuss, quic_nitegupt, quic_ramkri,
quic_nayiluri, dmitry.baryshkov, Lorenzo Pieralisi, Rob Herring,
Bjorn Helgaas, linux-arm-msm, linux-pci, devicetree, linux-kernel
Hello,
> Update the relavent DT bindings for PCIe, add new config to the phy
> driver add pcie and phy nodes to the .dtsi file and enable then in
> board .dts file for the sa8775p-ride platform.
Applied to controller/qcom, thank you!
[1/4] dt-bindings: PCI: qcom: Add sa8775p compatible
https://git.kernel.org/pci/pci/c/9169e03946b9
[2/4] PCI: qcom: Add support for sa8775p SoC
https://git.kernel.org/pci/pci/c/d60379d65d2b
Krzysztof
^ permalink raw reply [flat|nested] 10+ messages in thread