Skip to contentSkip to conversation

ASoC: Intel: sof_rt5682: add mtl_rt5650 support

PATCH RESEND In review Mac Chiang 3 participants 4 messages Nov 13, 2023 – Nov 14, 2023

Subsystems (3)
lore
Share & tools
lore

Mac Chiang

author
#0 lore raw

PATCH RESEND v3 1/1 ASoC: Intel: sof_rt5682: add mtl_rt5650 support

RT5650 is I2S codec integrated with HP and SPK. The HW board connects SoC I2S to RT5650 codec as below:

I2S0: ALC5650 aif1 for Speaker
I2S2: ALC5650 aif2 for Headphone

---
Hi Pierre, I resend the patch for your review and cc maintainers. Thanks. Pick up for Chrome MTL projects support.

Changes v3:
- missing Reviewed-by, add it.
---

 sound/soc/intel/boards/sof_rt5682.c               |  9 +++++++++
 sound/soc/intel/common/soc-acpi-intel-mtl-match.c | 12 ++++++++++++
 2 files changed, 21 insertions(+)
sound/soc/intel/boards/sof_rt5682.c +9 -0
index 06ad15af46de..9723479f43da 100644
@@ -1147,6 +1147,15 @@ static const struct platform_device_id board_ids[] = {
 					SOF_RT5682_SSP_AMP(0) |
 					SOF_RT5682_NUM_HDMIDEV(3)),
 	},
+	{
+		.name = "mtl_rt5650",
+		.driver_data = (kernel_ulong_t)(SOF_RT5682_MCLK_EN |
+					SOF_RT5682_SSP_CODEC(2) |
+					SOF_RT5682_SSP_AMP(0) |
+					SOF_RT5682_NUM_HDMIDEV(3) |
+					SOF_BT_OFFLOAD_SSP(1) |
+					SOF_SSP_BT_OFFLOAD_PRESENT),
+	},
 	{ }
 };
 MODULE_DEVICE_TABLE(platform, board_ids);
sound/soc/intel/common/soc-acpi-intel-mtl-match.c +12 -0
index 301b8142d554..af4224bff718 100644
@@ -40,6 +40,11 @@ static const struct snd_soc_acpi_codecs mtl_lt6911_hdmi = {
 	.codecs = {"INTC10B0"}
 };
 
+static const struct snd_soc_acpi_codecs mtl_rt5650_amp = {
+	.num_codecs = 1,
+	.codecs = {"10EC5650"}
+};
+
 struct snd_soc_acpi_mach snd_soc_acpi_intel_mtl_machines[] = {
 	{
 		.comp_ids = &mtl_rt5682_rt5682s_hp,
@@ -77,6 +82,13 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_mtl_machines[] = {
 					SND_SOC_ACPI_TPLG_INTEL_SSP_MSB |
 					SND_SOC_ACPI_TPLG_INTEL_DMIC_NUMBER,
 	},
+	{
+		.id = "10EC5650",
+		.drv_name = "mtl_rt5650",
+		.machine_quirk = snd_soc_acpi_codec_list,
+		.quirk_data = &mtl_rt5650_amp,
+		.sof_tplg_filename = "sof-mtl-rt5650.tplg",
+	},
 	/* place amp-only boards in the end of table */
 	{
 		.id = "INTC10B0",
Signature · 1 line
2.20.1
Acked-by on v3 1/1
#1 lore raw
Quoted 11 lines · Mac Chiang

RT5650 is I2S codec integrated with HP and SPK. The HW board connects SoC I2S to RT5650 codec as below:

I2S0: ALC5650 aif1 for Speaker
I2S2: ALC5650 aif2 for Headphone

---
Hi Pierre, I resend the patch for your review and cc maintainers. Thanks. Pick up for Chrome MTL projects support.

The code was submitted as
https://github.com/thesofproject/linux/pull/4661, approved and merged in the topic/sof-dev branch. By submitting the same code multiple times using two different paths, you are just adding more confusion and noise for what should be a straightforward process on a minor change.

Moving forward, please pick one of:
a) submit to alsa-devel
b) submit to the SOF GitHub and let SOF maintainers upstream.

Thank you.

Quoted 59 lines

Changes v3:
- missing Reviewed-by, add it.
---

 sound/soc/intel/boards/sof_rt5682.c               |  9 +++++++++
 sound/soc/intel/common/soc-acpi-intel-mtl-match.c | 12 ++++++++++++
 2 files changed, 21 insertions(+)
sound/soc/intel/boards/sof_rt5682.c +9 -0
index 06ad15af46de..9723479f43da 100644
@@ -1147,6 +1147,15 @@ static const struct platform_device_id board_ids[] = {
 					SOF_RT5682_SSP_AMP(0) |
 					SOF_RT5682_NUM_HDMIDEV(3)),
 	},
