lkml.org 
[lkml]   [2015]   [Jan]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [alsa-devel][PATCH 2/3] ASoC: fsl_sai: Add support for tdm slots operation
On Tue, Jan 20, 2015 at 08:21:19PM +0800, Zidan Wang wrote:
> @@ -369,10 +380,25 @@ static int fsl_sai_hw_params(struct snd_pcm_substream *substream,
> u32 word_width = snd_pcm_format_width(params_format(params));
> u32 val_cr4 = 0, val_cr5 = 0;
> int ret;
> + u32 bclk;
> +
> + if (channels == 1)
> + channels = 2;
> +
> + if (!sai->slots || sai->slots % channels)
> + sai->slots = channels;
> +
> + sai->slots = sai->slots / channels;
> +
> + if (sai->slot_width < word_width || sai->is_dsp_mode)
> + sai->slot_width = word_width;

Could you pls explain a bit what's this overriding for?
Or it might be better to put into a comment.

Nicolin


\
 
 \ /
  Last update: 2015-01-21 19:41    [W:1.244 / U:0.204 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site