On 02/25/2015 04:38 PM, Nicolin Chen wrote:
On Wed, Feb 25, 2015 at 04:28:52PM +0800, Xuebing Wang wrote:
Thanks. As the mainline kernel supports I2S master mode, would you please tell me which ASoC machine driver actually uses I2S master mode?
fsl-asoc-card.c
Nicolin,
Thanks. I am trying routing aud3 to internal ssi2. Thus in my case: int_port = 2, ext_port = 3, right? Of course, there are int_port-- and ext_port --.
As I am using I2S master mode (ssi2 generates both bit clock and frame sync, thus (dai_fmt & MASK) == SND_SOC_DAIFMT_CBM_CFM. According to iMX6SL reference manual, should TFSEL (bits 30..27) of int_ptcr be IMX_AUDMUX_V2_PTCR_TFSEL(int_port) (note: int_port vs ext_port), rather than the current IMX_AUDMUX_V2_PTCR_TFSEL(ext_port) in file fsl-asoc-card.c?
Thanks again.
The reason I am asking is that I am using I2S master mode, I'd like to reference that machine driver to configure audmux by function imx_audmux_v2_configure_port().
That driver is a general purpose driver for several CODECs supports. If you plan to get your machine driver upstream, you can try that one directly; Otherwise, you can extract the audmux configuration part for your own use.
Nicolin