All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] ASoC: fsl: Fix fsl-asoc-card AC'97 support
@ 2023-01-06 23:15 ` Mark Brown
  0 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-06 23:15 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen, Liam Girdwood
  Cc: alsa-devel, Mark Brown, linux-arm-kernel

The generic driver for Freescale cards with ASRC does not so far as I
can tell work for AC'97 cards, it's certainly not working for the two
Udoo boards I have that use it and I'm not clear how it ever worked.
These patches fix the card well enough to probe and make it through
pcm-test for playback at standard rates, though there are still issues
with capture and some playback configurations getting confused about
constraints.

To: Shengjiu Wang <shengjiu.wang@gmail.com>
To: Xiubo Li <Xiubo.Lee@gmail.com>
To: Fabio Estevam <festevam@gmail.com>
To: Nicolin Chen <nicoleotsuka@gmail.com>
To: Liam Girdwood <lgirdwood@gmail.com>
Cc: alsa-devel@alsa-project.org
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: Mark Brown <broonie@kernel.org>

---
Mark Brown (2):
      ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97 CODEC
      ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets

 sound/soc/fsl/fsl-asoc-card.c | 8 ++++----
 sound/soc/fsl/fsl_ssi.c       | 4 ++--
 2 files changed, 6 insertions(+), 6 deletions(-)
---
base-commit: 1b929c02afd37871d5afb9d498426f83432e71c2
change-id: 20230106-asoc-udoo-probe-54daa107cbcb

Best regards,
-- 
Mark Brown <broonie@kernel.org>

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

* [PATCH 1/2] ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97 CODEC
  2023-01-06 23:15 ` Mark Brown
@ 2023-01-06 23:15   ` Mark Brown
  -1 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-06 23:15 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen, Liam Girdwood
  Cc: alsa-devel, Mark Brown, linux-arm-kernel

The SSI driver calls the AC'97 playback and transmit streams "AC97 Playback"
and "AC97 Capture" respectively. This is the same name used by the generic
AC'97 CODEC driver in ASoC, creating confusion for the Freescale ASoC card
when it attempts to use these widgets in routing. Add a "CPU" in the name
like the regular DAIs registered by the driver to disambiguate.

Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/fsl/fsl-asoc-card.c | 8 ++++----
 sound/soc/fsl/fsl_ssi.c       | 4 ++--
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc-card.c
index c836848ef0a6..1dfd0341e487 100644
--- a/sound/soc/fsl/fsl-asoc-card.c
+++ b/sound/soc/fsl/fsl-asoc-card.c
@@ -121,11 +121,11 @@ static const struct snd_soc_dapm_route audio_map[] = {
 
 static const struct snd_soc_dapm_route audio_map_ac97[] = {
 	/* 1st half -- Normal DAPM routes */
-	{"Playback",  NULL, "AC97 Playback"},
-	{"AC97 Capture",  NULL, "Capture"},
+	{"Playback",  NULL, "CPU AC97 Playback"},
+	{"CPU AC97 Capture",  NULL, "Capture"},
 	/* 2nd half -- ASRC DAPM routes */
-	{"AC97 Playback",  NULL, "ASRC-Playback"},
-	{"ASRC-Capture",  NULL, "AC97 Capture"},
+	{"CPU AC97 Playback",  NULL, "ASRC-Playback"},
+	{"ASRC-Capture",  NULL, "CPU AC97 Capture"},
 };
 
 static const struct snd_soc_dapm_route audio_map_tx[] = {
diff --git a/sound/soc/fsl/fsl_ssi.c b/sound/soc/fsl/fsl_ssi.c
index c9e0e31d5b34..46a53551b955 100644
--- a/sound/soc/fsl/fsl_ssi.c
+++ b/sound/soc/fsl/fsl_ssi.c
@@ -1189,14 +1189,14 @@ static struct snd_soc_dai_driver fsl_ssi_ac97_dai = {
 	.symmetric_channels = 1,
 	.probe = fsl_ssi_dai_probe,
 	.playback = {
-		.stream_name = "AC97 Playback",
+		.stream_name = "CPU AC97 Playback",
 		.channels_min = 2,
 		.channels_max = 2,
 		.rates = SNDRV_PCM_RATE_8000_48000,
 		.formats = SNDRV_PCM_FMTBIT_S16 | SNDRV_PCM_FMTBIT_S20,
 	},
 	.capture = {
-		.stream_name = "AC97 Capture",
+		.stream_name = "CPU AC97 Capture",
 		.channels_min = 2,
 		.channels_max = 2,
 		.rates = SNDRV_PCM_RATE_48000,

-- 
2.30.2

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

* [PATCH 0/2] ASoC: fsl: Fix fsl-asoc-card AC'97 support
@ 2023-01-06 23:15 ` Mark Brown
  0 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-06 23:15 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen, Liam Girdwood
  Cc: alsa-devel, linux-arm-kernel, Mark Brown

