mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data
@ 2024-05-18  3:35 Shenghao Ding
  2024-05-20  9:29 ` Andy Shevchenko
  2024-05-20 19:27 ` Mark Brown
  0 siblings, 2 replies; 4+ messages in thread
From: Shenghao Ding @ 2024-05-18  3:35 UTC (permalink / raw)
  To: broonie
  Cc: andriy.shevchenko, i-salazar, pierre-louis.bossart, 13916275206,
	alsa-devel, linux-kernel, liam.r.girdwood, kevin-lu, tiwai,
	baojun.xu, soyer, Baojun.Xu, Shenghao Ding

TAS2552 is a Smartamp with I/V sense data, add TX path
to support capturing I/V data.

Fixes: 38803ce7b53b ("ASoC: codecs: tas*: merge .digital_mute() into .mute_stream()")
Signed-off-by: Shenghao Ding <shenghao-ding@ti.com>

---
v1:
 - Changed the copyright year to 2024 in the related files.
 - Add tx device in tas2552_dai.
 - Add Stream Domain Widgets for I/V capture
 - Add INPUT widget
 - Add I/V capture route
---
 sound/soc/codecs/tas2552.c | 15 +++++++++++++--
 1 file changed, 13 insertions(+), 2 deletions(-)

diff --git a/sound/soc/codecs/tas2552.c b/sound/soc/codecs/tas2552.c
index 40f5f27e74c0..9fd3642b98b3 100644
--- a/sound/soc/codecs/tas2552.c
+++ b/sound/soc/codecs/tas2552.c
@@ -2,7 +2,8 @@
 /*
  * tas2552.c - ALSA SoC Texas Instruments TAS2552 Mono Audio Amplifier
  *
- * Copyright (C) 2014 Texas Instruments Incorporated -  https://www.ti.com
+ * Copyright (C) 2014 - 2024 Texas Instruments Incorporated -
+ *	https://www.ti.com
  *
  * Author: Dan Murphy <dmurphy@ti.com>
  */
@@ -119,12 +120,14 @@ static const struct snd_soc_dapm_widget tas2552_dapm_widgets[] =
 			 &tas2552_input_mux_control),
 
 	SND_SOC_DAPM_AIF_IN("DAC IN", "DAC Playback", 0, SND_SOC_NOPM, 0, 0),
+	SND_SOC_DAPM_AIF_OUT("ASI OUT", "DAC Capture", 0, SND_SOC_NOPM, 0, 0),
 	SND_SOC_DAPM_DAC("DAC", NULL, SND_SOC_NOPM, 0, 0),
 	SND_SOC_DAPM_OUT_DRV("ClassD", TAS2552_CFG_2, 7, 0, NULL, 0),
 	SND_SOC_DAPM_SUPPLY("PLL", TAS2552_CFG_2, 3, 0, NULL, 0),
 	SND_SOC_DAPM_POST("Post Event", tas2552_post_event),
 
-	SND_SOC_DAPM_OUTPUT("OUT")
+	SND_SOC_DAPM_OUTPUT("OUT"),
+	SND_SOC_DAPM_INPUT("DMIC")
 };
 
 static const struct snd_soc_dapm_route tas2552_audio_map[] = {
@@ -134,6 +137,7 @@ static const struct snd_soc_dapm_route tas2552_audio_map[] = {
 	{"ClassD", NULL, "Input selection"},
 	{"OUT", NULL, "ClassD"},
 	{"ClassD", NULL, "PLL"},
+	{"ASI OUT", NULL, "DMIC"}
 };
 
 #ifdef CONFIG_PM
@@ -538,6 +542,13 @@ static struct snd_soc_dai_driver tas2552_dai[] = {
 			.rates = SNDRV_PCM_RATE_8000_192000,
 			.formats = TAS2552_FORMATS,
 		},
+		.capture = {
+			.stream_name = "Capture",
+			.channels_min = 2,
+			.channels_max = 2,
+			.rates = SNDRV_PCM_RATE_8000_192000,
+			.formats = TAS2552_FORMATS,
+		},
 		.ops = &tas2552_speaker_dai_ops,
 	},
 };
-- 
2.34.1


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

