linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Zhang Rui <rui.zhang@intel.com>
To: Wei Ni <wni@nvidia.com>
Cc: Jean Delvare <khali@linux-fr.org>,
	"R, Durgadoss" <durgadoss.r@intel.com>,
	"Brown, Len" <len.brown@intel.com>,
	"akpm@linux-foundation.org" <akpm@linux-foundation.org>,
	"joe@perches.com" <joe@perches.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-tegra@ger.kernel.org" <linux-tegra@ger.kernel.org>,
	Alex Courbot <acourbot@nvidia.com>
Subject: Re: How to use the generic thermal sysfs.
Date: Wed, 01 Aug 2012 09:02:52 +0800	[thread overview]
Message-ID: <1343782972.1682.489.camel@rui.sh.intel.com> (raw)
In-Reply-To: <1343386122.4042.88.camel@tegra-chromium-2>

On 五, 2012-07-27 at 18:48 +0800, Wei Ni wrote:
> On Fri, 2012-07-27 at 15:39 +0800, Zhang Rui wrote:
> > On 五, 2012-07-27 at 09:30 +0200, Jean Delvare wrote:
> > > On Fri, 27 Jul 2012 10:58:21 +0800, Wei Ni wrote:
> > > > On Fri, 2012-07-27 at 09:21 +0800, Zhang Rui wrote:
> > > > > is it possible to program the sensor at this time, in your own thermal
> > > > > driver?
> > > > 
> > > > Since we are using the generic thermal driver lm90.c, I'm not sure if we
> > > > could program these limits in the generic driver, I think it's better to
> > > > have a generic interface to set the limits, so I wish to add a
> > > > callback .set_limits() in the generic thermal framework.
> > > 
> > > I can confirm that hwmon drivers do not set limits, it is up to
> > > user-space to do it if they want. So if there is a need to do so in the
> > > kernel itself, a proper interface at the generic thermal framework
> > > level seems appropriate.
> > > 
> > oh, setting limits from userspace?
> > I think you can program the senor when writing the trip point?
> > with this patch,
> > http://marc.info/?l=linux-acpi&m=134318814620429&w=2
> 
> Do you mean it can use .set_trip_temp() to set limits when writing the
> trip point? But I think this callback is used to change the trip_temp,
> it could not used to set the limits, in here the limit value is used to
> trigger the interrupt.
> 
yes, you are right. .set_trip_temp does not work.

usually, this is needed to re-program the sensor when the temperature
hits a trip point , right?

can we make use of the thermal_zone_device_ops.notify()?
say we invoke .notify() in thermal_zone_device_update for each trip
point.

thanks,
rui
> > 
> > thanks,
> > rui
> > 
> > 
> 
> 



  reply	other threads:[~2012-08-01  1:01 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-12 10:22 How to use the generic thermal sysfs Wei Ni
2012-07-12 10:54 ` R, Durgadoss
2012-07-13  1:51   ` Zhang Rui
2012-07-13  7:30     ` Wei Ni
2012-07-13  7:41       ` Zhang Rui
2012-07-13  8:11         ` Wei Ni
2012-07-13  9:53           ` Wei Ni
2012-07-26  9:31         ` Wei Ni
2012-07-27  1:21           ` Zhang Rui
2012-07-27  2:58             ` Wei Ni
2012-07-27  7:30               ` Jean Delvare
2012-07-27  7:39                 ` Zhang Rui
2012-07-27 10:48                   ` Wei Ni
2012-08-01  1:02                     ` Zhang Rui [this message]
2012-08-01 11:29                       ` Wei Ni
2012-10-17  7:15         ` How can I get the latest generic thermal framework Wei Ni
2012-10-17  8:36           ` R, Durgadoss
2012-07-13  5:48   ` How to use the generic thermal sysfs Alex Courbot
2012-07-13  5:54     ` R, Durgadoss
2012-07-13  6:08       ` Alex Courbot
2012-07-13  6:10         ` Zhang Rui

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=1343782972.1682.489.camel@rui.sh.intel.com \
    --to=rui.zhang@intel.com \
    --cc=acourbot@nvidia.com \
    --cc=akpm@linux-foundation.org \
    --cc=durgadoss.r@intel.com \
    --cc=joe@perches.com \
    --cc=khali@linux-fr.org \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@ger.kernel.org \
    --cc=wni@nvidia.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).