ARM64: dts: gru: fix up the pwm regulator node
authorDouglas Anderson <dianders@chromium.org>
Fri, 1 Apr 2016 20:48:41 +0000 (13:48 -0700)
committerCaesar Wang <wxt@rock-chips.com>
Thu, 7 Apr 2016 13:49:51 +0000 (21:49 +0800)
This attempts to model commit 063e65397a89 ("ARM64: dts: rk3399-tb: fix
up the pwm regulator node").

Note that instead of putting a duty cycle of 25000 ns (40 kHz) I've set
a duty cycle of 1667 ns (600 kHz) because I think that's what the TRM
says.

Change-Id: Ifc209eddb20122feec96c5e86f7a14da7d74eb3f
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Caesar Wang <wxt@rock-chips.com>
arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi

index 06c9496297f4c2e890f2f46e67ec8ca0bd9e4415..d53e77b5774b9836049a6959a262b9f8ca579603 100644 (file)
                regulator-name = "ppvar_bigcpu";
                status = "okay";
 
-               pwms = <&pwm1 0 1000>;  // TODO: schematics say "FSW 600KHz".  Change these???
+               // TODO: schematics say 600kHz so period of 1667 ns
+               // Rockchip has 25000 (40kHz) for these though.
+               pwms = <&pwm1 0 1667 0>;
 
                // TODO: where's the mapping of duty cycle to voltage???
                // TODO: we probably need in-flight PWM regulator series?
 
                /* EC turns on w/ ap_core_en; always on for AP */
                regulator-always-on;
+               regulator-boot-on;
 
                regulator-min-microvolt = <800000>;
                regulator-max-microvolt = <1500000>;
                regulator-name = "ppvar_litcpu";
                status = "okay";
 
-               pwms = <&pwm2 0 1000>;
+               // TODO: schematics say 600kHz so period of 1667 ns
+               // Rockchip has 25000 (40kHz) for these though.
+               pwms = <&pwm2 0 1667 0>;
 
                /* EC turns on w/ ap_core_en; always on for AP */
                regulator-always-on;
+               regulator-boot-on;
 
                regulator-min-microvolt = <800000>;
                regulator-max-microvolt = <1500000>;
                regulator-name = "ppvar_gpu";
                status = "okay";
 
-               pwms = <&pwm0 0 1000>;
+               // TODO: schematics say 600kHz so period of 1667 ns
+               // Rockchip has 25000 (40kHz) for these though.
+               pwms = <&pwm0 0 1667 0>;
 
                /* EC turns on w/ ap_core_en; always on for AP */
                regulator-always-on;
+               regulator-boot-on;
 
                regulator-min-microvolt = <800000>;
                regulator-max-microvolt = <1500000>;
                regulator-name = "ppvar_centerlogic";
                status = "okay";
 
-               pwms = <&pwm3 0 1000>;
+               // TODO: schematics say 600kHz so period of 1667 ns
+               // Rockchip has 25000 (40kHz) for these though.
+               pwms = <&pwm3 0 1667 0>;
 
                /* EC turns on w/ ppvar_centerlogic_en; always on for AP */
                regulator-always-on;
+               regulator-boot-on;
 
                regulator-min-microvolt = <800000>;
                regulator-max-microvolt = <1500000>;