All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
@ 2008-09-29  9:50 Arun KS
  2008-09-29 11:06 ` Mark Brown
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Arun KS @ 2008-09-29  9:50 UTC (permalink / raw)
  To: linux-omap@vger.kernel.org List, alsa-devel; +Cc: Jarkko Nikula, felipe.balbi

Enables DSP DAI format for mcbsp in omap platform driver

Signed-off-by: Arun KS <arunks@mistralsolutions.com>
---
 sound/soc/omap/omap-mcbsp.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
index 3a4cc4b..1c024aa 100644
--- a/sound/soc/omap/omap-mcbsp.c
+++ b/sound/soc/omap/omap-mcbsp.c
@@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
snd_soc_dai *cpu_dai,
 		regs->rcr2	|= RDATDLY(1);
 		regs->xcr2	|= XDATDLY(1);
 		break;
+	case SND_SOC_DAIFMT_DSP_A:
+		/* 0-bit data delay */
+		regs->rcr2	|= RDATDLY(0);
+		regs->xcr2	|= XDATDLY(0);
+		break;
+
 	default:
 		/* Unsupported data format */
 		return -EINVAL;
-- 
1.5.3.4

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
@ 2008-09-29  9:50 Arun KS
  0 siblings, 0 replies; 11+ messages in thread
From: Arun KS @ 2008-09-29  9:50 UTC (permalink / raw)
  To: alsa-devel; +Cc: felipe.balbi, Jarkko Nikula

Enables DSP DAI format for mcbsp in omap platform driver

Signed-off-by: Arun KS <arunks@mistralsolutions.com>
---
 sound/soc/omap/omap-mcbsp.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
index 3a4cc4b..1c024aa 100644
--- a/sound/soc/omap/omap-mcbsp.c
+++ b/sound/soc/omap/omap-mcbsp.c
@@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
snd_soc_dai *cpu_dai,
 		regs->rcr2	|= RDATDLY(1);
 		regs->xcr2	|= XDATDLY(1);
 		break;
+	case SND_SOC_DAIFMT_DSP_A:
+		/* 0-bit data delay */
+		regs->rcr2	|= RDATDLY(0);
+		regs->xcr2	|= XDATDLY(0);
+		break;
+
 	default:
 		/* Unsupported data format */
 		return -EINVAL;
-- 
1.5.3.4

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-29  9:50 [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver Arun KS
@ 2008-09-29 11:06 ` Mark Brown
  2008-09-29 11:15 ` Jarkko Nikula
  2008-09-29 11:15 ` Jarkko Nikula
  2 siblings, 0 replies; 11+ messages in thread
From: Mark Brown @ 2008-09-29 11:06 UTC (permalink / raw)
  To: Arun KS; +Cc: alsa-devel, Jarkko Nikula, felipe.balbi

On Mon, Sep 29, 2008 at 03:20:12PM +0530, Arun KS wrote:
> Enables DSP DAI format for mcbsp in omap platform driver

> Signed-off-by: Arun KS <arunks@mistralsolutions.com>

Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>

