Re: [PATCH v3 1/2] ASoC: cs35l33: Initial commit of the cs35l33 CODEC driver.

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

 




On Mon, 16 May 2016, Mark Brown wrote:

> On Mon, May 16, 2016 at 10:20:24AM -0500, Paul Handrigan wrote:
> > On Fri, 13 May 2016, Mark Brown wrote:
> > > On Fri, May 13, 2016 at 03:50:28PM -0500, Paul.Handrigan@xxxxxxxxxx wrote:
> 
> > > > +	for (i = 0; i < CS35L33_INT_ATTEMPTS; i++) {
> > > > +		/* ack the irq by reading both status registers */
> 
> > > Why do we need this...?
> 
> > The we need to keep handling the unmasked interrupts until they are
> > all cleared.  We could get another interrupt while handling the first
> > triggered interrupt, but the interrupt line could be de-asserted due to
> > the read-to-clear nature of the interrupt status registers.
> 
> This doesn't follow?  Clear to read shouldn't be affected by reading
> repeatedly, or at least I don't see that helps any problems in a
> non-racy fashion, and the interrupt subsystem will happily call the
> handler again if the interrupt reasserts during handling so new
> interrupts shouldn't be an issue either.  New interrupts are an issue
> for most devices so we really ought to have handling for that in the
> interrupt subsystem if it's needed, or possibly the usage of the
> subsystem needs to change to take advantage of preexisting handling...
> 

After taking a closer look at it, it would make sence to remove the for 
loop.  We will still need to attempt clear the unmasked interrupt status
bits since it may take a few reads to clear those bits.
_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel



[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux