[alsa-devel] [PATCH] ALSA: pcm - introduce soc_delay

Jassi Brar jaswinder.singh at linaro.org
Mon Jul 23 12:50:33 CEST 2012

On 23 July 2012 16:09, Vinod Koul <vinod.koul at linux.intel.com> wrote:
> On Mon, 2012-07-23 at 15:49 +0530, Jassi Brar wrote:
>> On Mon, Jul 23, 2012 at 3:36 PM, Vinod Koul <vinod.koul at linux.intel.com> wrote:
>> > In many modern SoCs the audio DSP can buffer the PCM ring buffer data. Today we
>> > have no means to represent this buffering and ALSA wrongly detects an overrun
>> > when hw_ptr reaches app_ptr value, though DSP may still have some buffered data.
>> >
>> > This patch tries to add a new field "soc_delay" to represent buffering done in
>> > DSPs. This value is also used for the xrun calculations in ALSA.
>> >
>> Couldn't we employ snd_pcm_hw_params.fifo_size for the purpose ?
> Nope, that should be used to represent the delay in samples being output
> not the sample which are buffered and processed in a DSP
After leaving alsa ring buffer, don't the samples incur extra delay of
your internal  buffer ?

More information about the Alsa-devel mailing list