lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 2 Jan 2015 11:53:00 -0400
From:	Eduardo Valentin <edubezval@...il.com>
To:	Javi Merino <javi.merino@....com>
Cc:	linux-pm@...r.kernel.org, linux-kernel@...r.kernel.org,
	punit.agrawal@....com, broonie@...nel.org,
	Zhang Rui <rui.zhang@...el.com>
Subject: Re: [RFC PATCH v6 9/9] of: thermal: Introduce sustainable power for
 a thermal zone

On Fri, Dec 05, 2014 at 07:04:20PM +0000, Javi Merino wrote:
> From: Punit Agrawal <punit.agrawal@....com>
> 
> Introduce an optional property called, sustainable-power, which
> represents the power (in mW) which the thermal zone can safely
> dissipate.
> 
> If provided the property is parsed and associated with the thermal
> zone via the thermal zone parameters.
> 
> Cc: Zhang Rui <rui.zhang@...el.com>
> Cc: Eduardo Valentin <edubezval@...il.com>
> Signed-off-by: Punit Agrawal <punit.agrawal@....com>
> ---
>  Documentation/devicetree/bindings/thermal/thermal.txt | 4 ++++
>  drivers/thermal/of-thermal.c                          | 4 ++++
>  2 files changed, 8 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/thermal/thermal.txt b/Documentation/devicetree/bindings/thermal/thermal.txt
> index f5db6b72a36f..c6eb9a8d2aed 100644
> --- a/Documentation/devicetree/bindings/thermal/thermal.txt
> +++ b/Documentation/devicetree/bindings/thermal/thermal.txt
> @@ -167,6 +167,10 @@ Optional property:
>  			by means of sensor ID. Additional coefficients are
>  			interpreted as constant offset.
>  
> +- sustainable-power:	An estimate of the sustainable power (in mW) that the
> +  Type: unsigned	thermal zone can dissipate.
> +  Size: one cell
> +

Please, include examples of this property, as you mentioned in the
governor documentation.

>  Note: The delay properties are bound to the maximum dT/dt (temperature
>  derivative over time) in two situations for a thermal zone:
>  (i)  - when passive cooling is activated (polling-delay-passive); and
> diff --git a/drivers/thermal/of-thermal.c b/drivers/thermal/of-thermal.c
> index 62143ba31001..e032b9bf4085 100644
> --- a/drivers/thermal/of-thermal.c
> +++ b/drivers/thermal/of-thermal.c
> @@ -794,6 +794,7 @@ int __init of_parse_thermal_zones(void)
>  	for_each_child_of_node(np, child) {
>  		struct thermal_zone_device *zone;
>  		struct thermal_zone_params *tzp;
> +		u32 prop;
>  
>  		/* Check whether child is enabled or not */
>  		if (!of_device_is_available(child))
> @@ -820,6 +821,9 @@ int __init of_parse_thermal_zones(void)
>  		/* No hwmon because there might be hwmon drivers registering */
>  		tzp->no_hwmon = true;
>  
> +		if (!of_property_read_u32(child, "sustainable-power", &prop))
> +			tzp->sustainable_power = prop;
> +
>  		zone = thermal_zone_device_register(child->name, tz->ntrips,
>  						    0, tz,
>  						    ops, tzp,
> -- 
> 1.9.1
> 
> 

Download attachment "signature.asc" of type "application/pgp-signature" (474 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