All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Matt Ranostay <mranostay@gmail.com>
Cc: "Marek Vašut" <marex@denx.de>,
	"linux-iio@vger.kernel.org" <linux-iio@vger.kernel.org>
Subject: Re: Multiple IIO_THRESHOLD events
Date: Sat, 11 Jul 2015 18:58:39 +0100	[thread overview]
Message-ID: <55A1594F.1060204@kernel.org> (raw)
In-Reply-To: <CAKzfze8sGEyU9DgDR4y2p3=5d+9024WgqgVw5fsv4b2XY1HH1g@mail.gmail.com>

On 09/07/15 18:23, Matt Ranostay wrote:
> Hello Jonathan,
> 
> I am currently working on temperature sensor that has multiple trip
> points, and was wondering what would be the correct way to tie this to
> one channel if several events may have the same IIO_EV_DIR_*
> direction.
> 
> low temp trippoint - > IIO_EV_DIR_FALLING
> high temp trippoint -> IIO_EV_DIR_RISING
> critical temp trippoint ->  ?
> 
> Would it make sensor to add functionality to allow iio_event_spec to
> have an .index field so multiple IIO_EV_DIR_RISING could be parsed
> into sysfs entries?
> 
> 
> Thanks,
> 
> Matt
> 
Hi Matt,

The few times this has come up before, the conclusion has been that
the device was actually more suited to have a hwmon driver than an IIO one.
We have had event units capable of being configured for this sort of operation
but have never actually implemented it.

You are quite correct in that we don't have a current way to support
it.  An index field and appropriate extension of the abi is fine.  However
you've also got to find somewhere in the event code to place it.
That's nastier from an ABI change point of view.


  reply	other threads:[~2015-07-11 17:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-09 17:23 Multiple IIO_THRESHOLD events Matt Ranostay
2015-07-11 17:58 ` Jonathan Cameron [this message]
2015-07-13 17:29   ` Matt Ranostay
2015-07-13 20:50     ` Jonathan Cameron
2015-07-16  2:43       ` Matt Ranostay

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=55A1594F.1060204@kernel.org \
    --to=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=marex@denx.de \
    --cc=mranostay@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.