]>
Commit | Line | Data |
---|---|---|
da5d2fbd JP |
1 | From 44a201df71739a3c5ef3c40e58ebaccfd052d430 Mon Sep 17 00:00:00 2001 |
2 | From: Anand Moon <linux.amoon@gmail.com> | |
3 | Date: Fri, 21 Oct 2022 05:09:03 +0000 | |
4 | Subject: arm64: dts: meson: Enable active coling using gpio-fan on Odroid | |
5 | N2/N2+ | |
6 | ||
7 | Odroid N2/N2+ support active cooling via gpio-fan controller. | |
8 | Add fan controls and tip point for cpu and ddr thermal sensor | |
9 | on this boards. | |
10 | ||
11 | Signed-off-by: Anand Moon <linux.amoon@gmail.com> | |
12 | Link: https://lore.kernel.org/r/20221021050906.1158-1-linux.amoon@gmail.com | |
13 | Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org> | |
14 | --- | |
15 | .../boot/dts/amlogic/meson-g12b-odroid-n2.dtsi | 42 ++++++++++++++++++++++ | |
16 | 1 file changed, 42 insertions(+) | |
17 | ||
18 | diff --git a/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dtsi b/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dtsi | |
19 | index fd3fa82e4c330..667d2b7749244 100644 | |
20 | --- a/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dtsi | |
21 | +++ b/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dtsi | |
22 | @@ -39,6 +39,14 @@ | |
23 | reset-gpios = <&gpio BOOT_12 GPIO_ACTIVE_LOW>; | |
24 | }; | |
25 | ||
26 | + fan: gpio-fan { | |
27 | + compatible = "gpio-fan"; | |
28 | + gpios = <&gpio_ao GPIOAO_10 GPIO_ACTIVE_HIGH>; | |
29 | + /* Using Dummy Speed */ | |
30 | + gpio-fan,speed-map = <0 0>, <1 1>; | |
31 | + #cooling-cells = <2>; | |
32 | + }; | |
33 | + | |
34 | leds { | |
35 | compatible = "gpio-leds"; | |
36 | ||
37 | @@ -410,6 +418,40 @@ | |
38 | clock-latency = <50000>; | |
39 | }; | |
40 | ||
41 | +&cpu_thermal { | |
42 | + trips { | |
43 | + cpu_active: cpu-active { | |
44 | + temperature = <60000>; /* millicelsius */ | |
45 | + hysteresis = <2000>; /* millicelsius */ | |
46 | + type = "active"; | |
47 | + }; | |
48 | + }; | |
49 | + | |
50 | + cooling-maps { | |
51 | + map { | |
52 | + trip = <&cpu_active>; | |
53 | + cooling-device = <&fan THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; | |
54 | + }; | |
55 | + }; | |
56 | +}; | |
57 | + | |
58 | +&ddr_thermal { | |
59 | + trips { | |
60 | + ddr_active: ddr-active { | |
61 | + temperature = <60000>; /* millicelsius */ | |
62 | + hysteresis = <2000>; /* millicelsius */ | |
63 | + type = "active"; | |
64 | + }; | |
65 | + }; | |
66 | + | |
67 | + cooling-maps { | |
68 | + map { | |
69 | + trip = <&ddr_active>; | |
70 | + cooling-device = <&fan THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; | |
71 | + }; | |
72 | + }; | |
73 | +}; | |
74 | + | |
75 | &ext_mdio { | |
76 | external_phy: ethernet-phy@0 { | |
77 | /* Realtek RTL8211F (0x001cc916) */ | |
78 | -- | |
79 | cgit | |
80 |