Linux ARM-MSM sub-architecture
 help / color / mirror / Atom feed
* [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply
@ 2025-10-23  4:02 Manikanta Mylavarapu
  2025-10-23 14:12 ` Dmitry Baryshkov
  2025-10-23 14:33 ` Konrad Dybcio
  0 siblings, 2 replies; 5+ messages in thread
From: Manikanta Mylavarapu @ 2025-10-23  4:02 UTC (permalink / raw)
  To: andersson, konradybcio, robh, krzk+dt, conor+dt, linux-arm-msm,
	devicetree, linux-kernel
  Cc: quic_srichara, quic_varada, kathiravan.thirumoorthy

Add a GPIO-controlled regulator node for the CPU rail on the
IPQ5424 RDP466 platform. This regulator supports two voltage
levels 850mV and 1000mV.

Update CPU nodes to reference the regulator via the `cpu-supply`
property, and add the required pinctrl configuration for GPIO17.

Signed-off-by: Manikanta Mylavarapu <quic_mmanikan@quicinc.com>
---
 arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts | 24 +++++++++++++++++++++
 arch/arm64/boot/dts/qcom/ipq5424.dtsi       |  4 ++++
 2 files changed, 28 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
index 738618551203..6d14eb2fe821 100644
--- a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
+++ b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
@@ -46,6 +46,23 @@ led-0 {
 		};
 	};
 