+	{
+		.name = "mtl_rt5650",
+		.driver_data = (kernel_ulong_t)(SOF_RT5682_MCLK_EN |
+					SOF_RT5682_SSP_CODEC(2) |
+					SOF_RT5682_SSP_AMP(0) |
+					SOF_RT5682_NUM_HDMIDEV(3) |
+					SOF_BT_OFFLOAD_SSP(1) |
+					SOF_SSP_BT_OFFLOAD_PRESENT),
+	},
 	{ }
 };
 MODULE_DEVICE_TABLE(platform, board_ids);
sound/soc/intel/common/soc-acpi-intel-mtl-match.c +12 -0
index 301b8142d554..af4224bff718 100644
@@ -40,6 +40,11 @@ static const struct snd_soc_acpi_codecs mtl_lt6911_hdmi = {
 	.codecs = {"INTC10B0"}
 };
 
+static const struct snd_soc_acpi_codecs mtl_rt5650_amp = {
+	.num_codecs = 1,
+	.codecs = {"10EC5650"}
+};
+
 struct snd_soc_acpi_mach snd_soc_acpi_intel_mtl_machines[] = {
 	{
 		.comp_ids = &mtl_rt5682_rt5682s_hp,
@@ -77,6 +82,13 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_mtl_machines[] = {
 					SND_SOC_ACPI_TPLG_INTEL_SSP_MSB |
 					SND_SOC_ACPI_TPLG_INTEL_DMIC_NUMBER,
 	},
+	{
+		.id = "10EC5650",
+		.drv_name = "mtl_rt5650",
+		.machine_quirk = snd_soc_acpi_codec_list,
+		.quirk_data = &mtl_rt5650_amp,
+		.sof_tplg_filename = "sof-mtl-rt5650.tplg",
+	},
 	/* place amp-only boards in the end of table */
 	{
 		.id = "INTC10B0",
#2 lore raw
Quoted 34 lines

-----Original Message-----
From: Pierre-Louis Bossart <[email protected]>
Sent: Monday, November 13, 2023 10:41 PM
To: Chiang, Mac <[email protected]>; [email protected]
Cc: Rojewski, Cezary <[email protected]>; [email protected]; [email protected]; yung- [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]
Subject: Re: [RESEND,v3] ASoC: Intel: sof_rt5682: add mtl_rt5650 support

Quoted 11 lines · Mac Chiang

RT5650 is I2S codec integrated with HP and SPK. The HW board connects SoC I2S to RT5650 codec as below:

I2S0: ALC5650 aif1 for Speaker
I2S2: ALC5650 aif2 for Headphone

---
Hi Pierre, I resend the patch for your review and cc maintainers. Thanks. Pick up for Chrome MTL projects support.

The code was submitted as
https://github.com/thesofproject/linux/pull/4661, approved and merged in the topic/sof-dev branch. By submitting the same code multiple times using two different paths, you are just adding more confusion and noise for what should be a straightforward process on a minor change.

Quoted 3 lines

Moving forward, please pick one of:
a) submit to alsa-devel
b) submit to the SOF GitHub and let SOF maintainers upstream.

Thanks for reminding, Pierre. Sure, next time I will follow the minor change process.

Quoted 70 lines

Thank you.

sound/soc/intel/boards/sof_rt5682.c static const struct platform_device_id

Quoted 15 lines

Changes v3:
- missing Reviewed-by, add it.
---

 sound/soc/intel/boards/sof_rt5682.c               |  9 +++++++++
 sound/soc/intel/common/soc-acpi-intel-mtl-match.c | 12 ++++++++++++
 2 files changed, 21 insertions(+)
sound/soc/intel/boards/sof_rt5682.c +0 -0
index 06ad15af46de..9723479f43da 100644
@@ -1147,6 +1147,15 @@ static const struct platform_device_id

board_ids[] = {

sound/soc/intel/common/soc-acpi-intel-mtl-match.c static const struct snd_soc_acpi_codecs

Quoted 21 lines
sound/soc/intel/boards/sof_rt5682.c +9 -0
 					SOF_RT5682_SSP_AMP(0) |
 					SOF_RT5682_NUM_HDMIDEV(3)),
 	},
