Re: [PATCH v2 7/7] arm64: dts: allwinner: h6: Enable CPU and GPU opp tables for Orange Pi boards

From: ClÃment PÃron
Date: Mon Apr 06 2020 - 05:10:19 EST


Hi,

On Sun, 5 Apr 2020 at 19:36, ClÃment PÃron <peron.clem@xxxxxxxxx> wrote:
>
> Enable CPU and GPU opp tables for Orange Pi boards.
>
> This needs to change the CPU regulator max voltage to fit
> the OPP table.
>
> Also add the ramp-delay information to avoid any out of spec
> running as the regulator is slower at reaching the voltage
> requested compare to the PLL reaching the frequency.
>
> There is no such information for AXP805 but similar PMIC (AXP813)
> has a DVM (Dynamic Voltage scaling Management) ramp rate equal
> to 2500uV/us.
>
> Signed-off-by: ClÃment PÃron <peron.clem@xxxxxxxxx>
> ---
> arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi | 10 +++++++++-
> 1 file changed, 9 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi
> index 37f4c57597d4..f3ba500ce4c6 100644
> --- a/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi
> +++ b/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi

Made a mistake here.
Ondrej Jirman test DVFS on Orange Pi 3 board which is not this device-tree file.

Will fix in V3.

Regards,
ClÃment

> @@ -5,6 +5,8 @@
> /dts-v1/;
>
> #include "sun50i-h6.dtsi"
> +#include "sun50i-h6-cpu-opp.dtsi"
> +#include "sun50i-h6-gpu-opp.dtsi"
>
> #include <dt-bindings/gpio/gpio.h>
>
> @@ -45,6 +47,10 @@
> };
> };
>
> +&cpu0 {
> + cpu-supply = <&reg_dcdca>;
> +};
> +
> &ehci0 {
> status = "okay";
> };
> @@ -161,7 +167,8 @@
> reg_dcdca: dcdca {
> regulator-always-on;
> regulator-min-microvolt = <810000>;
> - regulator-max-microvolt = <1080000>;
> + regulator-max-microvolt = <1160000>;
> + regulator-ramp-delay = <2500>;
> regulator-name = "vdd-cpu";
> };
>
> @@ -169,6 +176,7 @@
> regulator-enable-ramp-delay = <32000>;
> regulator-min-microvolt = <810000>;
> regulator-max-microvolt = <1080000>;
> + regulator-ramp-delay = <2500>;
> regulator-name = "vdd-gpu";
> };
>
> --
> 2.20.1
>