[alsa-devel] [PATCH 3/5] ASoC: DaVinci: i2s, reduce underruns by combining into 1 element

Mark Brown broonie at opensource.wolfsonmicro.com
Sat Aug 8 10:59:11 CEST 2009

On Thu, Aug 06, 2009 at 04:55:33PM -0700, Troy Kisky wrote:

> @@ -37,6 +37,12 @@ struct snd_platform_data {
>  	u32 rx_dma_offset;
>  	enum dma_event_q eventq_no;	/* event queue number */
>  	unsigned int codec_fmt;
> +	/*
> +	 * Allowing this is more efficient and eliminates left and right swaps
> +	 * caused by underruns, but will swap the left and right channels
> +	 * when compared to previous behavior.
> +	 */
> +	unsigned disable_channel_combine:1;

It seems rather surprising to have this be enabled by default given that
it does swap the channels - I'd expect it to catch people out and it's
not really obvious that Linux would do something like this and it's not
quite so discoverable as it might be.  On the other hand, it does sound
like a useful performance win though I'm not sure how bad the problems
are in general and if the use of SRAM won't deal with things well

I'll apply the patch, copying the comment here into the commit message
to make things more discoverable, but I'd strongly suggest considering a
followup patch which changes the default to the original behaviour.  It
might even be worth making the behaviour runtime configurable.

More information about the Alsa-devel mailing list