Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1426624 > unrolled thread

Re: [PATCH 3/3] iio: st_sensors: Use level interrupts

Started byLinus Walleij <linus.walleij@linaro.org>
First post2016-06-20 16:00 +0200
Last post2016-06-20 16:00 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH 3/3] iio: st_sensors: Use level interrupts Linus Walleij <linus.walleij@linaro.org> - 2016-06-20 16:00 +0200

#1426624 — Re: [PATCH 3/3] iio: st_sensors: Use level interrupts

FromLinus Walleij <linus.walleij@linaro.org>
Date2016-06-20 16:00 +0200
SubjectRe: [PATCH 3/3] iio: st_sensors: Use level interrupts
Message-ID<rM7U6-w3-17@gated-at.bofh.it>
On Fri, May 13, 2016 at 8:43 PM, Crestez Dan Leonard
<leonard.crestez@intel.com> wrote:

> As far as I can tell DRDY for ST sensors behaves as a level rather than
> edge interrupt. Registering for IRQF_TRIGGER_RISING instead of
> IRQF_TRIGGER_HIGH mostly works except when the sampling frequency is
> high enough that new samples come before the new ones are read
> completely. In that case the interrupt line remains high, no more rising
> edges occur and the iio buffer stalls.
>
> Configuring the interrupt as IRQF_TRIGGER_HIGH makes it work as
> expected. This patch makes it so that st_sensors_trigger interrupt
> request code doesn't mangle the request flags into IRQF_TRIGGER_RISING.
>
> Cc: Linus Walleij <linus.walleij@linaro.org>
> Cc: Giuseppe Barba <giuseppe.barba@st.com>
> Cc: Denis Ciocca <denis.ciocca@st.com>
> Signed-off-by: Crestez Dan Leonard <leonard.crestez@intel.com>
> ---
> This is an alternative fix to this patch:
>         https://www.spinics.net/lists/linux-iio/msg24722.html
> [PATCH 2/2 v6] iio: st_sensors: read surplus samples in trigger.

I have incorporated this approach into my patch now: please give
it a spin!

Yours,
Linus Walleij

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web