diff mbox series

[1/2] arm64: tegra: Add pwm-fan profile settings

Message ID 1587130362-6149-1-git-send-email-spatra@nvidia.com
State New
Headers show
Series [1/2] arm64: tegra: Add pwm-fan profile settings | expand

Commit Message

Sandipan Patra April 17, 2020, 1:32 p.m. UTC
Add support for profiles in device tree to allow
different fan settings for trip point temp/hyst/pwm.

Signed-off-by: Sandipan Patra <spatra@nvidia.com>
---
 arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

Comments

Sandipan Patra May 4, 2020, 7:12 a.m. UTC | #1
Gentle reminder.

> -----Original Message-----
> From: Sandipan Patra <spatra@nvidia.com>
> Sent: Friday, April 17, 2020 7:03 PM
> To: Thierry Reding <treding@nvidia.com>; robh+dt@kernel.org; u.kleine-
> koenig@pengutronix.de; Jonathan Hunter <jonathanh@nvidia.com>
> Cc: Bibek Basu <bbasu@nvidia.com>; Bitan Biswas <bbiswas@nvidia.com>;
> linux-pwm@vger.kernel.org; devicetree@vger.kernel.org; linux-
> tegra@vger.kernel.org; linux-kernel@vger.kernel.org; Sandipan Patra
> <spatra@nvidia.com>
> Subject: [PATCH 1/2] arm64: tegra: Add pwm-fan profile settings
> 
> Add support for profiles in device tree to allow different fan settings for trip
> point temp/hyst/pwm.
> 
> Signed-off-by: Sandipan Patra <spatra@nvidia.com>
> ---
>  arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts | 15 ++++++++++++---
>  1 file changed, 12 insertions(+), 3 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts
> b/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts
> index e15d1ea..ff2b980 100644
> --- a/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts
> +++ b/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts
> @@ -219,10 +219,19 @@
> 
>  	fan: fan {
>  		compatible = "pwm-fan";
> -		pwms = <&pwm4 0 45334>;
> -
> -		cooling-levels = <0 64 128 255>;
>  		#cooling-cells = <2>;
> +		pwms = <&pwm4 0 45334>;
> +		profiles {
> +			default = "quiet";
> +			quiet {
> +				state_cap = <4>;
> +				cooling-levels = <0 77 120 160 255 255 255 255
> 255 255>;
> +			};
> +			cool {
> +				state_cap = <4>;
> +				cooling-levels = <0 77 120 160 255 255 255 255
> 255 255>;
> +			};
> +		};
>  	};
> 
>  	gpio-keys {
> --
> 2.7.4
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts b/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts
index e15d1ea..ff2b980 100644
--- a/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts
+++ b/arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts
@@ -219,10 +219,19 @@ 
 
 	fan: fan {
 		compatible = "pwm-fan";
-		pwms = <&pwm4 0 45334>;
-
-		cooling-levels = <0 64 128 255>;
 		#cooling-cells = <2>;
+		pwms = <&pwm4 0 45334>;
+		profiles {
+			default = "quiet";
+			quiet {
+				state_cap = <4>;
+				cooling-levels = <0 77 120 160 255 255 255 255 255 255>;
+			};
+			cool {
+				state_cap = <4>;
+				cooling-levels = <0 77 120 160 255 255 255 255 255 255>;
+			};
+		};
 	};
 
 	gpio-keys {