[alsa-devel] Handling HDA FIFO error

Clemens Ladisch clemens at ladisch.de
Wed May 15 11:08:55 CEST 2013

Daniel Drake wrote:
> Digging into the HDA code, I can see that normally, when the stream
> gets started, we get interrupts with SD_STS as 0x24. In the failure
> case, as soon as we start the stream, we get a flood of interrupts
> with SD_STS 0x8 - which indicates FIFO error.
> Disabling interrupt generation upon FIFO error does not help much - it
> avoids the flood of interrupts, but doesn't change the fact that audio
> playing apps hang or loop infinitely.
> Are there any things I could check that would explain why a FIFO error
> might be occurring?

Probably a buffer underrun, i.e., the controller did not manage to
read samples from memory fast enough.

> any suggestions for how to improve the hda_intel driver to handle
> FIFO error gracefully? Right now there is no code to handle that.

It should stop the stream, i.e., go into the xrun state.

In theory, the application restarting the stream should reset the DMA
engine enough to make it work again.  But you say this happens also
when starting the stream, so I guess more resetting is needed.


More information about the Alsa-devel mailing list