The generic driver for Freescale cards with ASRC does not so far as I
can tell work for AC'97 cards, it's certainly not working for the two
Udoo boards I have that use it and I'm not clear how it ever worked.
These patches fix the card well enough to probe and make it through
pcm-test for playback at standard rates, though there are still issues
with capture and some playback configurations getting confused about
constraints.

To: Shengjiu Wang <shengjiu.wang@gmail.com>
To: Xiubo Li <Xiubo.Lee@gmail.com>
To: Fabio Estevam <festevam@gmail.com>
To: Nicolin Chen <nicoleotsuka@gmail.com>
To: Liam Girdwood <lgirdwood@gmail.com>
Cc: alsa-devel@alsa-project.org
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: Mark Brown <broonie@kernel.org>

---
Mark Brown (2):
      ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97 CODEC
      ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets

 sound/soc/fsl/fsl-asoc-card.c | 8 ++++----
 sound/soc/fsl/fsl_ssi.c       | 4 ++--
 2 files changed, 6 insertions(+), 6 deletions(-)
---
base-commit: 1b929c02afd37871d5afb9d498426f83432e71c2
change-id: 20230106-asoc-udoo-probe-54daa107cbcb

Best regards,
-- 
Mark Brown <broonie@kernel.org>

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH 1/2] ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97 CODEC
@ 2023-01-06 23:15   ` Mark Brown
  0 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-06 23:15 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen, Liam Girdwood
  Cc: alsa-devel, linux-arm-kernel, Mark Brown

The SSI driver calls the AC'97 playback and transmit streams "AC97 Playback"
and "AC97 Capture" respectively. This is the same name used by the generic
AC'97 CODEC driver in ASoC, creating confusion for the Freescale ASoC card
when it attempts to use these widgets in routing. Add a "CPU" in the name
like the regular DAIs registered by the driver to disambiguate.

Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/fsl/fsl-asoc-card.c | 8 ++++----
 sound/soc/fsl/fsl_ssi.c       | 4 ++--
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc-card.c
index c836848ef0a6..1dfd0341e487 100644
--- a/sound/soc/fsl/fsl-asoc-card.c
+++ b/sound/soc/fsl/fsl-asoc-card.c
@@ -121,11 +121,11 @@ static const struct snd_soc_dapm_route audio_map[] = {
 
 static const struct snd_soc_dapm_route audio_map_ac97[] = {
 	/* 1st half -- Normal DAPM routes */
-	{"Playback",  NULL, "AC97 Playback"},
-	{"AC97 Capture",  NULL, "Capture"},
+	{"Playback",  NULL, "CPU AC97 Playback"},
+	{"CPU AC97 Capture",  NULL, "Capture"},
 	/* 2nd half -- ASRC DAPM routes */
-	{"AC97 Playback",  NULL, "ASRC-Playback"},
-	{"ASRC-Capture",  NULL, "AC97 Capture"},
+	{"CPU AC97 Playback",  NULL, "ASRC-Playback"},
+	{"ASRC-Capture",  NULL, "CPU AC97 Capture"},
 };
 
 static const struct snd_soc_dapm_route audio_map_tx[] = {
diff --git a/sound/soc/fsl/fsl_ssi.c b/sound/soc/fsl/fsl_ssi.c
index c9e0e31d5b34..46a53551b955 100644
--- a/sound/soc/fsl/fsl_ssi.c
+++ b/sound/soc/fsl/fsl_ssi.c
@@ -1189,14 +1189,14 @@ static struct snd_soc_dai_driver fsl_ssi_ac97_dai = {
 	.symmetric_channels = 1,
 	.probe = fsl_ssi_dai_probe,
 	.playback = {
-		.stream_name = "AC97 Playback",
+		.stream_name = "CPU AC97 Playback",
 		.channels_min = 2,
 		.channels_max = 2,
 		.rates = SNDRV_PCM_RATE_8000_48000,
 		.formats = SNDRV_PCM_FMTBIT_S16 | SNDRV_PCM_FMTBIT_S20,
 	},
 	.capture = {
-		.stream_name = "AC97 Capture",
+		.stream_name = "CPU AC97 Capture",
 		.channels_min = 2,
 		.channels_max = 2,
 		.rates = SNDRV_PCM_RATE_48000,

-- 
2.30.2

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH 2/2] ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets
  2023-01-06 23:15 ` Mark Brown