Thanks!

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-29  9:50 [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver Arun KS
  2008-09-29 11:06 ` Mark Brown
  2008-09-29 11:15 ` Jarkko Nikula
@ 2008-09-29 11:15 ` Jarkko Nikula
  2 siblings, 0 replies; 11+ messages in thread
From: Jarkko Nikula @ 2008-09-29 11:15 UTC (permalink / raw)
  To: alsa-devel; +Cc: felipe.balbi, linux-omap@vger.kernel.org List, alsa-devel

On Mon, 29 Sep 2008 15:20:12 +0530
"ext Arun KS" <arunks@mistralsolutions.com> wrote:

> Enables DSP DAI format for mcbsp in omap platform driver
> 
> Signed-off-by: Arun KS <arunks@mistralsolutions.com>
> ---
>  sound/soc/omap/omap-mcbsp.c |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
> index 3a4cc4b..1c024aa 100644
> --- a/sound/soc/omap/omap-mcbsp.c
> +++ b/sound/soc/omap/omap-mcbsp.c
> @@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
> snd_soc_dai *cpu_dai,
>  		regs->rcr2	|= RDATDLY(1);
>  		regs->xcr2	|= XDATDLY(1);
>  		break;
> +	case SND_SOC_DAIFMT_DSP_A:
> +		/* 0-bit data delay */
> +		regs->rcr2	|= RDATDLY(0);
> +		regs->xcr2	|= XDATDLY(0);
> +		break;
> +
>  	default:

I think this is not enough. The word clock length equals to one BCLK
cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.


Jarkko

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-29  9:50 [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver Arun KS
  2008-09-29 11:06 ` Mark Brown
@ 2008-09-29 11:15 ` Jarkko Nikula
  2008-09-29 12:54   ` Arun KS
                     ` (3 more replies)
  2008-09-29 11:15 ` Jarkko Nikula
  2 siblings, 4 replies; 11+ messages in thread
From: Jarkko Nikula @ 2008-09-29 11:15 UTC (permalink / raw)
  To: ext Arun KS; +Cc: linux-omap@vger.kernel.org List, alsa-devel, felipe.balbi

On Mon, 29 Sep 2008 15:20:12 +0530
"ext Arun KS" <arunks@mistralsolutions.com> wrote:

> Enables DSP DAI format for mcbsp in omap platform driver
> 
> Signed-off-by: Arun KS <arunks@mistralsolutions.com>
> ---
>  sound/soc/omap/omap-mcbsp.c |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
> index 3a4cc4b..1c024aa 100644
> --- a/sound/soc/omap/omap-mcbsp.c
> +++ b/sound/soc/omap/omap-mcbsp.c
> @@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
> snd_soc_dai *cpu_dai,
>  		regs->rcr2	|= RDATDLY(1);
>  		regs->xcr2	|= XDATDLY(1);
>  		break;
> +	case SND_SOC_DAIFMT_DSP_A:
> +		/* 0-bit data delay */
> +		regs->rcr2	|= RDATDLY(0);
> +		regs->xcr2	|= XDATDLY(0);
> +		break;
> +
>  	default:

I think this is not enough. The word clock length equals to one BCLK
cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.


Jarkko

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-29 11:15 ` Jarkko Nikula
@ 2008-09-29 12:54   ` Arun KS
  2008-09-29 12:54   ` Arun KS
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 11+ messages in thread
From: Arun KS @ 2008-09-29 12:54 UTC (permalink / raw)
  To: alsa-devel; +Cc: felipe.balbi, linux-omap@vger.kernel.org List, alsa-devel

Thanks all for the comments.
I will incorporate and send the patches again.

On Mon, Sep 29, 2008 at 4:45 PM, Jarkko Nikula <jarkko.nikula@nokia.com> wrote:
> On Mon, 29 Sep 2008 15:20:12 +0530
> "ext Arun KS" <arunks@mistralsolutions.com> wrote:
>
>> Enables DSP DAI format for mcbsp in omap platform driver
>>
>> Signed-off-by: Arun KS <arunks@mistralsolutions.com>
>> ---
>>  sound/soc/omap/omap-mcbsp.c |    6 ++++++
>>  1 files changed, 6 insertions(+), 0 deletions(-)
>>
>> diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
>> index 3a4cc4b..1c024aa 100644
>> --- a/sound/soc/omap/omap-mcbsp.c
>> +++ b/sound/soc/omap/omap-mcbsp.c
>> @@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
>> snd_soc_dai *cpu_dai,
>>               regs->rcr2      |= RDATDLY(1);
>>               regs->xcr2      |= XDATDLY(1);
>>               break;
>> +     case SND_SOC_DAIFMT_DSP_A:
>> +             /* 0-bit data delay */
>> +             regs->rcr2      |= RDATDLY(0);
>> +             regs->xcr2      |= XDATDLY(0);
>> +             break;
>> +
>>       default:
>
> I think this is not enough. The word clock length equals to one BCLK
> cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.
>
>
> Jarkko
> --
> To unsubscribe from this list: send the line "unsubscribe alsa-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-29 11:15 ` Jarkko Nikula
  2008-09-29 12:54   ` Arun KS
@ 2008-09-29 12:54   ` Arun KS
  2008-09-30  6:41   ` Arun KS
  2008-09-30  6:41   ` Arun KS
  3 siblings, 0 replies; 11+ messages in thread
From: Arun KS @ 2008-09-29 12:54 UTC (permalink / raw)
  To: Jarkko Nikula; +Cc: linux-omap@vger.kernel.org List, alsa-devel, felipe.balbi

Thanks all for the comments.
I will incorporate and send the patches again.

On Mon, Sep 29, 2008 at 4:45 PM, Jarkko Nikula <jarkko.nikula@nokia.com> wrote:
> On Mon, 29 Sep 2008 15:20:12 +0530
> "ext Arun KS" <arunks@mistralsolutions.com> wrote:
>
>> Enables DSP DAI format for mcbsp in omap platform driver
>>
>> Signed-off-by: Arun KS <arunks@mistralsolutions.com>
>> ---
>>  sound/soc/omap/omap-mcbsp.c |    6 ++++++
>>  1 files changed, 6 insertions(+), 0 deletions(-)
>>
>> diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
>> index 3a4cc4b..1c024aa 100644
>> --- a/sound/soc/omap/omap-mcbsp.c
>> +++ b/sound/soc/omap/omap-mcbsp.c
>> @@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
>> snd_soc_dai *cpu_dai,
>>               regs->rcr2      |= RDATDLY(1);
>>               regs->xcr2      |= XDATDLY(1);
>>               break;
>> +     case SND_SOC_DAIFMT_DSP_A:
>> +             /* 0-bit data delay */
>> +             regs->rcr2      |= RDATDLY(0);
>> +             regs->xcr2      |= XDATDLY(0);
>> +             break;
>> +
>>       default:
>
> I think this is not enough. The word clock length equals to one BCLK
> cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.
>
>
> Jarkko
> --
> To unsubscribe from this list: send the line "unsubscribe alsa-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-29 11:15 ` Jarkko Nikula
                     ` (2 preceding siblings ...)
  2008-09-30  6:41   ` Arun KS
@ 2008-09-30  6:41   ` Arun KS
  3 siblings, 0 replies; 11+ messages in thread
From: Arun KS @ 2008-09-30  6:41 UTC (permalink / raw)
  To: alsa-devel; +Cc: felipe.balbi, linux-omap@vger.kernel.org List, alsa-devel

On Mon, Sep 29, 2008 at 4:45 PM, Jarkko Nikula <jarkko.nikula@nokia.com> wrote:
> On Mon, 29 Sep 2008 15:20:12 +0530
> "ext Arun KS" <arunks@mistralsolutions.com> wrote:
>
>> Enables DSP DAI format for mcbsp in omap platform driver
>>
>> Signed-off-by: Arun KS <arunks@mistralsolutions.com>
>> ---
>>  sound/soc/omap/omap-mcbsp.c |    6 ++++++
>>  1 files changed, 6 insertions(+), 0 deletions(-)
>>
>> diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
>> index 3a4cc4b..1c024aa 100644
>> --- a/sound/soc/omap/omap-mcbsp.c
>> +++ b/sound/soc/omap/omap-mcbsp.c
>> @@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
>> snd_soc_dai *cpu_dai,
>>               regs->rcr2      |= RDATDLY(1);
>>               regs->xcr2      |= XDATDLY(1);
>>               break;
>> +     case SND_SOC_DAIFMT_DSP_A:
>> +             /* 0-bit data delay */
>> +             regs->rcr2      |= RDATDLY(0);
>> +             regs->xcr2      |= XDATDLY(0);
>> +             break;
>> +
>>       default:
>
> I think this is not enough. The word clock length equals to one BCLK
> cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.
>

In DSP Mode, Frame sync is followed by two data words.
I tested this patch and its working. Am i missing something ?

>
> Jarkko
> --
> To unsubscribe from this list: send the line "unsubscribe alsa-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-29 11:15 ` Jarkko Nikula
  2008-09-29 12:54   ` Arun KS
  2008-09-29 12:54   ` Arun KS
@ 2008-09-30  6:41   ` Arun KS
  2008-09-30 13:11     ` Jarkko Nikula
  2008-09-30 13:11     ` Jarkko Nikula
  2008-09-30  6:41   ` Arun KS
  3 siblings, 2 replies; 11+ messages in thread
From: Arun KS @ 2008-09-30  6:41 UTC (permalink / raw)
  To: Jarkko Nikula; +Cc: linux-omap@vger.kernel.org List, alsa-devel, felipe.balbi

On Mon, Sep 29, 2008 at 4:45 PM, Jarkko Nikula <jarkko.nikula@nokia.com> wrote:
> On Mon, 29 Sep 2008 15:20:12 +0530
> "ext Arun KS" <arunks@mistralsolutions.com> wrote:
>
>> Enables DSP DAI format for mcbsp in omap platform driver
>>
>> Signed-off-by: Arun KS <arunks@mistralsolutions.com>
>> ---
>>  sound/soc/omap/omap-mcbsp.c |    6 ++++++
>>  1 files changed, 6 insertions(+), 0 deletions(-)
>>
>> diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
>> index 3a4cc4b..1c024aa 100644
>> --- a/sound/soc/omap/omap-mcbsp.c
>> +++ b/sound/soc/omap/omap-mcbsp.c
>> @@ -292,6 +292,12 @@ static int omap_mcbsp_dai_set_dai_fmt(struct
>> snd_soc_dai *cpu_dai,
>>               regs->rcr2      |= RDATDLY(1);
>>               regs->xcr2      |= XDATDLY(1);
>>               break;
>> +     case SND_SOC_DAIFMT_DSP_A:
>> +             /* 0-bit data delay */
>> +             regs->rcr2      |= RDATDLY(0);
>> +             regs->xcr2      |= XDATDLY(0);
>> +             break;
>> +
>>       default:
>
> I think this is not enough. The word clock length equals to one BCLK
> cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.
>

In DSP Mode, Frame sync is followed by two data words.
I tested this patch and its working. Am i missing something ?

>
> Jarkko
> --
> To unsubscribe from this list: send the line "unsubscribe alsa-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-30  6:41   ` Arun KS
@ 2008-09-30 13:11     ` Jarkko Nikula
  2008-09-30 13:11     ` Jarkko Nikula
  1 sibling, 0 replies; 11+ messages in thread
From: Jarkko Nikula @ 2008-09-30 13:11 UTC (permalink / raw)
  To: alsa-devel; +Cc: felipe.balbi, linux-omap@vger.kernel.org List, alsa-devel

On Tue, 30 Sep 2008 12:11:45 +0530
"ext Arun KS" <arunks@mistralsolutions.com> wrote:

> > I think this is not enough. The word clock length equals to one BCLK
> > cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.
> >
> 
> In DSP Mode, Frame sync is followed by two data words.
> I tested this patch and its working. Am i missing something ?
> 
I meant length of FS/LRC[IN | OUT] signal itself. E.g. see figures 3-7
and 3-8 in AIC23 data manual:

http://www.ti.com/lit/gpn/tlv320aic23

Now omap-mcbsp.c sets this FS length to 16 BCLK periods in
omap_mcbsp_dai_hw_params. Currently code is pretty much tailored for
16-bit stereo I2S so probably some McBSP configuration bits are better
set in another function than currently :-)


Jarkko

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver
  2008-09-30  6:41   ` Arun KS
  2008-09-30 13:11     ` Jarkko Nikula
@ 2008-09-30 13:11     ` Jarkko Nikula
  1 sibling, 0 replies; 11+ messages in thread
From: Jarkko Nikula @ 2008-09-30 13:11 UTC (permalink / raw)
  To: ext Arun KS; +Cc: linux-omap@vger.kernel.org List, alsa-devel, felipe.balbi

On Tue, 30 Sep 2008 12:11:45 +0530
"ext Arun KS" <arunks@mistralsolutions.com> wrote:

> > I think this is not enough. The word clock length equals to one BCLK
> > cycle in DSP mode. Not n channel bit BCLK cycles like in I2S.
> >
> 
> In DSP Mode, Frame sync is followed by two data words.
> I tested this patch and its working. Am i missing something ?
> 
I meant length of FS/LRC[IN | OUT] signal itself. E.g. see figures 3-7
and 3-8 in AIC23 data manual:

http://www.ti.com/lit/gpn/tlv320aic23

Now omap-mcbsp.c sets this FS length to 16 BCLK periods in
omap_mcbsp_dai_hw_params. Currently code is pretty much tailored for
16-bit stereo I2S so probably some McBSP configuration bits are better
set in another function than currently :-)


Jarkko

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2008-09-30 13:12 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-29  9:50 [PATCH 3/5] [RFC] ALSA ASOC Adds DSP DAI format support for platform driver Arun KS
2008-09-29 11:06 ` Mark Brown
2008-09-29 11:15 ` Jarkko Nikula
2008-09-29 12:54   ` Arun KS
2008-09-29 12:54   ` Arun KS
2008-09-30  6:41   ` Arun KS
2008-09-30 13:11     ` Jarkko Nikula
2008-09-30 13:11     ` Jarkko Nikula
2008-09-30  6:41   ` Arun KS
2008-09-29 11:15 ` Jarkko Nikula
  -- strict thread matches above, loose matches on Subject: below --
2008-09-29  9:50 Arun KS

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.