Re: [PATCH 2/2] iio: inv_mpu6050: Make interrupt optional

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 25, 2021 at 2:11 PM Lars-Peter Clausen <lars@xxxxxxxxxx> wrote:

> The inv_mpu6050 driver requires an interrupt for buffered capture. But non
> buffered reading for measurements works just fine without an interrupt
> connected.
>
> Make the interrupt optional to support this case.
>
> Signed-off-by: Lars-Peter Clausen <lars@xxxxxxxxxx>

Makes sense.
Reviewed-by: Linus Walleij <linus.walleij@xxxxxxxxxx>

> -       result = inv_mpu6050_probe_trigger(indio_dev, irq_type);
> -       if (result) {
> -               dev_err(dev, "trigger probe fail %d\n", result);
> -               return result;
(...)
> +               /*
> +                * The driver currently only supports buffered capture with its
> +                * own trigger. So no IRQ, no trigger, no buffer
> +                */

I bet it can be made to work with e.g. a hrtimer trigger quite easily since we
support raw reading?

Yours,
Linus Walleij



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux