arm64: dts: rockchip: Add support for two PWM fans on helios64
authorUwe Kleine-König <uwe@kleine-koenig.org>
Mon, 10 May 2021 09:06:07 +0000 (11:06 +0200)
committerSalvatore Bonaccorso <carnil@debian.org>
Wed, 31 Jan 2024 21:14:09 +0000 (22:14 +0100)
Origin: https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/patch/?id=271b66414df0b172c936b3cfd1894b7939f84165

On the helios64 board the two connectors P6 and P7 are supposed to
power two fans. Add the corresponding pwm-fan devices.

Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Link: https://lore.kernel.org/r/20210510090607.970145-1-uwe@kleine-koenig.org
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Gbp-Pq: Topic features/arm64
Gbp-Pq: Name arm64-dts-rockchip-Add-support-for-two-PWM-fans-on-h.patch

arch/arm64/boot/dts/rockchip/rk3399-kobol-helios64.dts

index 19485b552bc4b8f0e963a3d3e522f337309dce3f..9d4a0885fd121813e8ff5e0e40cee095490e2f2c 100644 (file)
                #clock-cells = <0>;
        };
 
+       fan1 {
+               /* fan connected to P7 */
+               compatible = "pwm-fan";
+               pwms = <&pwm0 0 40000 0>;
+               cooling-levels = <0 80 170 255>;
+       };
+
+       fan2 {
+               /* fan connected to P6 */
+               compatible = "pwm-fan";
+               pwms = <&pwm1 0 40000 0>;
+               cooling-levels = <0 80 170 255>;
+       };
+
        leds {
                compatible = "gpio-leds";
                pinctrl-names = "default";
        status = "okay";
 };
 
+&pwm0 {
+       /* pwm-fan on P7 */
+       status = "okay";
+};
+
+&pwm1 {
+       /* pwm-fan on P6 */
+       status = "okay";
+};
+
 &sdhci {
        bus-width = <8>;
        mmc-hs200-1_8v;