+	vreg_apc: regulator-vreg-apc {
+		compatible = "regulator-gpio";
+		regulator-name = "vreg_apc";
+		regulator-min-microvolt = <850000>;
+		regulator-max-microvolt = <1000000>;
+		regulator-boot-on;
+		regulator-always-on;
+		regulator-ramp-delay = <250>;
+
+		gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
+		gpios-states = <1>;
+		states = <850000 0>, <1000000 1>;
+
+		pinctrl-0 = <&regulator_gpio_default>;
+		pinctrl-names = "default";
+	};
+
 	vreg_misc_3p3: regulator-usb-3p3 {
 		compatible = "regulator-fixed";
 		regulator-min-microvolt = <3300000>;
@@ -171,6 +188,13 @@ gpio_leds_default: gpio-leds-default-state {
 		bias-pull-down;
 	};
 
+	regulator_gpio_default: regulator-gpio-default-state {
+		pins = "gpio17";
+		function = "gpio";
+		drive-strength = <8>;
+		bias-disable;
+	};
+
 	spi0_default_state: spi0-default-state {
 		clk-pins {
 			pins = "gpio6";
diff --git a/arch/arm64/boot/dts/qcom/ipq5424.dtsi b/arch/arm64/boot/dts/qcom/ipq5424.dtsi
index ef2b52f3597d..70702c80c626 100644
--- a/arch/arm64/boot/dts/qcom/ipq5424.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq5424.dtsi
@@ -56,6 +56,7 @@ cpu0: cpu@0 {
 			clocks = <&apss_clk APSS_SILVER_CORE_CLK>;
 			clock-names = "cpu";
 			operating-points-v2 = <&cpu_opp_table>;
+			cpu-supply = <&vreg_apc>;
 			interconnects = <&apss_clk MASTER_CPU &apss_clk SLAVE_L3>;
 
 			l2_0: l2-cache {
@@ -81,6 +82,7 @@ cpu1: cpu@100 {
 			clocks = <&apss_clk APSS_SILVER_CORE_CLK>;
 			clock-names = "cpu";
 			operating-points-v2 = <&cpu_opp_table>;
+			cpu-supply = <&vreg_apc>;
 			interconnects = <&apss_clk MASTER_CPU &apss_clk SLAVE_L3>;
 
 			l2_100: l2-cache {
@@ -100,6 +102,7 @@ cpu2: cpu@200 {
 			clocks = <&apss_clk APSS_SILVER_CORE_CLK>;
 			clock-names = "cpu";
 			operating-points-v2 = <&cpu_opp_table>;
+			cpu-supply = <&vreg_apc>;
 			interconnects = <&apss_clk MASTER_CPU &apss_clk SLAVE_L3>;
 
 			l2_200: l2-cache {
@@ -119,6 +122,7 @@ cpu3: cpu@300 {
 			clocks = <&apss_clk APSS_SILVER_CORE_CLK>;
 			clock-names = "cpu";
 			operating-points-v2 = <&cpu_opp_table>;
+			cpu-supply = <&vreg_apc>;
 			interconnects = <&apss_clk MASTER_CPU &apss_clk SLAVE_L3>;
 
 			l2_300: l2-cache {

base-commit: fe45352cd106ae41b5ad3f0066c2e54dbb2dfd70
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply
  2025-10-23  4:02 [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply Manikanta Mylavarapu
@ 2025-10-23 14:12 ` Dmitry Baryshkov
  2025-10-27 11:53   ` Manikanta Mylavarapu
  2025-10-23 14:33 ` Konrad Dybcio
  1 sibling, 1 reply; 5+ messages in thread
From: Dmitry Baryshkov @ 2025-10-23 14:12 UTC (permalink / raw)
  To: Manikanta Mylavarapu
  Cc: andersson, konradybcio, robh, krzk+dt, conor+dt, linux-arm-msm,
	devicetree, linux-kernel, quic_srichara, quic_varada,
	kathiravan.thirumoorthy

On Thu, Oct 23, 2025 at 09:32:24AM +0530, Manikanta Mylavarapu wrote:
> Add a GPIO-controlled regulator node for the CPU rail on the
> IPQ5424 RDP466 platform. This regulator supports two voltage
> levels 850mV and 1000mV.
> 
> Update CPU nodes to reference the regulator via the `cpu-supply`
> property, and add the required pinctrl configuration for GPIO17.
> 
> Signed-off-by: Manikanta Mylavarapu <quic_mmanikan@quicinc.com>
> ---
>  arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts | 24 +++++++++++++++++++++
>  arch/arm64/boot/dts/qcom/ipq5424.dtsi       |  4 ++++
>  2 files changed, 28 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
> index 738618551203..6d14eb2fe821 100644
> --- a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
> +++ b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
> @@ -46,6 +46,23 @@ led-0 {
>  		};
>  	};
>  
> +	vreg_apc: regulator-vreg-apc {
> +		compatible = "regulator-gpio";
> +		regulator-name = "vreg_apc";
> +		regulator-min-microvolt = <850000>;
> +		regulator-max-microvolt = <1000000>;
> +		regulator-boot-on;
> +		regulator-always-on;
> +		regulator-ramp-delay = <250>;
> +
> +		gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
> +		gpios-states = <1>;
> +		states = <850000 0>, <1000000 1>;
> +
> +		pinctrl-0 = <&regulator_gpio_default>;
> +		pinctrl-names = "default";

'vreg' > 'usb'

> +	};
> +
>  	vreg_misc_3p3: regulator-usb-3p3 {
>  		compatible = "regulator-fixed";
>  		regulator-min-microvolt = <3300000>;
-- 
With best wishes
Dmitry

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply
  2025-10-23  4:02 [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply Manikanta Mylavarapu
  2025-10-23 14:12 ` Dmitry Baryshkov
@ 2025-10-23 14:33 ` Konrad Dybcio
  2025-10-27 11:53   ` Manikanta Mylavarapu
  1 sibling, 1 reply; 5+ messages in thread
From: Konrad Dybcio @ 2025-10-23 14:33 UTC (permalink / raw)
  To: Manikanta Mylavarapu, andersson, konradybcio, robh, krzk+dt,
	conor+dt, linux-arm-msm, devicetree, linux-kernel
  Cc: quic_srichara, quic_varada, kathiravan.thirumoorthy

On 10/23/25 6:02 AM, Manikanta Mylavarapu wrote:
> Add a GPIO-controlled regulator node for the CPU rail on the
> IPQ5424 RDP466 platform. This regulator supports two voltage
> levels 850mV and 1000mV.
> 
> Update CPU nodes to reference the regulator via the `cpu-supply`
> property, and add the required pinctrl configuration for GPIO17.
> 
> Signed-off-by: Manikanta Mylavarapu <quic_mmanikan@quicinc.com>
> ---
>  arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts | 24 +++++++++++++++++++++
>  arch/arm64/boot/dts/qcom/ipq5424.dtsi       |  4 ++++
>  2 files changed, 28 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
> index 738618551203..6d14eb2fe821 100644
> --- a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
> +++ b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
> @@ -46,6 +46,23 @@ led-0 {
>  		};
>  	};
>  
> +	vreg_apc: regulator-vreg-apc {
> +		compatible = "regulator-gpio";
> +		regulator-name = "vreg_apc";
> +		regulator-min-microvolt = <850000>;
> +		regulator-max-microvolt = <1000000>;
> +		regulator-boot-on;
> +		regulator-always-on;
> +		regulator-ramp-delay = <250>;
> +
> +		gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
> +		gpios-states = <1>;
> +		states = <850000 0>, <1000000 1>;

Atop Dmitry's comment, please make the states entries 1 a line

Konrad

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply
  2025-10-23 14:33 ` Konrad Dybcio
@ 2025-10-27 11:53   ` Manikanta Mylavarapu
  0 siblings, 0 replies; 5+ messages in thread
From: Manikanta Mylavarapu @ 2025-10-27 11:53 UTC (permalink / raw)
  To: Konrad Dybcio, andersson, konradybcio, robh, krzk+dt, conor+dt,
	linux-arm-msm, devicetree, linux-kernel
  Cc: quic_srichara, quic_varada, kathiravan.thirumoorthy



On 10/23/2025 8:03 PM, Konrad Dybcio wrote:
> On 10/23/25 6:02 AM, Manikanta Mylavarapu wrote:
>> Add a GPIO-controlled regulator node for the CPU rail on the
>> IPQ5424 RDP466 platform. This regulator supports two voltage
>> levels 850mV and 1000mV.
>>
>> Update CPU nodes to reference the regulator via the `cpu-supply`
>> property, and add the required pinctrl configuration for GPIO17.
>>
>> Signed-off-by: Manikanta Mylavarapu <quic_mmanikan@quicinc.com>
>> ---
>>  arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts | 24 +++++++++++++++++++++
>>  arch/arm64/boot/dts/qcom/ipq5424.dtsi       |  4 ++++
>>  2 files changed, 28 insertions(+)
>>
>> diff --git a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
>> index 738618551203..6d14eb2fe821 100644
>> --- a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
>> +++ b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
>> @@ -46,6 +46,23 @@ led-0 {
>>  		};
>>  	};
>>  
>> +	vreg_apc: regulator-vreg-apc {
>> +		compatible = "regulator-gpio";
>> +		regulator-name = "vreg_apc";
>> +		regulator-min-microvolt = <850000>;
>> +		regulator-max-microvolt = <1000000>;
>> +		regulator-boot-on;
>> +		regulator-always-on;
>> +		regulator-ramp-delay = <250>;
>> +
>> +		gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
>> +		gpios-states = <1>;
>> +		states = <850000 0>, <1000000 1>;
> 
> Atop Dmitry's comment, please make the states entries 1 a line

Hi Konrad,

Thank you for reviewing the patch.
I will incorporate the suggested change in the next version.

Thanks & Regards,
Manikanta.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply
  2025-10-23 14:12 ` Dmitry Baryshkov
@ 2025-10-27 11:53   ` Manikanta Mylavarapu
  0 siblings, 0 replies; 5+ messages in thread
From: Manikanta Mylavarapu @ 2025-10-27 11:53 UTC (permalink / raw)
  To: Dmitry Baryshkov
  Cc: andersson, konradybcio, robh, krzk+dt, conor+dt, linux-arm-msm,
	devicetree, linux-kernel, quic_srichara, quic_varada,
	kathiravan.thirumoorthy



On 10/23/2025 7:42 PM, Dmitry Baryshkov wrote:
> On Thu, Oct 23, 2025 at 09:32:24AM +0530, Manikanta Mylavarapu wrote:
>> Add a GPIO-controlled regulator node for the CPU rail on the
>> IPQ5424 RDP466 platform. This regulator supports two voltage
>> levels 850mV and 1000mV.
>>
>> Update CPU nodes to reference the regulator via the `cpu-supply`
>> property, and add the required pinctrl configuration for GPIO17.
>>
>> Signed-off-by: Manikanta Mylavarapu <quic_mmanikan@quicinc.com>
>> ---
>>  arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts | 24 +++++++++++++++++++++
>>  arch/arm64/boot/dts/qcom/ipq5424.dtsi       |  4 ++++
>>  2 files changed, 28 insertions(+)
>>
>> diff --git a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
>> index 738618551203..6d14eb2fe821 100644
>> --- a/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
>> +++ b/arch/arm64/boot/dts/qcom/ipq5424-rdp466.dts
>> @@ -46,6 +46,23 @@ led-0 {
>>  		};
>>  	};
>>  
>> +	vreg_apc: regulator-vreg-apc {
>> +		compatible = "regulator-gpio";
>> +		regulator-name = "vreg_apc";
>> +		regulator-min-microvolt = <850000>;
>> +		regulator-max-microvolt = <1000000>;
>> +		regulator-boot-on;
>> +		regulator-always-on;
>> +		regulator-ramp-delay = <250>;
>> +
>> +		gpios = <&tlmm 17 GPIO_ACTIVE_HIGH>;
>> +		gpios-states = <1>;
>> +		states = <850000 0>, <1000000 1>;
>> +
>> +		pinctrl-0 = <&regulator_gpio_default>;
>> +		pinctrl-names = "default";
> 
> 'vreg' > 'usb'
> 

Hi Dmitry,

Thank you for reviewing the patch.
I will incorporate the suggested change in the next version.

Thanks & Regards,
Manikanta.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2025-10-27 11:53 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-23  4:02 [PATCH v1] arm64: dts: qcom: ipq5424: add gpio regulator for cpu power supply Manikanta Mylavarapu
2025-10-23 14:12 ` Dmitry Baryshkov
2025-10-27 11:53   ` Manikanta Mylavarapu
2025-10-23 14:33 ` Konrad Dybcio
2025-10-27 11:53   ` Manikanta Mylavarapu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox