ASoC: Use dai_fmt in saarb machine driver
Subsystems (3)
PATCH 1/4 ASoC: Use dai_fmt in saarb machine driver
--- sound/soc/pxa/saarb.c | 11 ++--------- 1 files changed, 2 insertions(+), 9 deletions(-)
sound/soc/pxa/saarb.c +2 -9
@@ -92,15 +92,6 @@ static int saarb_i2s_hw_params(struct snd_pcm_substream *substream,if (ret <0 )return ret; - ret =snd_soc_dai_set_fmt (cpu_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBM_CFM ); -if (ret <0 ) -return ret; - ret =snd_soc_dai_set_fmt (codec_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBM_CFM ); -if (ret <0 ) -return ret; - ret =snd_soc_dai_set_tdm_slot (cpu_dai,3 ,3 ,2 , width);return ret;
@@ -119,6 +110,8 @@ static struct snd_soc_dai_link saarb_dai[] = { .platform_name = "pxa-pcm-audio", .codec_name = "88pm860x-codec", .init = saarb_pm860x_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBM_CFM, .ops = &saarb_i2s_ops, }, };
Signature · 1 line
1.7.5.4
PATCH 2/4 ASoC: Use dai_fmt in spitz machine driver
--- sound/soc/pxa/spitz.c | 14 ++------------ 1 files changed, 2 insertions(+), 12 deletions(-)
sound/soc/pxa/spitz.c +2 -12
@@ -143,18 +143,6 @@ static int spitz_hw_params(struct snd_pcm_substream *substream,break ; } -/* set codec DAI configuration */ - ret =snd_soc_dai_set_fmt (codec_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBS_CFS ); -if (ret <0 ) -return ret; - -/* set cpu DAI configuration */ - ret =snd_soc_dai_set_fmt (cpu_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBS_CFS ); -if (ret <0 ) -return ret; -/* set the codec system clock for DAC and ADC */ ret =snd_soc_dai_set_sysclk (codec_dai,WM8750_SYSCLK , clk,SND_SOC_CLOCK_IN );
@@ -313,6 +301,8 @@ static struct snd_soc_dai_link spitz_dai = { .platform_name = "pxa-pcm-audio", .codec_name = "wm8750.0-001b", .init = spitz_wm8750_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBS_CFS, .ops = &spitz_ops, };
Signature · 1 line
1.7.5.4
Re: [PATCH 2/4] ASoC: Use dai_fmt in spitz machine driver
Quoted 29 lines · Axel Lin
Signed-off-by Axel Lin <[email protected]>---
sound/soc/pxa/spitz.c | 14 ++------------1 files changed, 2 insertions(+), 12 deletions(-)sound/soc/pxa/spitz.c +0
-12@@ -143,18 +143,6 @@ static int spitz_hw_params(struct snd_pcm_substream *substream, break; } - /* set codec DAI configuration */ - ret = snd_soc_dai_set_fmt(codec_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBS_CFS); - if (ret < 0) - return ret; - - /* set cpu DAI configuration */ - ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBS_CFS); - if (ret < 0) - return ret; - /* set the codec system clock for DAC and ADC */ ret = snd_soc_dai_set_sysclk(codec_dai, WM8750_SYSCLK, clk, SND_SOC_CLOCK_IN);
sound/soc/pxa/spitz.c static struct snd_soc_dai_link spitz_dai = { · line 308
Quoted 8 lines
sound/soc/pxa/spitz.c +2
-0@@ -313,6 +301,8 @@ static struct snd_soc_dai_link spitz_dai = { .platform_name = "pxa-pcm-audio", .codec_name = "wm8750.0-001b", .init = spitz_wm8750_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBS_CFS, .ops = &spitz_ops, };
PATCH 3/4 ASoC: Use dai_fmt in tavorevb3 machine driver
In reply to Axel Lin--- sound/soc/pxa/tavorevb3.c | 12 ++---------- 1 files changed, 2 insertions(+), 10 deletions(-)
sound/soc/pxa/tavorevb3.c +2 -10
@@ -92,16 +92,6 @@ static int evb3_i2s_hw_params(struct snd_pcm_substream *substream,if (ret <0 )return ret; - ret =snd_soc_dai_set_fmt (cpu_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBM_CFM ); -if (ret <0 ) -return ret; - - ret =snd_soc_dai_set_fmt (codec_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBM_CFM ); -if (ret <0 ) -return ret; - ret =snd_soc_dai_set_tdm_slot (cpu_dai,3 ,3 ,2 , width);return ret; }
@@ -119,6 +109,8 @@ static struct snd_soc_dai_link evb3_dai[] = { .platform_name = "pxa-pcm-audio", .codec_name = "88pm860x-codec", .init = evb3_pm860x_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBM_CFM, .ops = &evb3_i2s_ops, }, };
Signature · 1 line
1.7.5.4
Re: [PATCH 3/4] ASoC: Use dai_fmt in tavorevb3 machine driver
Quoted 27 lines · Axel Lin
Signed-off-by Axel Lin <[email protected]>---
sound/soc/pxa/tavorevb3.c | 12 ++----------1 files changed, 2 insertions(+), 10 deletions(-)sound/soc/pxa/tavorevb3.c +0
-10@@ -92,16 +92,6 @@ static int evb3_i2s_hw_params(struct snd_pcm_substream *substream, if (ret < 0) return ret; - ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM); - if (ret < 0) - return ret; - - ret = snd_soc_dai_set_fmt(codec_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM); - if (ret < 0) - return ret; - ret = snd_soc_dai_set_tdm_slot(cpu_dai, 3, 3, 2, width); return ret; }
sound/soc/pxa/tavorevb3.c static struct snd_soc_dai_link evb3_dai[] = {
Quoted 9 lines
sound/soc/pxa/tavorevb3.c +2
-1@@ -119,6 +109,8 @@ static struct snd_soc_dai_link evb3_dai[] = { .platform_name = "pxa-pcm-audio", .codec_name = "88pm860x-codec", .init = evb3_pm860x_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBM_CFM, .ops = &evb3_i2s_ops, }, }; --
PATCH 4/4 ASoC: Use dai_fmt in z2 machine driver
In reply to Axel Lin--- sound/soc/pxa/z2.c | 14 ++------------ 1 files changed, 2 insertions(+), 12 deletions(-)
sound/soc/pxa/z2.c +2 -12
@@ -56,18 +56,6 @@ static int z2_hw_params(struct snd_pcm_substream *substream,break ; } -/* set codec DAI configuration */ - ret =snd_soc_dai_set_fmt (codec_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBS_CFS ); -if (ret <0 ) -return ret; - -/* set cpu DAI configuration */ - ret =snd_soc_dai_set_fmt (cpu_dai,SND_SOC_DAIFMT_I2S | -SND_SOC_DAIFMT_NB_NF |SND_SOC_DAIFMT_CBS_CFS ); -if (ret <0 ) -return ret; -/* set the codec system clock for DAC and ADC */ ret =snd_soc_dai_set_sysclk (codec_dai,WM8750_SYSCLK , clk,SND_SOC_CLOCK_IN );
@@ -196,6 +184,8 @@ static struct snd_soc_dai_link z2_dai = { .platform_name = "pxa-pcm-audio", .codec_name = "wm8750.0-001b", .init = z2_wm8750_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBS_CFS, .ops = &z2_ops, };
Signature · 1 line
1.7.5.4
Re: [PATCH 4/4] ASoC: Use dai_fmt in z2 machine driver
Quoted 29 lines · Axel Lin
Signed-off-by Axel Lin <[email protected]>---
sound/soc/pxa/z2.c | 14 ++------------1 files changed, 2 insertions(+), 12 deletions(-)sound/soc/pxa/z2.c +0
-12@@ -56,18 +56,6 @@ static int z2_hw_params(struct snd_pcm_substream *substream, break; } - /* set codec DAI configuration */ - ret = snd_soc_dai_set_fmt(codec_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBS_CFS); - if (ret < 0) - return ret; - - /* set cpu DAI configuration */ - ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBS_CFS); - if (ret < 0) - return ret; - /* set the codec system clock for DAC and ADC */ ret = snd_soc_dai_set_sysclk(codec_dai, WM8750_SYSCLK, clk, SND_SOC_CLOCK_IN);
sound/soc/pxa/z2.c static struct snd_soc_dai_link z2_dai = {
Quoted 9 lines
sound/soc/pxa/z2.c +2
-1@@ -196,6 +184,8 @@ static struct snd_soc_dai_link z2_dai = { .platform_name = "pxa-pcm-audio", .codec_name = "wm8750.0-001b", .init = z2_wm8750_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBS_CFS, .ops = &z2_ops, }; --
Quoted 35 lines · Axel Lin
Signed-off-by Axel Lin <[email protected]>---
sound/soc/pxa/saarb.c | 11 ++---------1 files changed, 2 insertions(+), 9 deletions(-)sound/soc/pxa/saarb.c +2
-10@@ -92,15 +92,6 @@ static int saarb_i2s_hw_params(struct snd_pcm_substream *substream, if (ret < 0) return ret; - ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM); - if (ret < 0) - return ret; - ret = snd_soc_dai_set_fmt(codec_dai, SND_SOC_DAIFMT_I2S | - SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM); - if (ret < 0) - return ret; - ret = snd_soc_dai_set_tdm_slot(cpu_dai, 3, 3, 2, width); return ret;@@ -119,6 +110,8 @@ static struct snd_soc_dai_link saarb_dai[] = { .platform_name = "pxa-pcm-audio", .codec_name = "88pm860x-codec", .init = saarb_pm860x_init, + .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBM_CFM, .ops = &saarb_i2s_ops, }, }; --
Quoted 2 lines
1.7.5.4
Mark Brown
AppliedQuoted 1 line · Axel Lin
Signed-off-by Axel Lin <[email protected]>
Applied all, thanks.