diff mbox

ASoC: omap-mcbsp: Support SND_SOC_DAIFMT_CBM_CFS for omap3/4

Message ID 20130721162400.GA17491@panicking (mailing list archive)
State New, archived
Headers show

Commit Message

Michael Nazzareno Trimarchi July 21, 2013, 4:24 p.m. UTC
Add SND_SOC_DAIFMT_CBM_CFS support for omap3/omap4. The patch was tested on
a pandaboard-es board connected to the pcm1792a codec. mcbspx_fsx must
configured as output and mcbspx_clkx must be configured as input.

Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
---
 sound/soc/omap/omap-mcbsp.c |    5 +++++
 1 file changed, 5 insertions(+)

Comments

Peter Ujfalusi July 21, 2013, 5:25 p.m. UTC | #1
On 07/21/2013 06:24 PM, Michael Trimarchi wrote:
> Add SND_SOC_DAIFMT_CBM_CFS support for omap3/omap4. The patch was tested on
> a pandaboard-es board connected to the pcm1792a codec. mcbspx_fsx must
> configured as output and mcbspx_clkx must be configured as input.

Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>

> 
> Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
> ---
>  sound/soc/omap/omap-mcbsp.c |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
> index 7483efb..6c19bba 100644
> --- a/sound/soc/omap/omap-mcbsp.c
> +++ b/sound/soc/omap/omap-mcbsp.c
> @@ -433,6 +433,11 @@ static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_dai *cpu_dai,
>  		/* Sample rate generator drives the FS */
>  		regs->srgr2	|= FSGM;
>  		break;
> +	case SND_SOC_DAIFMT_CBM_CFS:
> +		/* McBSP slave. FS clock as output */
> +		regs->srgr2	|= FSGM;
> +		regs->pcr0	|= FSXM;
> +		break;
>  	case SND_SOC_DAIFMT_CBM_CFM:
>  		/* McBSP slave */
>  		break;
>
Mark Brown July 21, 2013, 11:58 p.m. UTC | #2
On Sun, Jul 21, 2013 at 06:24:01PM +0200, Michael Trimarchi wrote:
> Add SND_SOC_DAIFMT_CBM_CFS support for omap3/omap4. The patch was tested on
> a pandaboard-es board connected to the pcm1792a codec. mcbspx_fsx must
> configured as output and mcbspx_clkx must be configured as input.

Applied, thanks.
diff mbox

Patch

diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
index 7483efb..6c19bba 100644
--- a/sound/soc/omap/omap-mcbsp.c
+++ b/sound/soc/omap/omap-mcbsp.c
@@ -433,6 +433,11 @@  static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_dai *cpu_dai,
 		/* Sample rate generator drives the FS */
 		regs->srgr2	|= FSGM;
 		break;
+	case SND_SOC_DAIFMT_CBM_CFS:
+		/* McBSP slave. FS clock as output */
+		regs->srgr2	|= FSGM;
+		regs->pcr0	|= FSXM;
+		break;
 	case SND_SOC_DAIFMT_CBM_CFM:
 		/* McBSP slave */
 		break;