[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20160415093535.GD3217@sirena.org.uk>
Date: Fri, 15 Apr 2016 10:35:35 +0100
From: Mark Brown <broonie@...nel.org>
To: Purna Chandra Mandal <purna.mandal@...rochip.com>
Cc: linux-kernel@...r.kernel.org, linux-spi@...r.kernel.org
Subject: Re: [PATCH v2 2/2] spi: pic32-sqi: add SPI driver for PIC32 SQI
controller.
On Fri, Apr 15, 2016 at 11:59:55AM +0530, Purna Chandra Mandal wrote:
> On 04/14/2016 11:25 AM, Mark Brown wrote:
> > On Wed, Apr 13, 2016 at 06:52:58PM +0530, Purna Chandra Mandal wrote:
> >> + enable = readl(sqi->regs + PESQI_INT_ENABLE_REG);
> >> + status = readl(sqi->regs + PESQI_INT_STAT_REG);
> >> + if (!status)
> >> + return IRQ_NONE;
> > For robustness the check should be if there was anything handled, not if
> > there was anything set.
> In PESQI controller INT_STAT_REG specifies interrupting reason(s) as usual,
> but mostly to confirm completion of on-going DMA operation. It is sticky,
> no way to acknowledge the interrupt source except masking the source.
> In short, whole interrupt logic is mere extension of status polling logic.
> And in driver isr logic is completely depended on the INT_STAT_REG; if status
> is zero no handling can be done and is unexpected!
That's fine, if something goes wrong there's error handling in genirq
which will notice that the interrupt is screaming and disable it.
Download attachment "signature.asc" of type "application/pgp-signature" (474 bytes)
Powered by blists - more mailing lists