1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2/* 3 * Copyright (C) 2025 PHYTEC Messtechnik GmbH 4 * Author: Primoz Fiser <primoz.fiser@norik.com> 5 */ 6 7#include <dt-bindings/pwm/pwm.h> 8#include "imx93-pinfunc.h" 9 10/dts-v1/; 11/plugin/; 12 13&{/} { 14 fan0: pwm-fan { 15 compatible = "pwm-fan"; 16 #cooling-cells = <2>; 17 pinctrl-names = "default"; 18 pinctrl-0 = <&pinctrl_fan>; 19 cooling-levels = <1 90 150 200 255>; 20 pwms = <&tpm6 1 40000 PWM_POLARITY_INVERTED>; 21 }; 22 23 thermal-zones { 24 cpu-thermal { 25 trips { 26 cpu_low: cpu-low { 27 hysteresis = <3000>; 28 temperature = <50000>; 29 type = "active"; 30 }; 31 32 cpu_med: cpu-med { 33 hysteresis = <3000>; 34 temperature = <58000>; 35 type = "active"; 36 }; 37 38 cpu_high: cpu-high { 39 hysteresis = <3000>; 40 temperature = <65000>; 41 type = "active"; 42 }; 43 }; 44 45 cooling-maps { 46 map1 { 47 cooling-device = <&fan0 1 1>; 48 trip = <&cpu_low>; 49 }; 50 51 map2 { 52 cooling-device = <&fan0 2 2>; 53 trip = <&cpu_med>; 54 }; 55 56 map3 { 57 cooling-device = <&fan0 4 4>; 58 trip = <&cpu_high>; 59 }; 60 }; 61 }; 62 }; 63}; 64 65&tpm6 { 66 status = "okay"; 67}; 68 69&iomuxc { 70 pinctrl_fan: fangrp { 71 fsl,pins = < 72 MX93_PAD_GPIO_IO23__TPM6_CH1 0x31e 73 >; 74 }; 75}; 76