* Re: [PATCH v1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data
  2024-05-18  3:35 [PATCH v1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data Shenghao Ding
@ 2024-05-20  9:29 ` Andy Shevchenko
  2024-05-20  9:31   ` Andy Shevchenko
  2024-05-20 19:27 ` Mark Brown
  1 sibling, 1 reply; 4+ messages in thread
From: Andy Shevchenko @ 2024-05-20  9:29 UTC (permalink / raw)
  To: Shenghao Ding
  Cc: broonie, i-salazar, pierre-louis.bossart, 13916275206,
	alsa-devel, linux-kernel, liam.r.girdwood, kevin-lu, tiwai,
	baojun.xu, soyer, Baojun.Xu

On Sat, May 18, 2024 at 11:35:15AM +0800, Shenghao Ding wrote:
> TAS2552 is a Smartamp with I/V sense data, add TX path
> to support capturing I/V data.

...

>  /*
>   * tas2552.c - ALSA SoC Texas Instruments TAS2552 Mono Audio Amplifier
>   *
> - * Copyright (C) 2014 Texas Instruments Incorporated -  https://www.ti.com
> + * Copyright (C) 2014 - 2024 Texas Instruments Incorporated -
> + *	https://www.ti.com

Is it okay to wrap the (c) line? (Just asking.)

>   * Author: Dan Murphy <dmurphy@ti.com>
>   */

-- 
With Best Regards,
Andy Shevchenko



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

* Re: [PATCH v1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data
  2024-05-20  9:29 ` Andy Shevchenko
@ 2024-05-20  9:31   ` Andy Shevchenko
  0 siblings, 0 replies; 4+ messages in thread
From: Andy Shevchenko @ 2024-05-20  9:31 UTC (permalink / raw)
  To: Shenghao Ding
  Cc: broonie, i-salazar, pierre-louis.bossart, 13916275206,
	alsa-devel, linux-kernel, liam.r.girdwood, kevin-lu, tiwai,
	baojun.xu, soyer, Baojun.Xu

On Mon, May 20, 2024 at 12:29:41PM +0300, Andy Shevchenko wrote:
> On Sat, May 18, 2024 at 11:35:15AM +0800, Shenghao Ding wrote:

...

> >  /*
> >   * tas2552.c - ALSA SoC Texas Instruments TAS2552 Mono Audio Amplifier
> >   *
> > - * Copyright (C) 2014 Texas Instruments Incorporated -  https://www.ti.com
> > + * Copyright (C) 2014 - 2024 Texas Instruments Incorporated -
> > + *	https://www.ti.com
> 
> Is it okay to wrap the (c) line? (Just asking.)

In another TI driver the form of

 * Copyright (C) 2014 - 2024 Texas Instruments Incorporated
 * https://www.ti.com

is used, perhaps you should align?

> >   * Author: Dan Murphy <dmurphy@ti.com>
> >   */

-- 
With Best Regards,
Andy Shevchenko



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

* Re: [PATCH v1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data
  2024-05-18  3:35 [PATCH v1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data Shenghao Ding
  2024-05-20  9:29 ` Andy Shevchenko
@ 2024-05-20 19:27 ` Mark Brown
  1 sibling, 0 replies; 4+ messages in thread
From: Mark Brown @ 2024-05-20 19:27 UTC (permalink / raw)
  To: Shenghao Ding
  Cc: andriy.shevchenko, i-salazar, pierre-louis.bossart, 13916275206,
	alsa-devel, linux-kernel, liam.r.girdwood, kevin-lu, tiwai,
	baojun.xu, soyer, Baojun.Xu

On Sat, 18 May 2024 11:35:15 +0800, Shenghao Ding wrote:
> TAS2552 is a Smartamp with I/V sense data, add TX path
> to support capturing I/V data.
> 
> 

Applied to

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

Thanks!

[1/1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data
      commit: 7078ac4fd179a68d0bab448004fcd357e7a45f8d

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] 4+ messages in thread

end of thread, other threads:[~2024-05-20 19:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-18  3:35 [PATCH v1] ASoC: tas2552: Add TX path for capturing AUDIO-OUT data Shenghao Ding
2024-05-20  9:29 ` Andy Shevchenko
2024-05-20  9:31   ` Andy Shevchenko
2024-05-20 19:27 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®