1 From 5d90603b09e5814ffc38c47e79ccf9bc564f9296 Mon Sep 17 00:00:00 2001
2 From: Daniel Golle <daniel@makrotopia.org>
3 Date: Tue, 30 May 2023 22:12:35 +0200
4 Subject: [PATCH 18/19] arm64: dts: mt7986: add pwm-fan and cooling-maps to
7 Add pwm-fan and cooling-maps to BananaPi-R3 devicetree.
9 Signed-off-by: Daniel Golle <daniel@makrotopia.org>
10 Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
11 Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
12 Link: https://lore.kernel.org/r/20230530201235.22330-5-linux@fw-web.de
13 Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
15 .../dts/mediatek/mt7986a-bananapi-bpi-r3.dts | 31 +++++++++++++++++++
16 1 file changed, 31 insertions(+)
18 --- a/arch/arm64/boot/dts/mediatek/mt7986a-bananapi-bpi-r3.dts
19 +++ b/arch/arm64/boot/dts/mediatek/mt7986a-bananapi-bpi-r3.dts
25 + compatible = "pwm-fan";
26 + #cooling-cells = <2>;
27 + /* cooling level (0, 1, 2) - pwm inverted */
28 + cooling-levels = <255 96 0>;
29 + pwms = <&pwm 0 10000 0>;
34 compatible = "gpio-keys";
43 + /* active: set fan to cooling level 2 */
44 + cooling-device = <&fan 2 2>;
45 + trip = <&cpu_trip_active_high>;
49 + /* active: set fan to cooling level 1 */
50 + cooling-device = <&fan 1 1>;
51 + trip = <&cpu_trip_active_low>;
55 + /* passive: set fan to cooling level 0 */
56 + cooling-device = <&fan 0 0>;
57 + trip = <&cpu_trip_passive>;