[alsa-devel] [PATCH] ASoC: Automatically set TDM if needed on pxa-ssp and allow frame width override when using TDM.

Daniel Ribeiro drwyrm at gmail.com
Wed Jun 10 16:17:11 CEST 2009

Em Qua, 2009-06-10 às 19:44 +0800, Paul Shen escreveu:
> Seems the frame_width has no  such relations with sampe width, the
> sample width is defined on runtime by the audio files.
> Make a example sample with  paly a often used 16bit sample width
> stereo aduio file.

> When you play 16bit audio sample with  2*16 bit frame ,
>          frame   --|____________|------------------|_____________|---
>          data      --<======>-<======>-<======>-
>          here the datasize should be SSCR0_DataSize(16), the frame size is 32

No, the example above would be DataSize(32), SFRMWDTH(16). (LEFT_J?)

Or it could be DataSize(16) and 2 active TDM Slots.

But the point here is to not use SSCR0_MOD when its not needed
(sample * chn <= 32), we need to support real networked configurations,
set_tdm_slot() should only be called if you are really using network
mode. eg:

set_tdm_slots(3, 2) shouldn't ever be needed.

> also you can play 16bit audio sample with 2*32 frame,
>          frame
> --|_________________________|------------------------------------|____
>          data     --<======>-------------------<======>-------------------<==
>          here the datasize is also DataSize(16), but the frame size is 64.
> Do I misunderstand you?

Sure you can waste bitclocks.. But we should try to only waste bitclocks
when it is really needed, eg for I2S. The patch is not considering I2S

Daniel Ribeiro
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Esta =?ISO-8859-1?Q?=E9?= uma parte de mensagem
 assinada digitalmente
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20090610/c4c1713b/attachment.sig 

More information about the Alsa-devel mailing list