Skip to contentSkip to conversation

ASoC: Blackfin: bf5xx-ad193x: Fix codec device name

PATCH Applied Lars-Peter Clausen 4 participants 5 messages Sep 5, 2011 – Sep 6, 2011

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ASoC: Blackfin: bf5xx-ad193x: Fix codec device name

Fix the codec_name field of the dai_link to match the actual device name of the codec. Otherwise the card won't be instantiated.

---
 sound/soc/blackfin/bf5xx-ad193x.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
sound/soc/blackfin/bf5xx-ad193x.c +2 -2
index a118a0f..5956584 100644
@@ -103,7 +103,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
 		.cpu_dai_name = "bfin-tdm.0",
 		.codec_dai_name ="ad193x-hifi",
 		.platform_name = "bfin-tdm-pcm-audio",
-		.codec_name = "ad193x.5",
+		.codec_name = "spi0.5",
 		.ops = &bf5xx_ad193x_ops,
 	},
 	{
@@ -112,7 +112,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
 		.cpu_dai_name = "bfin-tdm.1",
 		.codec_dai_name ="ad193x-hifi",
 		.platform_name = "bfin-tdm-pcm-audio",
-		.codec_name = "ad193x.5",
+		.codec_name = "spi0.5",
 		.ops = &bf5xx_ad193x_ops,
 	},
 };
Signature · 1 line
1.7.2.5
#1 lore raw
Quoted 36 lines · Lars-Peter Clausen

Fix the codec_name field of the dai_link to match the actual device name of the codec. Otherwise the card won't be instantiated.

---
 sound/soc/blackfin/bf5xx-ad193x.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
sound/soc/blackfin/bf5xx-ad193x.c +2 -3
index a118a0f..5956584 100644
@@ -103,7 +103,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
               .cpu_dai_name = "bfin-tdm.0",
               .codec_dai_name ="ad193x-hifi",
               .platform_name = "bfin-tdm-pcm-audio",
-               .codec_name = "ad193x.5",
+               .codec_name = "spi0.5",
               .ops = &bf5xx_ad193x_ops,
       },
       {
@@ -112,7 +112,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
               .cpu_dai_name = "bfin-tdm.1",
               .codec_dai_name ="ad193x-hifi",
               .platform_name = "bfin-tdm-pcm-audio",
-               .codec_name = "ad193x.5",
+               .codec_name = "spi0.5",
               .ops = &bf5xx_ad193x_ops,
       },
 };
--

1.7.2.5

Applied
#2 lore raw
In reply to Lars-Peter Clausen
Quoted 2 lines · Lars-Peter Clausen

Fix the codec_name field of the dai_link to match the actual device name of the codec. Otherwise the card won't be instantiated.

Applied, thanks.

#3 lore raw
In reply to Lars-Peter Clausen

2011/9/5 Lars-Peter Clausen <[email protected]>:

Quoted 32 lines

Fix the codec_name field of the dai_link to match the actual device name of the codec. Otherwise the card won't be instantiated.

---
 sound/soc/blackfin/bf5xx-ad193x.c |    4 ++--

 1 files changed, 2 insertions(+), 2 deletions(-)
sound/soc/blackfin/bf5xx-ad193x.c +2 -3
index a118a0f..5956584 100644
@@ -103,7 +103,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
                .cpu_dai_name = "bfin-tdm.0",
                .codec_dai_name ="ad193x-hifi",
                .platform_name = "bfin-tdm-pcm-audio",
-               .codec_name = "ad193x.5",
+               .codec_name = "spi0.5",
                .ops = &bf5xx_ad193x_ops,
        },
        {
@@ -112,7 +112,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
                .cpu_dai_name = "bfin-tdm.1",
                .codec_dai_name ="ad193x-hifi",
                .platform_name = "bfin-tdm-pcm-audio",
-               .codec_name = "ad193x.5",
+               .codec_name = "spi0.5",
                .ops = &bf5xx_ad193x_ops,
        },
  };
--
Quoted 1 line

1.7.2.5

Lars, I have to tell you ad193x supports i2c and spi.

#if defined(CONFIG_SND_SOC_AD193X_SPI)
                .codec_name = "spi0.5",
#elif defined(CONFIG_SND_SOC_AD193X_I2C)
                .codec_name = "ad193x.0-0004",

#endif

It is better to modify machine driver to platform driver and pass in control type.

Scott

#4 lore raw
Quoted 41 lines · Scott Jiang

2011/9/5 Lars-Peter Clausen <[email protected]>:

Quoted 32 lines

Fix the codec_name field of the dai_link to match the actual device name of the codec. Otherwise the card won't be instantiated.

---
 sound/soc/blackfin/bf5xx-ad193x.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
sound/soc/blackfin/bf5xx-ad193x.c +2 -3
index a118a0f..5956584 100644
@@ -103,7 +103,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
               .cpu_dai_name = "bfin-tdm.0",
               .codec_dai_name ="ad193x-hifi",
               .platform_name = "bfin-tdm-pcm-audio",
-               .codec_name = "ad193x.5",
+               .codec_name = "spi0.5",
               .ops = &bf5xx_ad193x_ops,
       },
       {
@@ -112,7 +112,7 @@ static struct snd_soc_dai_link bf5xx_ad193x_dai[] = {
               .cpu_dai_name = "bfin-tdm.1",
               .codec_dai_name ="ad193x-hifi",
               .platform_name = "bfin-tdm-pcm-audio",
-               .codec_name = "ad193x.5",
+               .codec_name = "spi0.5",
               .ops = &bf5xx_ad193x_ops,
       },
 };
--
Quoted 1 line

1.7.2.5

Lars, I have to tell you ad193x supports i2c and spi.

#if defined(CONFIG_SND_SOC_AD193X_SPI)
                .codec_name = "spi0.5",
#elif defined(CONFIG_SND_SOC_AD193X_I2C)
                .codec_name = "ad193x.0-0004",
Quoted 6 lines

#endif

It is better to modify machine driver to platform driver and pass in control type.

Scott

Yes, though I would prefer using platform_device_id for this since whether it is I2C or SPI depends on the codec model.

- Lars