arm64: dts: qcom: x1e80100: PCIe fixes and CRD modem support
v2 cover arm64: dts: qcom: x1e80100: PCIe fixes and CRD modem support
This series fixes some issues with the current x1e80100 PCIe support, adds the PCIe5 nodes and enables the modem on the CRD.
The fixes should go into 6.11, but the modem support depends on them so I decided to send everything in one series.
As Konrad noted some of these issues have been reproduced in the other x1e80100 dts. I'll send a separate series addressing that.
Johan
Changes in v2
- add missing minimum OPPs
- move 'pinctrl-name' under 'pinctrl-0'
Johan Hovold (8):
arm64: dts: qcom: x1e80100-crd: fix PCIe4 PHY supply
arm64: dts: qcom: x1e80100: fix PCIe domain numbers
arm64: dts: qcom: x1e80100: add missing PCIe minimum OPP
arm64: dts: qcom: x1e80100-crd: fix up PCIe6a pinctrl node
arm64: dts: qcom: x1e80100-crd: disable PCIe6a perst pull down
arm64: dts: qcom: x1e80100-crd: fix missing PCIe4 gpios
arm64: dts: qcom: x1e80100: add PCIe5 nodes
arm64: dts: qcom: x1e80100-crd: enable SDX65 modem
arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 110 +++++++++++++++++-- arch/arm64/boot/dts/qcom/x1e80100.dtsi | 128 +++++++++++++++++++++- 2 files changed, 227 insertions(+), 11 deletions(-)
Signature · 1 line
2.44.2
PATCH v2 1/8 arm64: dts: qcom: x1e80100-crd: fix PCIe4 PHY supply
The PCIe4 PHY is powered by vreg_l3i (not vreg_l3j).
--- arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/x1e80100-crd.dts +1 -1
@@ -788,7 +788,7 @@ &pcie4 { }; &pcie4_phy { - vdda-phy-supply = <&vreg_l3j_0p8>; + vdda-phy-supply = <&vreg_l3i_0p8>; vdda-pll-supply = <&vreg_l3e_1p2>; status = "okay";
Signature · 1 line
2.44.2
Re: [PATCH v2 1/8] arm64: dts: qcom: x1e80100-crd: fix PCIe4 PHY supply
Quoted 5 lines · Johan Hovold
The PCIe4 PHY is powered by
vreg_l3i(notvreg_l3j).Fixes d7e03cce0400 ("arm64: dts: qcom: x1e80100-crd: Enable more support")Cc [email protected] # 6.9Signed-off-by Johan Hovold <[email protected]>
Quoted 20 lines
--- arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)arch/arm64/boot/dts/qcom/x1e80100-crd.dts +1
-1@@ -788,7 +788,7 @@ &pcie4 { }; &pcie4_phy { - vdda-phy-supply = <&vreg_l3j_0p8>; + vdda-phy-supply = <&vreg_l3i_0p8>; vdda-pll-supply = <&vreg_l3e_1p2>; status = "okay";Signature · 1 line
2.44.2
PATCH v2 2/8 arm64: dts: qcom: x1e80100: fix PCIe domain numbers
In reply to Johan HovoldThe current PCIe domain numbers are off by one and do not match the numbers that the UEFI firmware (and Windows) uses.
--- arch/arm64/boot/dts/qcom/x1e80100.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/x1e80100.dtsi +2 -2
@@ -2916,7 +2916,7 @@ pcie6a: pci@1bf8000 { dma-coherent; - linux,pci-domain = <7>; + linux,pci-domain = <6>; num-lanes = <2>; interrupts = <GIC_SPI 773 IRQ_TYPE_LEVEL_HIGH>,
@@ -3037,7 +3037,7 @@ pcie4: pci@1c08000 { dma-coherent; - linux,pci-domain = <5>; + linux,pci-domain = <4>; num-lanes = <2>; interrupts = <GIC_SPI 141 IRQ_TYPE_LEVEL_HIGH>,
Signature · 1 line
2.44.2
PATCH v2 3/8 arm64: dts: qcom: x1e80100: add missing PCIe minimum OPP
In reply to Johan HovoldAdd the missing PCIe CX performance level votes to avoid relying on other drivers (e.g. USB) to maintain the nominal performance level required for Gen3 speeds.
--- arch/arm64/boot/dts/qcom/x1e80100.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/qcom/x1e80100.dtsi +2 -0
@@ -2974,6 +2974,7 @@ &mc_virt SLAVE_EBI1 QCOM_ICC_TAG_ALWAYS>, "link_down"; power-domains = <&gcc GCC_PCIE_6A_GDSC>; + required-opps = <&rpmhpd_opp_nom>; phys = <&pcie6a_phy>; phy-names = "pciephy";
@@ -3095,6 +3096,7 @@ &mc_virt SLAVE_EBI1 QCOM_ICC_TAG_ALWAYS>, "link_down"; power-domains = <&gcc GCC_PCIE_4_GDSC>; + required-opps = <&rpmhpd_opp_nom>; phys = <&pcie4_phy>; phy-names = "pciephy";
Signature · 1 line
2.44.2
Re: [PATCH v2 3/8] arm64: dts: qcom: x1e80100: add missing PCIe minimum OPP
Quoted 8 lines · Johan Hovold
Add the missing PCIe CX performance level votes to avoid relying on other drivers (e.g. USB) to maintain the nominal performance level required for Gen3 speeds.
Fixes 5eb83fc10289 ("arm64: dts: qcom: x1e80100: Add PCIe nodes")Cc [email protected] # 6.9Signed-off-by Johan Hovold <[email protected]>---
Konrad
PATCH v2 4/8 arm64: dts: qcom: x1e80100-crd: fix up PCIe6a pinctrl node
In reply to Johan HovoldThe PCIe6a pinctrl node appears to have been copied from the sc8280xp CRD dts, which has the NVMe on pcie2a and uses some funny indentation.
Fix up the node name to match the x1e80100 use and label and use only tabs for indentation.
--- arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
arch/arm64/boot/dts/qcom/x1e80100-crd.dts +6 -6
@@ -975,7 +975,7 @@ nvme_reg_en: nvme-reg-en-state { bias-disable; }; - pcie6a_default: pcie2a-default-state { + pcie6a_default: pcie6a-default-state { clkreq-n-pins { pins = "gpio153"; function = "pcie6a_clk";
@@ -991,11 +991,11 @@ perst-n-pins { }; wake-n-pins { - pins = "gpio154"; - function = "gpio"; - drive-strength = <2>; - bias-pull-up; - }; + pins = "gpio154"; + function = "gpio"; + drive-strength = <2>; + bias-pull-up; + }; }; tpad_default: tpad-default-state {
Signature · 1 line
2.44.2
PATCH v2 5/8 arm64: dts: qcom: x1e80100-crd: disable PCIe6a perst pull down
In reply to Johan HovoldDisable the PCIe6a perst pull-down resistor to save some power.
--- arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/x1e80100-crd.dts +1 -1
@@ -987,7 +987,7 @@ perst-n-pins { pins = "gpio152"; function = "gpio"; drive-strength = <2>; - bias-pull-down; + bias-disable; }; wake-n-pins {
Signature · 1 line
2.44.2
PATCH v2 6/8 arm64: dts: qcom: x1e80100-crd: fix missing PCIe4 gpios
In reply to Johan HovoldAdd the missing PCIe4 perst, wake and clkreq GPIOs and pin config.
--- arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 29 +++++++++++++++++++++++ 1 file changed, 29 insertions(+)
arch/arm64/boot/dts/qcom/x1e80100-crd.dts +29 -0
@@ -784,6 +784,12 @@ &mdss_dp3_phy { }; &pcie4 { + perst-gpios = <&tlmm 146 GPIO_ACTIVE_LOW>; + wake-gpios = <&tlmm 148 GPIO_ACTIVE_LOW>; + + pinctrl-0 = <&pcie4_default>; + pinctrl-names = "default"; + status = "okay"; };
@@ -975,6 +981,29 @@ nvme_reg_en: nvme-reg-en-state { bias-disable; }; + pcie4_default: pcie4-default-state { + clkreq-n-pins { + pins = "gpio147"; + function = "pcie4_clk"; + drive-strength = <2>; + bias-pull-up; + }; + + perst-n-pins { + pins = "gpio146"; + function = "gpio"; + drive-strength = <2>; + bias-disable; + }; + + wake-n-pins { + pins = "gpio148"; + function = "gpio"; + drive-strength = <2>; + bias-pull-up; + }; + }; + pcie6a_default: pcie6a-default-state { clkreq-n-pins { pins = "gpio153";
Signature · 1 line
2.44.2
PATCH v2 7/8 arm64: dts: qcom: x1e80100: add PCIe5 nodes
In reply to Johan HovoldDescribe the fifth PCIe controller and its PHY.
Note that using the GIC ITS with PCIe5 does not work currently so the ITS mapping is left unspecified for now.
--- arch/arm64/boot/dts/qcom/x1e80100.dtsi | 122 ++++++++++++++++++++++++- 1 file changed, 121 insertions(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/x1e80100.dtsi +121 -1
@@ -760,7 +760,7 @@ gcc: clock-controller@100000 { <&sleep_clk>, <0>, <&pcie4_phy>, - <0>, + <&pcie5_phy>, <&pcie6a_phy>, <0>, <&usb_1_ss0_qmpphy QMP_USB43DP_USB3_PIPE_CLK>,
@@ -3015,6 +3015,126 @@ pcie6a_phy: phy@1bfc000 { status = "disabled"; }; + pcie5: pci@1c00000 { + device_type = "pci"; + compatible = "qcom,pcie-x1e80100"; + reg = <0 0x01c00000 0 0x3000>, + <0 0x7e000000 0 0xf1d>, + <0 0x7e000f40 0 0xa8>, + <0 0x7e001000 0 0x1000>, + <0 0x7e100000 0 0x100000>, + <0 0x01c03000 0 0x1000>; + reg-names = "parf", + "dbi", + "elbi", + "atu", + "config", + "mhi"; + #address-cells = <3>; + #size-cells = <2>; + ranges = <0x01000000 0x0 0x00000000 0x0 0x7e200000 0x0 0x100000>, + <0x02000000 0x0 0x7e300000 0x0 0x7e300000 0x0 0x1d00000>; + bus-range = <0x00 0xff>; + + dma-coherent; + + linux,pci-domain = <5>; + num-lanes = <2>; + + interrupts = <GIC_SPI 94 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 95 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 86 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 82 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 77 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 78 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 0 0 0 70 IRQ_TYPE_LEVEL_HIGH>, + <0 0 0 2 &intc 0 0 0 71 IRQ_TYPE_LEVEL_HIGH>, + <0 0 0 3 &intc 0 0 0 72 IRQ_TYPE_LEVEL_HIGH>, + <0 0 0 4 &intc 0 0 0 73 IRQ_TYPE_LEVEL_HIGH>; + + clocks = <&gcc GCC_PCIE_5_AUX_CLK>, + <&gcc GCC_PCIE_5_CFG_AHB_CLK>, + <&gcc GCC_PCIE_5_MSTR_AXI_CLK>, + <&gcc GCC_PCIE_5_SLV_AXI_CLK>, + <&gcc GCC_PCIE_5_SLV_Q2A_AXI_CLK>, + <&gcc GCC_CFG_NOC_PCIE_ANOC_NORTH_AHB_CLK>, + <&gcc GCC_CNOC_PCIE_NORTH_SF_AXI_CLK>; + clock-names = "aux", + "cfg", + "bus_master", + "bus_slave", + "slave_q2a", + "noc_aggr", + "cnoc_sf_axi"; + + assigned-clocks = <&gcc GCC_PCIE_5_AUX_CLK>; + assigned-clock-rates = <19200000>; + + interconnects = <&pcie_south_anoc MASTER_PCIE_5 QCOM_ICC_TAG_ALWAYS + &mc_virt SLAVE_EBI1 QCOM_ICC_TAG_ALWAYS>, + <&gem_noc MASTER_APPSS_PROC QCOM_ICC_TAG_ALWAYS + &cnoc_main SLAVE_PCIE_5 QCOM_ICC_TAG_ALWAYS>; + interconnect-names = "pcie-mem", + "cpu-pcie"; + + resets = <&gcc GCC_PCIE_5_BCR>, + <&gcc GCC_PCIE_5_LINK_DOWN_BCR>; + reset-names = "pci", + "link_down"; + + power-domains = <&gcc GCC_PCIE_5_GDSC>; + required-opps = <&rpmhpd_opp_nom>; + + phys = <&pcie5_phy>; + phy-names = "pciephy"; + + status = "disabled"; + }; + + pcie5_phy: phy@1c06000 { + compatible = "qcom,x1e80100-qmp-gen3x2-pcie-phy"; + reg = <0 0x01c06000 0 0x2000>; + + clocks = <&gcc GCC_PCIE_5_AUX_CLK>, + <&gcc GCC_PCIE_5_CFG_AHB_CLK>, + <&rpmhcc RPMH_CXO_CLK>, + <&gcc GCC_PCIE_5_PHY_RCHNG_CLK>, + <&gcc GCC_PCIE_5_PIPE_CLK>; + clock-names = "aux", + "cfg_ahb", + "ref", + "rchng", + "pipe"; + + resets = <&gcc GCC_PCIE_5_PHY_BCR>; + reset-names = "phy"; + + assigned-clocks = <&gcc GCC_PCIE_5_PHY_RCHNG_CLK>; + assigned-clock-rates = <100000000>; + + power-domains = <&gcc GCC_PCIE_5_PHY_GDSC>; + + #clock-cells = <0>; + clock-output-names = "pcie5_pipe_clk"; + + #phy-cells = <0>; + + status = "disabled"; + }; + pcie4: pci@1c08000 { device_type = "pci"; compatible = "qcom,pcie-x1e80100";
Signature · 1 line
2.44.2
PATCH v2 8/8 arm64: dts: qcom: x1e80100-crd: enable SDX65 modem
In reply to Johan HovoldEnable PCIe5 and the SDX65 modem.
Note that the modem may need to be flashed with firmware before use.
--- arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 65 +++++++++++++++++++++++ 1 file changed, 65 insertions(+)
arch/arm64/boot/dts/qcom/x1e80100-crd.dts +65 -0
@@ -301,6 +301,22 @@ vreg_nvme: regulator-nvme { pinctrl-names = "default"; pinctrl-0 = <&nvme_reg_en>; }; + + vreg_wwan: regulator-wwan { + compatible = "regulator-fixed"; + + regulator-name = "SDX_VPH_PWR"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + + gpio = <&tlmm 221 GPIO_ACTIVE_HIGH>; + enable-active-high; + + pinctrl-0 = <&wwan_sw_en>; + pinctrl-names = "default"; + + regulator-boot-on; + }; }; &apps_rsc {
@@ -800,6 +816,25 @@ &pcie4_phy { status = "okay"; }; +&pcie5 { + perst-gpios = <&tlmm 149 GPIO_ACTIVE_LOW>; + wake-gpios = <&tlmm 151 GPIO_ACTIVE_LOW>; + + vddpe-3v3-supply = <&vreg_wwan>; + + pinctrl-0 = <&pcie5_default>; + pinctrl-names = "default"; + + status = "okay"; +}; + +&pcie5_phy { + vdda-phy-supply = <&vreg_l3i_0p8>; + vdda-pll-supply = <&vreg_l3e_1p2>; + + status = "okay"; +}; + &pcie6a { perst-gpios = <&tlmm 152 GPIO_ACTIVE_LOW>; wake-gpios = <&tlmm 154 GPIO_ACTIVE_LOW>;
@@ -1004,6 +1039,29 @@ wake-n-pins { }; }; + pcie5_default: pcie5-default-state { + clkreq-n-pins { + pins = "gpio150"; + function = "pcie5_clk"; + drive-strength = <2>; + bias-pull-up; + }; + + perst-n-pins { + pins = "gpio149"; + function = "gpio"; + drive-strength = <2>; + bias-disable; + }; + + wake-n-pins { + pins = "gpio151"; + function = "gpio"; + drive-strength = <2>; + bias-pull-up; + }; + }; + pcie6a_default: pcie6a-default-state { clkreq-n-pins { pins = "gpio153";
@@ -1055,6 +1113,13 @@ wcd_default: wcd-reset-n-active-state { bias-disable; output-low; }; + + wwan_sw_en: wwan-sw-en-state { + pins = "gpio221"; + function = "gpio"; + drive-strength = <4>; + bias-disable; + }; }; &uart21 {
Signature · 1 line
2.44.2
Quoted 10 lines · Johan Hovold
This series fixes some issues with the current x1e80100 PCIe support, adds the PCIe5 nodes and enables the modem on the CRD.
The fixes should go into 6.11, but the modem support depends on them so I decided to send everything in one series.
As Konrad noted some of these issues have been reproduced in the other x1e80100 dts. I'll send a separate series addressing that.
[...]
Applied, thanks!
[1/8] arm64: dts: qcom: x1e80100-crd: fix PCIe4 PHY supply
commit: 47b543e215b87d311afe0de28ad741f342dd56b0
[2/8] arm64: dts: qcom: x1e80100: fix PCIe domain numbers
commit: 3782328d84602bcccad1b6db7d913facd754a303
[3/8] arm64: dts: qcom: x1e80100: add missing PCIe minimum OPP
commit: 49162e60b8413deecfe13d220b20bd67d67c7adb
[4/8] arm64: dts: qcom: x1e80100-crd: fix up PCIe6a pinctrl node
commit: 9aa27050f3d9c6f413c49b5011fae70c475084f6
[5/8] arm64: dts: qcom: x1e80100-crd: disable PCIe6a perst pull down
commit: 5d40cfc17eab68d5f2272e74e92cc814a08c08fe
[6/8] arm64: dts: qcom: x1e80100-crd: fix missing PCIe4 gpios
commit: ba9db8faa26205cfc12f35b832735d11f960fcc2
[7/8] arm64: dts: qcom: x1e80100: add PCIe5 nodes
commit: ce59448ce722ce81f672dd9ffc9d17b98cc05896
[8/8] arm64: dts: qcom: x1e80100-crd: enable SDX65 modem
commit: 2eb91146ced41187b554ebb8feccd4b9e9639194Best regards,
Signature · 1 line
Bjorn Andersson <[email protected]>
Re: (subset) [PATCH v2 0/8] arm64: dts: qcom: x1e80100: PCIe fixes and CRD modem support
In reply to Johan HovoldQuoted 10 lines · Johan Hovold
This series fixes some issues with the current x1e80100 PCIe support, adds the PCIe5 nodes and enables the modem on the CRD.
The fixes should go into 6.11, but the modem support depends on them so I decided to send everything in one series.
As Konrad noted some of these issues have been reproduced in the other x1e80100 dts. I'll send a separate series addressing that.
[...]
Applied, thanks!
[1/8] arm64: dts: qcom: x1e80100-crd: fix PCIe4 PHY supply
commit: 30f593fa0088b89f479f7358640687b3cbca93d4
[2/8] arm64: dts: qcom: x1e80100: fix PCIe domain numbers
commit: f8fa1f2f6412bffa71972f9506b72992d0e6e485
[3/8] arm64: dts: qcom: x1e80100: add missing PCIe minimum OPP
commit: 98abf2fbd179017833c38edc9f3b587c69d07e2a
[4/8] arm64: dts: qcom: x1e80100-crd: fix up PCIe6a pinctrl node
commit: 6e3902c499544291ac4fd1a1bb69f2e9037a0e86
[5/8] arm64: dts: qcom: x1e80100-crd: disable PCIe6a perst pull down
commit: 8a6e1dbf1362e78081e71b2690750e9556136f26
[6/8] arm64: dts: qcom: x1e80100-crd: fix missing PCIe4 gpios
commit: 42b33ad188466292eaac9825544b8be8deddb3cbBest regards,
Signature · 1 line
Bjorn Andersson <[email protected]>