@ 2023-01-06 23:15   ` Mark Brown
  -1 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-06 23:15 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen, Liam Girdwood
  Cc: alsa-devel, Mark Brown, linux-arm-kernel

The fsl-asoc-card AC'97 support currently tries to route to Playback and
Capture widgets provided by the AC'97 CODEC. This doesn't work since the
generic AC'97 driver registers with an "AC97" at the front of the stream
and hence widget names, update to reflect reality. It's not clear to me
if or how this ever worked.

Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/fsl/fsl-asoc-card.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc-card.c
index 1dfd0341e487..8d14b5593658 100644
--- a/sound/soc/fsl/fsl-asoc-card.c
+++ b/sound/soc/fsl/fsl-asoc-card.c
@@ -121,8 +121,8 @@ static const struct snd_soc_dapm_route audio_map[] = {
 
 static const struct snd_soc_dapm_route audio_map_ac97[] = {
 	/* 1st half -- Normal DAPM routes */
-	{"Playback",  NULL, "CPU AC97 Playback"},
-	{"CPU AC97 Capture",  NULL, "Capture"},
+	{"AC97 Playback",  NULL, "CPU AC97 Playback"},
+	{"CPU AC97 Capture",  NULL, "AC97 Capture"},
 	/* 2nd half -- ASRC DAPM routes */
 	{"CPU AC97 Playback",  NULL, "ASRC-Playback"},
 	{"ASRC-Capture",  NULL, "CPU AC97 Capture"},

-- 
2.30.2

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

* [PATCH 2/2] ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets
@ 2023-01-06 23:15   ` Mark Brown
  0 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-06 23:15 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen, Liam Girdwood
  Cc: alsa-devel, linux-arm-kernel, Mark Brown

The fsl-asoc-card AC'97 support currently tries to route to Playback and
Capture widgets provided by the AC'97 CODEC. This doesn't work since the
generic AC'97 driver registers with an "AC97" at the front of the stream
and hence widget names, update to reflect reality. It's not clear to me
if or how this ever worked.

Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/fsl/fsl-asoc-card.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc-card.c
index 1dfd0341e487..8d14b5593658 100644
--- a/sound/soc/fsl/fsl-asoc-card.c
+++ b/sound/soc/fsl/fsl-asoc-card.c
@@ -121,8 +121,8 @@ static const struct snd_soc_dapm_route audio_map[] = {
 
 static const struct snd_soc_dapm_route audio_map_ac97[] = {
 	/* 1st half -- Normal DAPM routes */
-	{"Playback",  NULL, "CPU AC97 Playback"},
-	{"CPU AC97 Capture",  NULL, "Capture"},
+	{"AC97 Playback",  NULL, "CPU AC97 Playback"},
+	{"CPU AC97 Capture",  NULL, "AC97 Capture"},
 	/* 2nd half -- ASRC DAPM routes */
 	{"CPU AC97 Playback",  NULL, "ASRC-Playback"},
 	{"ASRC-Capture",  NULL, "CPU AC97 Capture"},

-- 
2.30.2

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 0/2] ASoC: fsl: Fix fsl-asoc-card AC'97 support
  2023-01-06 23:15 ` Mark Brown
                   ` (2 preceding siblings ...)
  (?)
@ 2023-01-10  5:24 ` Shengjiu Wang
  -1 siblings, 0 replies; 9+ messages in thread
From: Shengjiu Wang @ 2023-01-10  5:24 UTC (permalink / raw)
  To: Mark Brown
  Cc: alsa-devel, Xiubo Li, Liam Girdwood, Nicolin Chen, Fabio Estevam,
	linux-arm-kernel

On Sat, Jan 7, 2023 at 7:16 AM Mark Brown <broonie@kernel.org> wrote:

> The generic driver for Freescale cards with ASRC does not so far as I
> can tell work for AC'97 cards, it's certainly not working for the two
> Udoo boards I have that use it and I'm not clear how it ever worked.
> These patches fix the card well enough to probe and make it through
> pcm-test for playback at standard rates, though there are still issues
> with capture and some playback configurations getting confused about
> constraints.
>
> To: Shengjiu Wang <shengjiu.wang@gmail.com>
> To: Xiubo Li <Xiubo.Lee@gmail.com>
> To: Fabio Estevam <festevam@gmail.com>
> To: Nicolin Chen <nicoleotsuka@gmail.com>
> To: Liam Girdwood <lgirdwood@gmail.com>
> Cc: alsa-devel@alsa-project.org
> Cc: linux-arm-kernel@lists.infradead.org
> Signed-off-by: Mark Brown <broonie@kernel.org>
>

Acked-by: Shengjiu Wang <shengjiu.wang@gmail.com>

Best regards
Wang shengjiu

>
> ---
> Mark Brown (2):
>       ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97
> CODEC
>       ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets
>
>  sound/soc/fsl/fsl-asoc-card.c | 8 ++++----
>  sound/soc/fsl/fsl_ssi.c       | 4 ++--
>  2 files changed, 6 insertions(+), 6 deletions(-)
> ---
> base-commit: 1b929c02afd37871d5afb9d498426f83432e71c2
> change-id: 20230106-asoc-udoo-probe-54daa107cbcb
>
> Best regards,
> --
> Mark Brown <broonie@kernel.org>
>

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

* Re: [PATCH 0/2] ASoC: fsl: Fix fsl-asoc-card AC'97 support
  2023-01-06 23:15 ` Mark Brown
@ 2023-01-10 14:17   ` Mark Brown
  -1 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-10 14:17 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen,
	Liam Girdwood, Mark Brown
  Cc: alsa-devel, linux-arm-kernel

On Fri, 06 Jan 2023 23:15:06 +0000, Mark Brown wrote:
> The generic driver for Freescale cards with ASRC does not so far as I
> can tell work for AC'97 cards, it's certainly not working for the two
> Udoo boards I have that use it and I'm not clear how it ever worked.
> These patches fix the card well enough to probe and make it through
> pcm-test for playback at standard rates, though there are still issues
> with capture and some playback configurations getting confused about
> constraints.
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/2] ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97 CODEC
      commit: 8c6a42b5b0ed6f96624f56954e93eeae107440a6
[2/2] ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets
      commit: 242fc66ae6e1e2b8519daacc7590a73cd0e8a6e4

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

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

* Re: [PATCH 0/2] ASoC: fsl: Fix fsl-asoc-card AC'97 support
@ 2023-01-10 14:17   ` Mark Brown
  0 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2023-01-10 14:17 UTC (permalink / raw)
  To: Shengjiu Wang, Xiubo Li, Fabio Estevam, Nicolin Chen,
	Liam Girdwood, Mark Brown
  Cc: alsa-devel, linux-arm-kernel

On Fri, 06 Jan 2023 23:15:06 +0000, Mark Brown wrote:
> The generic driver for Freescale cards with ASRC does not so far as I
> can tell work for AC'97 cards, it's certainly not working for the two
> Udoo boards I have that use it and I'm not clear how it ever worked.
> These patches fix the card well enough to probe and make it through
> pcm-test for playback at standard rates, though there are still issues
> with capture and some playback configurations getting confused about
> constraints.
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/2] ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97 CODEC
      commit: 8c6a42b5b0ed6f96624f56954e93eeae107440a6
[2/2] ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets
      commit: 242fc66ae6e1e2b8519daacc7590a73cd0e8a6e4

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2023-01-10 14:19 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-06 23:15 [PATCH 0/2] ASoC: fsl: Fix fsl-asoc-card AC'97 support Mark Brown
2023-01-06 23:15 ` Mark Brown
2023-01-06 23:15 ` [PATCH 1/2] ASoC: fsl_ssi: Rename AC'97 streams to avoid collisions with AC'97 CODEC Mark Brown
2023-01-06 23:15   ` Mark Brown
2023-01-06 23:15 ` [PATCH 2/2] ASoC: fsl-asoc-card: Fix naming of AC'97 CODEC widgets Mark Brown
2023-01-06 23:15   ` Mark Brown
2023-01-10  5:24 ` [PATCH 0/2] ASoC: fsl: Fix fsl-asoc-card AC'97 support Shengjiu Wang
2023-01-10 14:17 ` Mark Brown
2023-01-10 14:17   ` Mark Brown

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.