* [PATCH] arm64: dts: allwinner: h616: rg35xx add missing regulator-ramp-delay @ 2024-12-03 20:38 Philippe Simons 2024-12-05 4:16 ` Chen-Yu Tsai 0 siblings, 1 reply; 4+ messages in thread From: Philippe Simons @ 2024-12-03 20:38 UTC (permalink / raw) To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec, Samuel Holland, open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS, moderated list:ARM/Allwinner sunXi SoC support, open list:ARM/Allwinner sunXi SoC support, open list Cc: Philippe Simons AXP datasheet says that ramp delay is 15.625 us/step, which is 10mV in our case. add missing regulator-ramp-delay to dcdc regulators accordingly Signed-off-by: Philippe Simons <simons.philippe@gmail.com> --- .../boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts index 80ccab7b5..b6e76a804 100644 --- a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts +++ b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts @@ -238,6 +238,7 @@ reg_dcdc1: dcdc1 { regulator-always-on; regulator-min-microvolt = <900000>; regulator-max-microvolt = <1160000>; + regulator-ramp-delay = <640>; regulator-name = "vdd-cpu"; }; @@ -245,6 +246,7 @@ reg_dcdc2: dcdc2 { regulator-always-on; regulator-min-microvolt = <940000>; regulator-max-microvolt = <940000>; + regulator-ramp-delay = <640>; regulator-name = "vdd-gpu-sys"; }; @@ -252,6 +254,7 @@ reg_dcdc3: dcdc3 { regulator-always-on; regulator-min-microvolt = <1100000>; regulator-max-microvolt = <1100000>; + regulator-ramp-delay = <640>; regulator-name = "vdd-dram"; }; -- 2.47.1 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] arm64: dts: allwinner: h616: rg35xx add missing regulator-ramp-delay 2024-12-03 20:38 [PATCH] arm64: dts: allwinner: h616: rg35xx add missing regulator-ramp-delay Philippe Simons @ 2024-12-05 4:16 ` Chen-Yu Tsai 2024-12-05 7:26 ` Philippe Simons 0 siblings, 1 reply; 4+ messages in thread From: Chen-Yu Tsai @ 2024-12-05 4:16 UTC (permalink / raw) To: Philippe Simons Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Jernej Skrabec, Samuel Holland, open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS, moderated list:ARM/Allwinner sunXi SoC support, open list:ARM/Allwinner sunXi SoC support, open list, Mark Brown On Wed, Dec 4, 2024 at 4:38 AM Philippe Simons <simons.philippe@gmail.com> wrote: > > AXP datasheet says that ramp delay is 15.625 us/step, > which is 10mV in our case. (CC-ing Mark for knowledge on regulators) If this is the property of the PMIC, it probably belongs in the driver, in "regulator_desc.ramp_delay". The "regulator-ramp-delay" in the DT can be used to override this if the board has excessive ramp delay due to other design reasons. ChenYu > add missing regulator-ramp-delay to dcdc regulators accordingly > > Signed-off-by: Philippe Simons <simons.philippe@gmail.com> > --- > .../boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > index 80ccab7b5..b6e76a804 100644 > --- a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > +++ b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > @@ -238,6 +238,7 @@ reg_dcdc1: dcdc1 { > regulator-always-on; > regulator-min-microvolt = <900000>; > regulator-max-microvolt = <1160000>; > + regulator-ramp-delay = <640>; > regulator-name = "vdd-cpu"; > }; > > @@ -245,6 +246,7 @@ reg_dcdc2: dcdc2 { > regulator-always-on; > regulator-min-microvolt = <940000>; > regulator-max-microvolt = <940000>; > + regulator-ramp-delay = <640>; > regulator-name = "vdd-gpu-sys"; > }; > > @@ -252,6 +254,7 @@ reg_dcdc3: dcdc3 { > regulator-always-on; > regulator-min-microvolt = <1100000>; > regulator-max-microvolt = <1100000>; > + regulator-ramp-delay = <640>; > regulator-name = "vdd-dram"; > }; > > -- > 2.47.1 > ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] arm64: dts: allwinner: h616: rg35xx add missing regulator-ramp-delay 2024-12-05 4:16 ` Chen-Yu Tsai @ 2024-12-05 7:26 ` Philippe Simons 2024-12-05 7:39 ` Chen-Yu Tsai 0 siblings, 1 reply; 4+ messages in thread From: Philippe Simons @ 2024-12-05 7:26 UTC (permalink / raw) To: wens Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Jernej Skrabec, Samuel Holland, open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS, moderated list:ARM/Allwinner sunXi SoC support, open list:ARM/Allwinner sunXi SoC support, open list, Mark Brown Ok I can do that, but the driver (axp20x-regulator.c) is using macros to generate these regulator_desc structs. So I have two options, create a new macro with the ramp_delay, or modify the existing macro, using 0 for the regulators I don't know about. Philippe On Thu, Dec 5, 2024 at 5:16 AM Chen-Yu Tsai <wens@csie.org> wrote: > > On Wed, Dec 4, 2024 at 4:38 AM Philippe Simons > <simons.philippe@gmail.com> wrote: > > > > AXP datasheet says that ramp delay is 15.625 us/step, > > which is 10mV in our case. > > (CC-ing Mark for knowledge on regulators) > > If this is the property of the PMIC, it probably belongs in the driver, > in "regulator_desc.ramp_delay". > > The "regulator-ramp-delay" in the DT can be used to override this > if the board has excessive ramp delay due to other design reasons. > > > ChenYu > > > add missing regulator-ramp-delay to dcdc regulators accordingly > > > > Signed-off-by: Philippe Simons <simons.philippe@gmail.com> > > --- > > .../boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > > index 80ccab7b5..b6e76a804 100644 > > --- a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > > +++ b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > > @@ -238,6 +238,7 @@ reg_dcdc1: dcdc1 { > > regulator-always-on; > > regulator-min-microvolt = <900000>; > > regulator-max-microvolt = <1160000>; > > + regulator-ramp-delay = <640>; > > regulator-name = "vdd-cpu"; > > }; > > > > @@ -245,6 +246,7 @@ reg_dcdc2: dcdc2 { > > regulator-always-on; > > regulator-min-microvolt = <940000>; > > regulator-max-microvolt = <940000>; > > + regulator-ramp-delay = <640>; > > regulator-name = "vdd-gpu-sys"; > > }; > > > > @@ -252,6 +254,7 @@ reg_dcdc3: dcdc3 { > > regulator-always-on; > > regulator-min-microvolt = <1100000>; > > regulator-max-microvolt = <1100000>; > > + regulator-ramp-delay = <640>; > > regulator-name = "vdd-dram"; > > }; > > > > -- > > 2.47.1 > > ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] arm64: dts: allwinner: h616: rg35xx add missing regulator-ramp-delay 2024-12-05 7:26 ` Philippe Simons @ 2024-12-05 7:39 ` Chen-Yu Tsai 0 siblings, 0 replies; 4+ messages in thread From: Chen-Yu Tsai @ 2024-12-05 7:39 UTC (permalink / raw) To: Philippe Simons Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Jernej Skrabec, Samuel Holland, open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS, moderated list:ARM/Allwinner sunXi SoC support, open list:ARM/Allwinner sunXi SoC support, open list, Mark Brown On Thu, Dec 5, 2024 at 3:26 PM Philippe Simons <simons.philippe@gmail.com> wrote: Please reply inline. > Ok I can do that, but the driver (axp20x-regulator.c) is using macros > to generate these regulator_desc structs. > > So I have two options, create a new macro with the ramp_delay, or > modify the existing macro, using 0 for the regulators I don't know about. You can add a new macro with the extra ramp_delay argument, and modify the existing macro to expand to that with ramp_delay = 0. ChenYu > Philippe > > On Thu, Dec 5, 2024 at 5:16 AM Chen-Yu Tsai <wens@csie.org> wrote: > > > > On Wed, Dec 4, 2024 at 4:38 AM Philippe Simons > > <simons.philippe@gmail.com> wrote: > > > > > > AXP datasheet says that ramp delay is 15.625 us/step, > > > which is 10mV in our case. > > > > (CC-ing Mark for knowledge on regulators) > > > > If this is the property of the PMIC, it probably belongs in the driver, > > in "regulator_desc.ramp_delay". > > > > The "regulator-ramp-delay" in the DT can be used to override this > > if the board has excessive ramp delay due to other design reasons. > > > > > > ChenYu > > > > > add missing regulator-ramp-delay to dcdc regulators accordingly > > > > > > Signed-off-by: Philippe Simons <simons.philippe@gmail.com> > > > --- > > > .../boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts | 3 +++ > > > 1 file changed, 3 insertions(+) > > > > > > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > > > index 80ccab7b5..b6e76a804 100644 > > > --- a/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > > > +++ b/arch/arm64/boot/dts/allwinner/sun50i-h700-anbernic-rg35xx-2024.dts > > > @@ -238,6 +238,7 @@ reg_dcdc1: dcdc1 { > > > regulator-always-on; > > > regulator-min-microvolt = <900000>; > > > regulator-max-microvolt = <1160000>; > > > + regulator-ramp-delay = <640>; > > > regulator-name = "vdd-cpu"; > > > }; > > > > > > @@ -245,6 +246,7 @@ reg_dcdc2: dcdc2 { > > > regulator-always-on; > > > regulator-min-microvolt = <940000>; > > > regulator-max-microvolt = <940000>; > > > + regulator-ramp-delay = <640>; > > > regulator-name = "vdd-gpu-sys"; > > > }; > > > > > > @@ -252,6 +254,7 @@ reg_dcdc3: dcdc3 { > > > regulator-always-on; > > > regulator-min-microvolt = <1100000>; > > > regulator-max-microvolt = <1100000>; > > > + regulator-ramp-delay = <640>; > > > regulator-name = "vdd-dram"; > > > }; > > > > > > -- > > > 2.47.1 > > > ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-12-05 7:39 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2024-12-03 20:38 [PATCH] arm64: dts: allwinner: h616: rg35xx add missing regulator-ramp-delay Philippe Simons 2024-12-05 4:16 ` Chen-Yu Tsai 2024-12-05 7:26 ` Philippe Simons 2024-12-05 7:39 ` Chen-Yu Tsai
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox