[RFC,5/6] arm64: dts: qcom: add base AIM500 dtsi

Message ID 20240205115721.1195336-6-quic_jingyw@quicinc.com
State New
Headers
Series arm64: dts: qcom: Introduce AIM500 platform device tree |

Commit Message

Jingyi Wang Feb. 5, 2024, 11:57 a.m. UTC
  Introduce aim500 board dtsi.

AIM500 Series is a highly optimized family of modules designed to
support AIoT and Generative AI applications based on sm8650p with
PMIC and bluetooth functions etc.

Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
---
 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
 1 file changed, 409 insertions(+)
 create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
  

Comments

Krzysztof Kozlowski Feb. 5, 2024, 12:35 p.m. UTC | #1
On 05/02/2024 12:57, Jingyi Wang wrote:
> Introduce aim500 board dtsi.
> 
> AIM500 Series is a highly optimized family of modules designed to
> support AIoT and Generative AI applications based on sm8650p with
> PMIC and bluetooth functions etc.
> 
> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
> ---
>  arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
>  1 file changed, 409 insertions(+)
>  create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> 
> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> new file mode 100644
> index 000000000000..cb857da8653b
> --- /dev/null
> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> @@ -0,0 +1,409 @@
> +// SPDX-License-Identifier: BSD-3-Clause
> +/*
> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
> + */
> +
> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
> +#include "sm8650p.dtsi"
> +#include "pm8550.dtsi"
> +#include "pm8550b.dtsi"
> +#define PMK8550VE_SID 8
> +#include "pm8550ve.dtsi"
> +#include "pm8550vs.dtsi"
> +#include "pmk8550.dtsi"
> +
> +/ {
> +	aliases {
> +		serial1 = &uart14;
> +	};
> +
> +	vph_pwr: vph-pwr-regulator { };

What is this? Why is it needed?


Best regards,
Krzysztof
  
Dmitry Baryshkov Feb. 5, 2024, 2:23 p.m. UTC | #2
On Mon, 5 Feb 2024 at 14:00, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
>
> Introduce aim500 board dtsi.

So, is it a board or a module?

>
> AIM500 Series is a highly optimized family of modules designed to
> support AIoT and Generative AI applications based on sm8650p with
> PMIC and bluetooth functions etc.
>
> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
> ---
>  arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
>  1 file changed, 409 insertions(+)
>  create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>
> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> new file mode 100644
> index 000000000000..cb857da8653b
> --- /dev/null
> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> @@ -0,0 +1,409 @@
> +// SPDX-License-Identifier: BSD-3-Clause
> +/*
> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
> + */
> +
> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
> +#include "sm8650p.dtsi"
> +#include "pm8550.dtsi"
> +#include "pm8550b.dtsi"
> +#define PMK8550VE_SID 8
> +#include "pm8550ve.dtsi"
> +#include "pm8550vs.dtsi"
> +#include "pmk8550.dtsi"
> +
> +/ {
> +       aliases {
> +               serial1 = &uart14;
> +       };
> +
> +       vph_pwr: vph-pwr-regulator { };

Is this regulator a part of the module or a part of the carrier board?
If the latter is true, this must go to the carrier board DT file.

> +};
> +
> +&apps_rsc {
> +       regulators-0 {
> +               compatible = "qcom,pm8550-rpmh-regulators";
> +
> +               vdd-bob1-supply = <&vph_pwr>;
> +               vdd-bob2-supply = <&vph_pwr>;
> +               vdd-l2-l13-l14-supply = <&vreg_bob1>;
> +               vdd-l3-supply = <&vreg_s1c_1p2>;
> +               vdd-l5-l16-supply = <&vreg_bob1>;
> +               vdd-l6-l7-supply = <&vreg_bob1>;
> +               vdd-l8-l9-supply = <&vreg_bob1>;
> +               vdd-l11-supply = <&vreg_s1c_1p2>;
> +               vdd-l12-supply = <&vreg_s6c_1p8>;
> +               vdd-l15-supply = <&vreg_s6c_1p8>;
> +               vdd-l17-supply = <&vreg_bob2>;
> +
> +               qcom,pmic-id = "b";

[skipped]

> +
> +&qupv3_id_1 {
> +       status = "okay";
> +};

No GPI node being enabled?

> +
> +&tlmm {
> +       bt_default: bt-default-state {
> +               bt-en-pins {
> +                       pins = "gpio17";
> +                       function = "gpio";
> +                       drive-strength = <16>;
> +                       bias-disable;
> +               };
> +
> +               sw-ctrl-pins {
> +                       pins = "gpio18";
> +                       function = "gpio";
> +                       bias-pull-down;
> +               };
> +       };
> +};
> +
> +&uart14 {
> +       status = "okay";
> +
> +       bluetooth {
> +               compatible = "qcom,wcn7850-bt";
> +
> +               clocks = <&rpmhcc RPMH_RF_CLK1>;
> +
> +               vddio-supply = <&vreg_l3c_1p2>;
> +               vddaon-supply = <&vreg_l15b_1p8>;
> +               vdddig-supply = <&vreg_s3c_0p9>;
> +               vddrfa0p8-supply = <&vreg_s3c_0p9>;
> +               vddrfa1p2-supply = <&vreg_s1c_1p2>;
> +               vddrfa1p9-supply = <&vreg_s6c_1p8>;
> +
> +               max-speed = <3200000>;
> +
> +               enable-gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
> +               swctrl-gpios = <&tlmm 18 GPIO_ACTIVE_HIGH>;
> +
> +               pinctrl-0 = <&bt_default>;
> +               pinctrl-names = "default";
> +       };
> +};
> --
> 2.25.1
>
>
  
Jingyi Wang Feb. 20, 2024, 9:11 a.m. UTC | #3
Hi Krzysztof,

On 2/5/2024 8:35 PM, Krzysztof Kozlowski wrote:
> On 05/02/2024 12:57, Jingyi Wang wrote:
>> Introduce aim500 board dtsi.
>>
>> AIM500 Series is a highly optimized family of modules designed to
>> support AIoT and Generative AI applications based on sm8650p with
>> PMIC and bluetooth functions etc.
>>
>> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
>> ---
>>  arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
>>  1 file changed, 409 insertions(+)
>>  create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>
>> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>> new file mode 100644
>> index 000000000000..cb857da8653b
>> --- /dev/null
>> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>> @@ -0,0 +1,409 @@
>> +// SPDX-License-Identifier: BSD-3-Clause
>> +/*
>> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
>> + */
>> +
>> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
>> +#include "sm8650p.dtsi"
>> +#include "pm8550.dtsi"
>> +#include "pm8550b.dtsi"
>> +#define PMK8550VE_SID 8
>> +#include "pm8550ve.dtsi"
>> +#include "pm8550vs.dtsi"
>> +#include "pmk8550.dtsi"
>> +
>> +/ {
>> +	aliases {
>> +		serial1 = &uart14;
>> +	};
>> +
>> +	vph_pwr: vph-pwr-regulator { };
> 
> What is this? Why is it needed?
> 
> 
> Best regards,
> Krzysztof
> 
vph_pwr is the power supply which differs from board design, it is defined in sm8650p-aim500-aiot.dts,
and it is used in the sm8650p-aim500.dts for regulator supply, so we leave the node here.

Thanks,
Jingyi
  
Jingyi Wang Feb. 20, 2024, 9:16 a.m. UTC | #4
Hi Dmitry,

On 2/5/2024 10:23 PM, Dmitry Baryshkov wrote:
> On Mon, 5 Feb 2024 at 14:00, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
>>
>> Introduce aim500 board dtsi.
> 
> So, is it a board or a module?
> 
aim500 is a module, will fix the descrption.

>>
>> AIM500 Series is a highly optimized family of modules designed to
>> support AIoT and Generative AI applications based on sm8650p with
>> PMIC and bluetooth functions etc.
>>
>> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
>> ---
>>  arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
>>  1 file changed, 409 insertions(+)
>>  create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>
>> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>> new file mode 100644
>> index 000000000000..cb857da8653b
>> --- /dev/null
>> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>> @@ -0,0 +1,409 @@
>> +// SPDX-License-Identifier: BSD-3-Clause
>> +/*
>> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
>> + */
>> +
>> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
>> +#include "sm8650p.dtsi"
>> +#include "pm8550.dtsi"
>> +#include "pm8550b.dtsi"
>> +#define PMK8550VE_SID 8
>> +#include "pm8550ve.dtsi"
>> +#include "pm8550vs.dtsi"
>> +#include "pmk8550.dtsi"
>> +
>> +/ {
>> +       aliases {
>> +               serial1 = &uart14;
>> +       };
>> +
>> +       vph_pwr: vph-pwr-regulator { };
> 
> Is this regulator a part of the module or a part of the carrier board?
> If the latter is true, this must go to the carrier board DT file.
> 

the vph_pwr regulator is defined in the aim500-aiot carrier board and used
in aim500 module.

>> +};
>> +
>> +&apps_rsc {
>> +       regulators-0 {
>> +               compatible = "qcom,pm8550-rpmh-regulators";
>> +
>> +               vdd-bob1-supply = <&vph_pwr>;
>> +               vdd-bob2-supply = <&vph_pwr>;
>> +               vdd-l2-l13-l14-supply = <&vreg_bob1>;
>> +               vdd-l3-supply = <&vreg_s1c_1p2>;
>> +               vdd-l5-l16-supply = <&vreg_bob1>;
>> +               vdd-l6-l7-supply = <&vreg_bob1>;
>> +               vdd-l8-l9-supply = <&vreg_bob1>;
>> +               vdd-l11-supply = <&vreg_s1c_1p2>;
>> +               vdd-l12-supply = <&vreg_s6c_1p8>;
>> +               vdd-l15-supply = <&vreg_s6c_1p8>;
>> +               vdd-l17-supply = <&vreg_bob2>;
>> +
>> +               qcom,pmic-id = "b";
> 
> [skipped]
> 
>> +
>> +&qupv3_id_1 {
>> +       status = "okay";
>> +};
> 
> No GPI node being enabled?
> 
will drop this node for there is no client under that.
>> +
>> +&tlmm {
>> +       bt_default: bt-default-state {
>> +               bt-en-pins {
>> +                       pins = "gpio17";
>> +                       function = "gpio";
>> +                       drive-strength = <16>;
>> +                       bias-disable;
>> +               };
>> +
>> +               sw-ctrl-pins {
>> +                       pins = "gpio18";
>> +                       function = "gpio";
>> +                       bias-pull-down;
>> +               };
>> +       };
>> +};
>> +
>> +&uart14 {
>> +       status = "okay";
>> +
>> +       bluetooth {
>> +               compatible = "qcom,wcn7850-bt";
>> +
>> +               clocks = <&rpmhcc RPMH_RF_CLK1>;
>> +
>> +               vddio-supply = <&vreg_l3c_1p2>;
>> +               vddaon-supply = <&vreg_l15b_1p8>;
>> +               vdddig-supply = <&vreg_s3c_0p9>;
>> +               vddrfa0p8-supply = <&vreg_s3c_0p9>;
>> +               vddrfa1p2-supply = <&vreg_s1c_1p2>;
>> +               vddrfa1p9-supply = <&vreg_s6c_1p8>;
>> +
>> +               max-speed = <3200000>;
>> +
>> +               enable-gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
>> +               swctrl-gpios = <&tlmm 18 GPIO_ACTIVE_HIGH>;
>> +
>> +               pinctrl-0 = <&bt_default>;
>> +               pinctrl-names = "default";
>> +       };
>> +};
>> --
>> 2.25.1
>>
>>
> 
> 
Thanks,
Jingyi
  
Dmitry Baryshkov Feb. 20, 2024, 9:19 a.m. UTC | #5
On Tue, 20 Feb 2024 at 11:17, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
>
> Hi Dmitry,
>
> On 2/5/2024 10:23 PM, Dmitry Baryshkov wrote:
> > On Mon, 5 Feb 2024 at 14:00, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
> >>
> >> Introduce aim500 board dtsi.
> >
> > So, is it a board or a module?
> >
> aim500 is a module, will fix the descrption.
>
> >>
> >> AIM500 Series is a highly optimized family of modules designed to
> >> support AIoT and Generative AI applications based on sm8650p with
> >> PMIC and bluetooth functions etc.
> >>
> >> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
> >> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
> >> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
> >> ---
> >>  arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
> >>  1 file changed, 409 insertions(+)
> >>  create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> >>
> >> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> >> new file mode 100644
> >> index 000000000000..cb857da8653b
> >> --- /dev/null
> >> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
> >> @@ -0,0 +1,409 @@
> >> +// SPDX-License-Identifier: BSD-3-Clause
> >> +/*
> >> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
> >> + */
> >> +
> >> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
> >> +#include "sm8650p.dtsi"
> >> +#include "pm8550.dtsi"
> >> +#include "pm8550b.dtsi"
> >> +#define PMK8550VE_SID 8
> >> +#include "pm8550ve.dtsi"
> >> +#include "pm8550vs.dtsi"
> >> +#include "pmk8550.dtsi"
> >> +
> >> +/ {
> >> +       aliases {
> >> +               serial1 = &uart14;
> >> +       };
> >> +
> >> +       vph_pwr: vph-pwr-regulator { };
> >
> > Is this regulator a part of the module or a part of the carrier board?
> > If the latter is true, this must go to the carrier board DT file.
> >
>
> the vph_pwr regulator is defined in the aim500-aiot carrier board and used
> in aim500 module.

If it is defined in the carrier board, then please move it and
corresponding supply entries to the carrier board dts. Other devices
using the SoM can have different power tree.

While we are at it, could you please rename the node to regulator-vph-pwr?
  
Krzysztof Kozlowski Feb. 20, 2024, 9:44 a.m. UTC | #6
On 20/02/2024 10:11, Jingyi Wang wrote:
> Hi Krzysztof,
> 
> On 2/5/2024 8:35 PM, Krzysztof Kozlowski wrote:
>> On 05/02/2024 12:57, Jingyi Wang wrote:
>>> Introduce aim500 board dtsi.
>>>
>>> AIM500 Series is a highly optimized family of modules designed to
>>> support AIoT and Generative AI applications based on sm8650p with
>>> PMIC and bluetooth functions etc.
>>>
>>> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>>> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>>> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
>>> ---
>>>  arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
>>>  1 file changed, 409 insertions(+)
>>>  create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>>
>>> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>> new file mode 100644
>>> index 000000000000..cb857da8653b
>>> --- /dev/null
>>> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>> @@ -0,0 +1,409 @@
>>> +// SPDX-License-Identifier: BSD-3-Clause
>>> +/*
>>> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
>>> + */
>>> +
>>> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
>>> +#include "sm8650p.dtsi"
>>> +#include "pm8550.dtsi"
>>> +#include "pm8550b.dtsi"
>>> +#define PMK8550VE_SID 8
>>> +#include "pm8550ve.dtsi"
>>> +#include "pm8550vs.dtsi"
>>> +#include "pmk8550.dtsi"
>>> +
>>> +/ {
>>> +	aliases {
>>> +		serial1 = &uart14;
>>> +	};
>>> +
>>> +	vph_pwr: vph-pwr-regulator { };
>>
>> What is this? Why is it needed?
>>
>>
>> Best regards,
>> Krzysztof
>>
> vph_pwr is the power supply which differs from board design, it is defined in sm8650p-aim500-aiot.dts,
> and it is used in the sm8650p-aim500.dts for regulator supply, so we leave the node here.

How an empty, unused node is a power supply?

Best regards,
Krzysztof
  
Jingyi Wang Feb. 20, 2024, 10:06 a.m. UTC | #7
Hi Dmitry,

On 2/20/2024 5:19 PM, Dmitry Baryshkov wrote:
> On Tue, 20 Feb 2024 at 11:17, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
>>
>> Hi Dmitry,
>>
>> On 2/5/2024 10:23 PM, Dmitry Baryshkov wrote:
>>> On Mon, 5 Feb 2024 at 14:00, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
>>>>
>>>> Introduce aim500 board dtsi.
>>>
>>> So, is it a board or a module?
>>>
>> aim500 is a module, will fix the descrption.
>>
>>>>
>>>> AIM500 Series is a highly optimized family of modules designed to
>>>> support AIoT and Generative AI applications based on sm8650p with
>>>> PMIC and bluetooth functions etc.
>>>>
>>>> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>>>> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>>>> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
>>>> ---
>>>>  arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
>>>>  1 file changed, 409 insertions(+)
>>>>  create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>>>
>>>> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>>> new file mode 100644
>>>> index 000000000000..cb857da8653b
>>>> --- /dev/null
>>>> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>>> @@ -0,0 +1,409 @@
>>>> +// SPDX-License-Identifier: BSD-3-Clause
>>>> +/*
>>>> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
>>>> + */
>>>> +
>>>> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
>>>> +#include "sm8650p.dtsi"
>>>> +#include "pm8550.dtsi"
>>>> +#include "pm8550b.dtsi"
>>>> +#define PMK8550VE_SID 8
>>>> +#include "pm8550ve.dtsi"
>>>> +#include "pm8550vs.dtsi"
>>>> +#include "pmk8550.dtsi"
>>>> +
>>>> +/ {
>>>> +       aliases {
>>>> +               serial1 = &uart14;
>>>> +       };
>>>> +
>>>> +       vph_pwr: vph-pwr-regulator { };
>>>
>>> Is this regulator a part of the module or a part of the carrier board?
>>> If the latter is true, this must go to the carrier board DT file.
>>>
>>
>> the vph_pwr regulator is defined in the aim500-aiot carrier board and used
>> in aim500 module.
> 
> If it is defined in the carrier board, then please move it and
> corresponding supply entries to the carrier board dts. Other devices
> using the SoM can have different power tree.
> 
> While we are at it, could you please rename the node to regulator-vph-pwr?
> 
> 
will rename the node and move it to sm8650p-aim500-aiot.dts

Thanks,
Jingyi
  
Aiqun Yu (Maria) Feb. 20, 2024, 10:28 a.m. UTC | #8
On 2/20/2024 6:06 PM, Jingyi Wang wrote:
> Hi Dmitry,
> 
> On 2/20/2024 5:19 PM, Dmitry Baryshkov wrote:
>> On Tue, 20 Feb 2024 at 11:17, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
>>>
>>> Hi Dmitry,
>>>
>>> On 2/5/2024 10:23 PM, Dmitry Baryshkov wrote:
>>>> On Mon, 5 Feb 2024 at 14:00, Jingyi Wang <quic_jingyw@quicinc.com> wrote:
>>>>>
>>>>> Introduce aim500 board dtsi.
>>>>
>>>> So, is it a board or a module?
>>>>
>>> aim500 is a module, will fix the descrption.
>>>
>>>>>
>>>>> AIM500 Series is a highly optimized family of modules designed to
>>>>> support AIoT and Generative AI applications based on sm8650p with
>>>>> PMIC and bluetooth functions etc.
>>>>>
>>>>> Co-developed-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>>>>> Signed-off-by: Tingwei Zhang <quic_tingweiz@quicinc.com>
>>>>> Signed-off-by: Jingyi Wang <quic_jingyw@quicinc.com>
>>>>> ---
>>>>>   arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi | 409 +++++++++++++++++++
>>>>>   1 file changed, 409 insertions(+)
>>>>>   create mode 100644 arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>>>>
>>>>> diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>>>> new file mode 100644
>>>>> index 000000000000..cb857da8653b
>>>>> --- /dev/null
>>>>> +++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
>>>>> @@ -0,0 +1,409 @@
>>>>> +// SPDX-License-Identifier: BSD-3-Clause
>>>>> +/*
>>>>> + * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
>>>>> + */
>>>>> +
>>>>> +#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
>>>>> +#include "sm8650p.dtsi"
>>>>> +#include "pm8550.dtsi"
>>>>> +#include "pm8550b.dtsi"
>>>>> +#define PMK8550VE_SID 8
>>>>> +#include "pm8550ve.dtsi"
>>>>> +#include "pm8550vs.dtsi"
>>>>> +#include "pmk8550.dtsi"
>>>>> +
>>>>> +/ {
>>>>> +       aliases {
>>>>> +               serial1 = &uart14;
>>>>> +       };
>>>>> +
>>>>> +       vph_pwr: vph-pwr-regulator { };
>>>>
>>>> Is this regulator a part of the module or a part of the carrier board?
>>>> If the latter is true, this must go to the carrier board DT file.
>>>>
>>>
>>> the vph_pwr regulator is defined in the aim500-aiot carrier board and used
>>> in aim500 module.
>>
>> If it is defined in the carrier board, then please move it and
>> corresponding supply entries to the carrier board dts. Other devices
>> using the SoM can have different power tree.
>>
>> While we are at it, could you please rename the node to regulator-vph-pwr?
>>
>>
> will rename the node and move it to sm8650p-aim500-aiot.dts

Shall we have the VPH_PWR implementation inside the board dts file, and 
have the supply entries which used the VPH_PWR inside the SOM.dtsi file?

The VPH_PWR is an input IO of SOM. And the corresponding supply entries 
is inside the SOM hardware design as well.

The VPH_PWR as a fixed regulator implementation is the board design, it 
can be changed to other design from different boards.

Here is a simple diagram to show the hardware description of the VPH_PWR 
related design:

+------------------------------------------------------+ 
 

|                 Board                                | 
 

|                                                      | 
 

|           +-----------------+                        | 
 

|power----->| Fixed regulator-----------+              | 
 

|           +-----------------+         |              | 
 

|                                       |              | 
 

|                                       v VPH_PWR      | 
 

|                  +------|----------------------+     | 
 

|                  |      |    SOM       |       |     | 
 

|                  |      |              |       |     | 
 

|                  |      vVPH_PWR       vVPM_PWR|     | 
 

|                  |  +------+       +------+    |     | 
 

|                  |  | pmic1|       |pmic2 |    |     | 
 

|                  |  +------+       +------+    |     | 
 

|                  |                             |     | 
 

|                  +-----------------------------+     | 
 

+------------------------------------------------------+ 
 



> 
> Thanks,
> Jingyi
  

Patch

diff --git a/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
new file mode 100644
index 000000000000..cb857da8653b
--- /dev/null
+++ b/arch/arm64/boot/dts/qcom/sm8650p-aim500.dtsi
@@ -0,0 +1,409 @@ 
+// SPDX-License-Identifier: BSD-3-Clause
+/*
+ * Copyright (c) 2024, Qualcomm Innovation Center, Inc. All rights reserved.
+ */
+
+#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
+#include "sm8650p.dtsi"
+#include "pm8550.dtsi"
+#include "pm8550b.dtsi"
+#define PMK8550VE_SID 8
+#include "pm8550ve.dtsi"
+#include "pm8550vs.dtsi"
+#include "pmk8550.dtsi"
+
+/ {
+	aliases {
+		serial1 = &uart14;
+	};
+
+	vph_pwr: vph-pwr-regulator { };
+};
+
+&apps_rsc {
+	regulators-0 {
+		compatible = "qcom,pm8550-rpmh-regulators";
+
+		vdd-bob1-supply = <&vph_pwr>;
+		vdd-bob2-supply = <&vph_pwr>;
+		vdd-l2-l13-l14-supply = <&vreg_bob1>;
+		vdd-l3-supply = <&vreg_s1c_1p2>;
+		vdd-l5-l16-supply = <&vreg_bob1>;
+		vdd-l6-l7-supply = <&vreg_bob1>;
+		vdd-l8-l9-supply = <&vreg_bob1>;
+		vdd-l11-supply = <&vreg_s1c_1p2>;
+		vdd-l12-supply = <&vreg_s6c_1p8>;
+		vdd-l15-supply = <&vreg_s6c_1p8>;
+		vdd-l17-supply = <&vreg_bob2>;
+
+		qcom,pmic-id = "b";
+
+		vreg_bob1: bob1 {
+			regulator-name = "vreg_bob1";
+			regulator-min-microvolt = <3008000>;
+			regulator-max-microvolt = <3960000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_bob2: bob2 {
+			regulator-name = "vreg_bob2";
+			regulator-min-microvolt = <2704000>;
+			regulator-max-microvolt = <3008000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l2b_3p0: ldo2 {
+			regulator-name = "vreg_l2b_3p0";
+			regulator-min-microvolt = <3008000>;
+			regulator-max-microvolt = <3008000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l5b_3p1: ldo5 {
+			regulator-name = "vreg_l5b_3p1";
+			regulator-min-microvolt = <3104000>;
+			regulator-max-microvolt = <3104000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l6b_1p8: ldo6 {
+			regulator-name = "vreg_l6b_1p8";
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <3008000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l7b_1p8: ldo7 {
+			regulator-name = "vreg_l7b_1p8";
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <3008000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l8b_1p8: ldo8 {
+			regulator-name = "vreg_l8b_1p8";
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <3008000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l11b_1p2: ldo11 {
+			regulator-name = "vreg_l11b_1p2";
+			regulator-min-microvolt = <1200000>;
+			regulator-max-microvolt = <1200000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l12b_1p8: ldo12 {
+			regulator-name = "vreg_l12b_1p8";
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l13b_3p0: ldo13 {
+			regulator-name = "vreg_l13b_3p0";
+			regulator-min-microvolt = <3000000>;
+			regulator-max-microvolt = <3000000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l14b_3p2: ldo14 {
+			regulator-name = "vreg_l14b_3p2";
+			regulator-min-microvolt = <3200000>;
+			regulator-max-microvolt = <3200000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l15b_1p8: ldo15 {
+			regulator-name = "vreg_l15b_1p8";
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l16b_2p8: ldo16 {
+			regulator-name = "vreg_l16b_2p8";
+			regulator-min-microvolt = <2800000>;
+			regulator-max-microvolt = <2800000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l17b_2p5: ldo17 {
+			regulator-name = "vreg_l17b_2p5";
+			regulator-min-microvolt = <2504000>;
+			regulator-max-microvolt = <2504000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-1 {
+		compatible = "qcom,pm8550vs-rpmh-regulators";
+
+		vdd-l1-supply = <&vreg_s1c_1p2>;
+		vdd-l2-supply = <&vreg_s1c_1p2>;
+		vdd-l3-supply = <&vreg_s1c_1p2>;
+		vdd-s1-supply = <&vph_pwr>;
+		vdd-s2-supply = <&vph_pwr>;
+		vdd-s3-supply = <&vph_pwr>;
+		vdd-s4-supply = <&vph_pwr>;
+		vdd-s5-supply = <&vph_pwr>;
+		vdd-s6-supply = <&vph_pwr>;
+
+		qcom,pmic-id = "c";
+
+		vreg_s1c_1p2: smps1 {
+			regulator-name = "vreg_s1c_1p2";
+			regulator-min-microvolt = <1224000>;
+			regulator-max-microvolt = <1348000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_s2c_0p8: smps2 {
+			regulator-name = "vreg_s2c_0p8";
+			regulator-min-microvolt = <500000>;
+			regulator-max-microvolt = <1036000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_s3c_0p9: smps3 {
+			regulator-name = "vreg_s3c_0p9";
+			regulator-min-microvolt = <904000>;
+			regulator-max-microvolt = <1068000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_s4c_1p2: smps4 {
+			regulator-name = "vreg_s4c_1p2";
+			regulator-min-microvolt = <1200000>;
+			regulator-max-microvolt = <1280000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_s5c_0p7: smps5 {
+			regulator-name = "vreg_s5c_0p7";
+			regulator-min-microvolt = <300000>;
+			regulator-max-microvolt = <900000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_s6c_1p8: smps6 {
+			regulator-name = "vreg_s6c_1p8";
+			regulator-min-microvolt = <1856000>;
+			regulator-max-microvolt = <2000000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l1c_1p2: ldo1 {
+			regulator-name = "vreg_l1c_1p2";
+			regulator-min-microvolt = <1100000>;
+			regulator-max-microvolt = <1200000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l3c_1p2: ldo3 {
+			regulator-name = "vreg_l3c_1p2";
+			regulator-min-microvolt = <1200000>;
+			regulator-max-microvolt = <1200000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-2 {
+		compatible = "qcom,pm8550vs-rpmh-regulators";
+
+		vdd-l1-supply = <&vreg_s3c_0p9>;
+
+		qcom,pmic-id = "d";
+
+		vreg_l1d_0p88: ldo1 {
+			regulator-name = "vreg_l1d_0p88";
+			regulator-min-microvolt = <880000>;
+			regulator-max-microvolt = <920000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-3 {
+		compatible = "qcom,pm8550vs-rpmh-regulators";
+
+		vdd-l3-supply = <&vreg_s3c_0p9>;
+
+		qcom,pmic-id = "e";
+
+		vreg_l3e_0p9: ldo3 {
+			regulator-name = "vreg_l3e_0p9";
+			regulator-min-microvolt = <880000>;
+			regulator-max-microvolt = <920000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-4 {
+		compatible = "qcom,pm8550vs-rpmh-regulators";
+
+		vdd-l1-supply = <&vreg_s3c_0p9>;
+		vdd-l3-supply = <&vreg_s3c_0p9>;
+
+		qcom,pmic-id = "g";
+
+		vreg_l1g_0p91: ldo1 {
+			regulator-name = "vreg_l1g_0p91";
+			regulator-min-microvolt = <912000>;
+			regulator-max-microvolt = <936000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l3g_0p91: ldo3 {
+			regulator-name = "vreg_l3g_0p91";
+			regulator-min-microvolt = <880000>;
+			regulator-max-microvolt = <912000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-5 {
+		compatible = "qcom,pm8550ve-rpmh-regulators";
+
+		vdd-l1-supply = <&vreg_s3c_0p9>;
+		vdd-l2-supply = <&vreg_s3c_0p9>;
+		vdd-l3-supply = <&vreg_s1c_1p2>;
+		vdd-s4-supply = <&vph_pwr>;
+
+		qcom,pmic-id = "i";
+
+		vreg_s4i_0p85: smps4 {
+			regulator-name = "vreg_s4i_0p85";
+			regulator-min-microvolt = <300000>;
+			regulator-max-microvolt = <1004000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l1i_0p88: ldo1 {
+			regulator-name = "vreg_l1i_0p88";
+			regulator-min-microvolt = <880000>;
+			regulator-max-microvolt = <912000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l2i_0p88: ldo2 {
+			regulator-name = "vreg_l2i_0p88";
+			regulator-min-microvolt = <880000>;
+			regulator-max-microvolt = <912000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l3i_1p2: ldo3 {
+			regulator-name = "vreg_l3i_0p91";
+			regulator-min-microvolt = <1200000>;
+			regulator-max-microvolt = <1200000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM
+						   RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+};
+
+&qupv3_id_1 {
+	status = "okay";
+};
+
+&tlmm {
+	bt_default: bt-default-state {
+		bt-en-pins {
+			pins = "gpio17";
+			function = "gpio";
+			drive-strength = <16>;
+			bias-disable;
+		};
+
+		sw-ctrl-pins {
+			pins = "gpio18";
+			function = "gpio";
+			bias-pull-down;
+		};
+	};
+};
+
+&uart14 {
+	status = "okay";
+
+	bluetooth {
+		compatible = "qcom,wcn7850-bt";
+
+		clocks = <&rpmhcc RPMH_RF_CLK1>;
+
+		vddio-supply = <&vreg_l3c_1p2>;
+		vddaon-supply = <&vreg_l15b_1p8>;
+		vdddig-supply = <&vreg_s3c_0p9>;
+		vddrfa0p8-supply = <&vreg_s3c_0p9>;
+		vddrfa1p2-supply = <&vreg_s1c_1p2>;
+		vddrfa1p9-supply = <&vreg_s6c_1p8>;
+
+		max-speed = <3200000>;
+
+		enable-gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
+		swctrl-gpios = <&tlmm 18 GPIO_ACTIVE_HIGH>;
+
+		pinctrl-0 = <&bt_default>;
+		pinctrl-names = "default";
+	};
+};