+	{
+		.name = "mtl_rt5650",
+		.driver_data = (kernel_ulong_t)(SOF_RT5682_MCLK_EN |
+					SOF_RT5682_SSP_CODEC(2) |
+					SOF_RT5682_SSP_AMP(0) |
+					SOF_RT5682_NUM_HDMIDEV(3) |
+					SOF_BT_OFFLOAD_SSP(1) |
+					SOF_SSP_BT_OFFLOAD_PRESENT),
+	},
 	{ }
 };
 MODULE_DEVICE_TABLE(platform, board_ids); diff --git

a/sound/soc/intel/common/soc-acpi-intel-mtl-match.c b/sound/soc/intel/common/soc-acpi-intel-mtl-match.c index 301b8142d554..af4224bff718 100644

sound/soc/intel/common/soc-acpi-intel-mtl-match.c +0 -0
@@ -40,6 +40,11 @@ static const struct snd_soc_acpi_codecs

mtl_lt6911_hdmi = {

sound/soc/intel/common/soc-acpi-intel-mtl-match.c static const struct snd_soc_acpi_codecs mtl_lt6911_hdmi = {

Quoted 11 lines
sound/soc/intel/common/soc-acpi-intel-mtl-match.c +5 -0
 	.codecs = {"INTC10B0"}
 };
 
+static const struct snd_soc_acpi_codecs mtl_rt5650_amp = {
+	.num_codecs = 1,
+	.codecs = {"10EC5650"}
+};
+
 struct snd_soc_acpi_mach snd_soc_acpi_intel_mtl_machines[] = {
 	{
 		.comp_ids = &mtl_rt5682_rt5682s_hp, @@ -77,6 +82,13 @@

struct

Quoted 2 lines

snd_soc_acpi_mach snd_soc_acpi_intel_mtl_machines[] = {

SND_SOC_ACPI_TPLG_INTEL_SSP_MSB |

Quoted 1 line

SND_SOC_ACPI_TPLG_INTEL_DMIC_NUMBER,

Quoted 11 lines
sound/soc/intel/common/soc-acpi-intel-mtl-match.c +7 -0
 	},
+	{
+		.id = "10EC5650",
+		.drv_name = "mtl_rt5650",
+		.machine_quirk = snd_soc_acpi_codec_list,
+		.quirk_data = &mtl_rt5650_amp,
+		.sof_tplg_filename = "sof-mtl-rt5650.tplg",
+	},
 	/* place amp-only boards in the end of table */
 	{
 		.id = "INTC10B0",
maintainer
#3 lore raw
In reply to Mac Chiang
Quoted 8 lines · Mac Chiang

RT5650 is I2S codec integrated with HP and SPK. The HW board connects SoC I2S to RT5650 codec as below:

I2S0: ALC5650 aif1 for Speaker
I2S2: ALC5650 aif2 for Headphone

[...]

Applied to

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

Thanks!

[1/1] ASoC: Intel: sof_rt5682: add mtl_rt5650 support

      commit: a55ea47bb8743ee044550c5dfdd3cb3147602e05

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