Re: [PATCH v6 1/2] arm64: dts: qcom: ipq5424: Add PCIe PHYs and controller nodes

From: Manikanta Mylavarapu
Date: Tue Apr 15 2025 - 08:21:39 EST




On 4/14/2025 4:17 PM, Konrad Dybcio wrote:
> On 4/2/25 12:27 PM, Manikanta Mylavarapu wrote:
>> Add PCIe0, PCIe1, PCIe2, PCIe3 (and corresponding PHY) devices
>> found on IPQ5424 platform. The PCIe0 & PCIe1 are 1-lane Gen3
>> host whereas PCIe2 & PCIe3 are 2-lane Gen3 host.
>>
>> Signed-off-by: Manikanta Mylavarapu <quic_mmanikan@xxxxxxxxxxx>
>> ---
>
> [...]
>
>> + pcie0_phy: phy@84000 {
>> + compatible = "qcom,ipq5424-qmp-gen3x1-pcie-phy",
>> + "qcom,ipq9574-qmp-gen3x1-pcie-phy";
>> + reg = <0x0 0x00084000 0x0 0x2000>;
>
> This is 0x1000-wide
>

Okay, sure.

>> + clocks = <&gcc GCC_PCIE0_AUX_CLK>,
>> + <&gcc GCC_PCIE0_AHB_CLK>,
>> + <&gcc GCC_PCIE0_PIPE_CLK>;
>> + clock-names = "aux",
>> + "cfg_ahb",
>> + "pipe";
>> +
>> + assigned-clocks = <&gcc GCC_PCIE0_AUX_CLK>;
>> + assigned-clock-rates = <20000000>;
>> +
>> + resets = <&gcc GCC_PCIE0_PHY_BCR>,
>> + <&gcc GCC_PCIE0PHY_PHY_BCR>;
>> + reset-names = "phy",
>> + "common";
>> +
>> + #clock-cells = <0>;
>> + clock-output-names = "gcc_pcie0_pipe_clk_src";
>> +
>> + #phy-cells = <0>;
>> + status = "disabled";
>> + };
>> +
>> + pcie1_phy: phy@8c000 {
>> + compatible = "qcom,ipq5424-qmp-gen3x1-pcie-phy",
>> + "qcom,ipq9574-qmp-gen3x1-pcie-phy";
>> + reg = <0x0 0x0008c000 0x0 0x2000>;
>
> So is this
>

Okay, sure.

>> + clocks = <&gcc GCC_PCIE1_AUX_CLK>,
>> + <&gcc GCC_PCIE1_AHB_CLK>,
>> + <&gcc GCC_PCIE1_PIPE_CLK>;
>> + clock-names = "aux",
>> + "cfg_ahb",
>> + "pipe";
>> +
>> + assigned-clocks = <&gcc GCC_PCIE1_AUX_CLK>;
>> + assigned-clock-rates = <20000000>;
>> +
>> + resets = <&gcc GCC_PCIE1_PHY_BCR>,
>> + <&gcc GCC_PCIE1PHY_PHY_BCR>;
>> + reset-names = "phy",
>> + "common";
>> +
>> + #clock-cells = <0>;
>> + clock-output-names = "gcc_pcie1_pipe_clk_src";
>> +
>> + #phy-cells = <0>;
>> + status = "disabled";
>> + };
>
>
>> + pcie3: pcie@40000000 {
>> + compatible = "qcom,pcie-ipq5424", "qcom,pcie-ipq9574";
>> + reg = <0x0 0x40000000 0x0 0xf1c>,
>> + <0x0 0x40000f20 0x0 0xa8>,
>> + <0x0 0x40001000 0x0 0x1000>,
>> + <0x0 0x000f8000 0x0 0x3000>,
>> + <0x0 0x40100000 0x0 0x1000>,
>> + <0x0 0x000fe000 0x0 0x1000>;
>> + reg-names = "dbi",
>> + "elbi",
>> + "atu",
>> + "parf",
>> + "config",
>> + "mhi";
>> + device_type = "pci";
>> + linux,pci-domain = <3>;
>> + num-lanes = <2>;
>> + #address-cells = <3>;
>> + #size-cells = <2>;
>> +
>> + ranges = <0x01000000 0x0 0x00000000 0x0 0x40200000 0x0 0x00100000>,
>> + <0x02000000 0x0 0x40300000 0x0 0x40300000 0x0 0x0fd00000>;
>
> I think the BAR spaces on all these hosts are only 32 MiB long
>

I have confirmed with the hardware team that the specified BAR register space is accurate.
256MB for all PCIe controllers.

Thanks & Regards,
Manikanta.