[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHp75Vdp12bm+CHWun36b36Sui73zh0_wtY5YhEqVdNy4rUxVA@mail.gmail.com>
Date: Tue, 22 Mar 2022 10:54:53 +0200
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Jagath Jog J <jagathjog1996@...il.com>
Cc: Dan Robertson <dan@...obertson.com>,
Jonathan Cameron <jic23@...nel.org>,
linux-iio <linux-iio@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v1 3/5] iio: accel: bma400: Add triggered buffer support
On Tue, Mar 22, 2022 at 12:21 AM Jagath Jog J <jagathjog1996@...il.com> wrote:
> On Mon, Mar 21, 2022 at 10:39:22AM +0200, Andy Shevchenko wrote:
> > On Sat, Mar 19, 2022 at 8:10 PM Jagath Jog J <jagathjog1996@...il.com> wrote:
First of all, you left many uncommented comments. I assume you agree
with my comments and are going to address them. If it's not the case,
please elaborate.
...
> > > +out:
>
> Just to skip the below "if()" if error occurs in previous regmap read,
> I used this label.
> if (status & BMA400_INT_DRDY_MSK)
> iio_trigger_poll_chained(data->trig);
>
> I will remove the label in next patch
Just return directly.
...
> > A useless label. Moreover this raises a question: why is it okay to
> > always mark IRQ as handled?
> >
> > > + return IRQ_HANDLED;
>
> Since I was not using top-half of the interrupt so I marked IRQ as handled
> even for error case in the handler.
Yes, but why? Isn't it an erroneous state? Does it mean spurious
interrupt? Does it mean interrupt is unserviced?
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists