devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Eduardo Valentin <edubezval@gmail.com>
To: Nishanth Menon <nm@ti.com>
Cc: "Tony Lindgren" <tony@atomide.com>,
	"Benoît Cousson" <bcousson@baylibre.com>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org,
	linux-omap@vger.kernel.org, Keerthy <j-keerthy@ti.com>,
	"Tero Kristo" <t-kristo@ti.com>
Subject: Re: [PATCH 3/3] ARM: dts: am57xx-beagle-x15: Add thermal map
Date: Fri, 20 Mar 2015 17:50:22 -0400	[thread overview]
Message-ID: <20150320214959.GB7226@developer.amazonguestwifi.org> (raw)
In-Reply-To: <1426880861-9266-4-git-send-email-nm@ti.com>

[-- Attachment #1: Type: text/plain, Size: 2715 bytes --]

On Fri, Mar 20, 2015 at 02:47:41PM -0500, Nishanth Menon wrote:
> BeagleBoard-X15 has capability for a fan and has an onboard TMP102
> temperature sensor as well. This allows us to create a new thermal
> zone (called, un-imaginatively "board"), and allows us to use some
> active cooling as temperatures start edge upward in the system by
> creating a new alert temperature (emperically 50C) for cpu.
> 
> NOTE: Fan is NOT mounted by default on the platform, in such a case,
> all we end up doing is switch on a regulator and leak very minimal
> current.
> 
> Signed-off-by: Nishanth Menon <nm@ti.com>

Acked-by: Eduardo Valentin <edubezval@gmail.com>

> ---
>  arch/arm/boot/dts/am57xx-beagle-x15.dts |   49 +++++++++++++++++++++++++++++++
>  1 file changed, 49 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/am57xx-beagle-x15.dts b/arch/arm/boot/dts/am57xx-beagle-x15.dts
> index 41642fe770a1..6a3621c23017 100644
> --- a/arch/arm/boot/dts/am57xx-beagle-x15.dts
> +++ b/arch/arm/boot/dts/am57xx-beagle-x15.dts
> @@ -86,6 +86,7 @@
>  		gpios =  <&tps659038_gpio 1 GPIO_ACTIVE_HIGH>;
>  		gpio-fan,speed-map = <0     0>,
>  				     <13000 1>;
> +		#cooling-cells = <2>;
>  	};
>  
>  	extcon_usb1: extcon_usb1 {
> @@ -441,6 +442,7 @@
>  		pinctrl-0 = <&tmp102_pins_default>;
>  		interrupt-parent = <&gpio7>;
>  		interrupts = <16 IRQ_TYPE_LEVEL_LOW>;
> +		#thermal-sensor-cells = <1>;
>  	};
>  };
>  
> @@ -559,3 +561,50 @@
>  &usb2 {
>  	dr_mode = "peripheral";
>  };
> +
> +&cpu_trips {
> +	cpu_alert1: cpu_alert1 {
> +		temperature = <50000>; /* millicelsius */
> +		hysteresis = <2000>; /* millicelsius */
> +		type = "active";
> +	};
> +};
> +
> +&cpu_cooling_maps {
> +	map1 {
> +		trip = <&cpu_alert1>;
> +		cooling-device = <&gpio_fan THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
> +	};
> +};
> +
> +&thermal_zones {
> +	board_thermal: board_thermal {
> +		polling-delay-passive = <1250>; /* milliseconds */
> +		polling-delay = <1500>; /* milliseconds */
> +
> +				/* sensor       ID */
> +		thermal-sensors = <&tmp102     0>;
> +
> +		board_trips: trips {
> +			board_alert0: board_alert {
> +				temperature = <40000>; /* millicelsius */
> +				hysteresis = <2000>; /* millicelsius */
> +				type = "active";
> +			};
> +
> +			board_crit: board_crit {
> +				temperature = <105000>; /* millicelsius */
> +				hysteresis = <0>; /* millicelsius */
> +				type = "critical";
> +			};
> +		};
> +
> +		board_cooling_maps: cooling-maps {
> +			map0 {
> +				trip = <&board_alert0>;
> +				cooling-device =
> +				  <&gpio_fan THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
> +			};
> +		};
> +       };
> +};
> -- 
> 1.7.9.5
> 

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

      reply	other threads:[~2015-03-20 21:50 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-20 19:47 [PATCH 0/3] ARM: omap5/dra7/x15: Thermal dts patches Nishanth Menon
2015-03-20 19:47 ` [PATCH 1/3] ARM: dts: OMAP5+: separate the cpu thermal zone definition from omap4 Nishanth Menon
2015-03-20 21:54   ` Eduardo Valentin
2015-03-23 10:16     ` Tero Kristo
2015-03-23 17:00       ` Nishanth Menon
     [not found] ` <1426880861-9266-1-git-send-email-nm-l0cyMroinI0@public.gmane.org>
2015-03-20 19:47   ` [PATCH 2/3] ARM: dts: DRA7: Add bandgap and related thermal nodes Nishanth Menon
2015-03-20 21:51     ` Eduardo Valentin
2015-03-20 19:47 ` [PATCH 3/3] ARM: dts: am57xx-beagle-x15: Add thermal map Nishanth Menon
2015-03-20 21:50   ` Eduardo Valentin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150320214959.GB7226@developer.amazonguestwifi.org \
    --to=edubezval@gmail.com \
    --cc=bcousson@baylibre.com \
    --cc=devicetree@vger.kernel.org \
    --cc=j-keerthy@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=nm@ti.com \
    --cc=t-kristo@ti.com \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).