arm64: tegra: Enable PWM fan on the Jetson TX2 Devkit

This is based on the existing configuration of the Jetson TX2 NX devkit.
The fan and thermal characteristics of the two devkits are similar, so
using the same configuration.

Signed-off-by: Aaron Kling <webgeek1234@gmail.com>
This commit is contained in:
Aaron Kling
2025-04-26 16:54:58 -05:00
committed by Thomas Makin
parent d904038ff4
commit a6c8c18494

View File

@@ -2415,6 +2415,10 @@
}; };
}; };
pwm@c340000 {
status = "okay";
};
pcie@10003000 { pcie@10003000 {
status = "okay"; status = "okay";
@@ -2514,6 +2518,16 @@
}; };
}; };
fan: pwm-fan {
compatible = "pwm-fan";
pwms = <&pwm4 0 45334>;
fan-supply = <&vdd_fan>;
/* cooling level (0, 1, 2, 3) - pwm inverted */
cooling-levels = <255 128 64 0>;
#cooling-cells = <2>;
};
vdd_sd: regulator-vdd-sd { vdd_sd: regulator-vdd-sd {
compatible = "regulator-fixed"; compatible = "regulator-fixed";
regulator-name = "SD_CARD_SW_PWR"; regulator-name = "SD_CARD_SW_PWR";
@@ -2562,6 +2576,17 @@
vin-supply = <&vdd_5v0_sys>; vin-supply = <&vdd_5v0_sys>;
}; };
vdd_fan: regulator-vdd-fan {
compatible = "regulator-fixed";
regulator-name = "VDD_FAN";
regulator-min-microvolt = <5000000>;
regulator-max-microvolt = <5000000>;
gpio = <&exp1 4 GPIO_ACTIVE_LOW>;
vin-supply = <&vdd_5v0_sys>;
};
sound { sound {
compatible = "nvidia,tegra186-audio-graph-card"; compatible = "nvidia,tegra186-audio-graph-card";
status = "okay"; status = "okay";
@@ -2627,4 +2652,88 @@
label = "NVIDIA Jetson TX2 APE"; label = "NVIDIA Jetson TX2 APE";
}; };
thermal-zones {
cpu-thermal {
polling-delay = <0>;
polling-delay-passive = <500>;
status = "okay";
trips {
cpu_trip_critical: critical {
temperature = <96500>;
hysteresis = <0>;
type = "critical";
};
cpu_trip_hot: hot {
temperature = <79000>;
hysteresis = <2000>;
type = "hot";
};
cpu_trip_active: active {
temperature = <62000>;
hysteresis = <2000>;
type = "active";
};
cpu_trip_passive: passive {
temperature = <45000>;
hysteresis = <2000>;
type = "passive";
};
};
cooling-maps {
map0 {
cooling-device = <&fan 3 3>;
trip = <&cpu_trip_critical>;
};
map1 {
cooling-device = <&fan 2 2>;
trip = <&cpu_trip_hot>;
};
map2 {
cooling-device = <&fan 1 1>;
trip = <&cpu_trip_active>;
};
map3 {
cooling-device = <&fan 0 0>;
trip = <&cpu_trip_passive>;
};
};
};
aux-thermal {
polling-delay = <0>;
polling-delay-passive = <500>;
status = "okay";
trips {
aux_alert0: critical {
temperature = <90000>;
hysteresis = <0>;
type = "critical";
};
};
};
gpu-thermal {
polling-delay = <0>;
polling-delay-passive = <500>;
status = "okay";
trips {
gpu_alert0: critical {
temperature = <99000>;
hysteresis = <0>;
type = "critical";
};
};
};
};
}; };