Skip to contentSkip to conversation

ASoC: SOF: allow soundwire use desc->default_fw_filename

PATCH In review Kai Vehmanen 3 participants 7 messages Jan 25, 2021 – Jan 27, 2021

Subsystems (4)
lore
Share & tools
lore

Kai Vehmanen

author maintainer
#0 lore raw

PATCH 1/3 ASoC: SOF: allow soundwire use desc->default_fw_filename

From: Libin Yang <[email protected]>

The old code always uses sof_fw_filename in struct snd_soc_acpi_mach as the firmware name. However, firmware name should depend on the platform instead of the machine. For example, different machines may use the same soundwire link topology, but they are using the different firmware. In this case, it's hard to determine in struct snd_soc_acpi_mach which firmware it should use.

---
 sound/soc/sof/intel/hda.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
sound/soc/sof/intel/hda.c +4 -1
index 7e703ce22fcd..d99a552eea53 100644
@@ -1169,7 +1169,10 @@ static int hda_sdw_machine_select(struct snd_sof_dev *sdev)
 			mach->mach_params.links = mach->links;
 			mach->mach_params.link_mask = mach->link_mask;
 			mach->mach_params.platform = dev_name(sdev->dev);
-			pdata->fw_filename = mach->sof_fw_filename;
+			if (mach->sof_fw_filename)
+				pdata->fw_filename = mach->sof_fw_filename;
+			else
+				pdata->fw_filename = pdata->desc->default_fw_filename;
 			pdata->tplg_filename = mach->sof_tplg_filename;
 		} else {
 			dev_info(sdev->dev,
Signature · 1 line
2.29.2
author maintainer
#1 lore raw

PATCH 2/3 ASoC: Intel: tgl: remove sof_fw_filename set for tgl_3_in_1_default

From: Libin Yang <[email protected]>

tgl_3_in_1_default link topology may be used by both TGL-LP and TGL-H. Let's remove the sof_fw_filename setting in struct snd_soc_acpi_mach and use the default_fw_filename setting in struct sof_dev_desc.

---
 sound/soc/intel/common/soc-acpi-intel-tgl-match.c | 7 -------
 1 file changed, 7 deletions(-)
sound/soc/intel/common/soc-acpi-intel-tgl-match.c +0 -7
index 4933184df5f5..89ab462361a3 100644
@@ -358,14 +358,12 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_tgl_sdw_machines[] = {
 		.link_mask = 0x7,
 		.links = tgl_sdw_rt711_link1_rt1308_link2_rt715_link0,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-tgl.ri",
 		.sof_tplg_filename = "sof-tgl-rt715-rt711-rt1308-mono.tplg",
 	},
 	{
 		.link_mask = 0xF, /* 4 active links required */
 		.links = tgl_3_in_1_default,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-tgl.ri",
 		.sof_tplg_filename = "sof-tgl-rt711-rt1308-rt715.tplg",
 	},
 	{
@@ -377,35 +375,30 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_tgl_sdw_machines[] = {
 		.link_mask = 0xF,
 		.links = tgl_3_in_1_mono_amp,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-tgl.ri",
 		.sof_tplg_filename = "sof-tgl-rt711-rt1308-mono-rt715.tplg",
 	},
 	{
 		.link_mask = 0xF, /* 4 active links required */
 		.links = tgl_3_in_1_sdca,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-tgl.ri",
 		.sof_tplg_filename = "sof-tgl-rt711-rt1316-rt714.tplg",
 	},
 	{
 		.link_mask = 0x3, /* rt711 on link 0 and 2 rt1308s on link 1 */
 		.links = tgl_rvp,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-tgl.ri",
 		.sof_tplg_filename = "sof-tgl-rt711-rt1308.tplg",
 	},
 	{
 		.link_mask = 0x3, /* rt5682 on link0 & 2xmax98373 on link 1 */
 		.links = tgl_chromebook_base,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-tgl.ri",
 		.sof_tplg_filename = "sof-tgl-sdw-max98373-rt5682.tplg",
 	},
 	{
 		.link_mask = 0x1, /* this will only enable rt5682 for now */
 		.links = tgl_chromebook_base,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-tgl.ri",
 		.sof_tplg_filename = "sof-tgl-rt5682.tplg",
 	},
 	{},
Signature · 1 line
2.29.2
maintainer Tested-by on v1 2/3
#2 lore raw

Re: [PATCH 2/3] ASoC: Intel: tgl: remove sof_fw_filename set for tgl_3_in_1_default

Dne 25. 01. 21 v 8:04 Kai Vehmanen napsal(a):

Quoted 10 lines

From: Libin Yang <[email protected]>

tgl_3_in_1_default link topology may be used by both TGL-LP and TGL-H. Let's remove the sof_fw_filename setting in struct snd_soc_acpi_mach and use the default_fw_filename setting in struct sof_dev_desc.

Signature · 2 lines
Jaroslav Kysela <[email protected]>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.
author maintainer
#3 lore raw

PATCH 3/3 ASoC: Intel: adl: remove sof_fw_filename setting in ADL snd_soc_acpi_mach

In reply to Kai Vehmanen

From: Libin Yang <[email protected]>

ADL will use sof-adl-s.ri if it is ADL-S platform. So let's use the default_fw_filename in pdata->desc for the ADL FW filename.

---
 sound/soc/intel/common/soc-acpi-intel-adl-match.c | 1 -
 1 file changed, 1 deletion(-)
sound/soc/intel/common/soc-acpi-intel-adl-match.c +0 -1
index 06b233d63b73..0aca340ebc25 100644
@@ -44,7 +44,6 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_adl_sdw_machines[] = {
 		.link_mask = 0x1, /* link0 required */
 		.links = adl_rvp,
 		.drv_name = "sof_sdw",
-		.sof_fw_filename = "sof-adl.ri",
 		.sof_tplg_filename = "sof-adl-rt711.tplg",
 	},
 	{},
Signature · 1 line
2.29.2
maintainer Tested-by on v1 1/3
#4 lore raw
In reply to Kai Vehmanen

Dne 25. 01. 21 v 8:04 Kai Vehmanen napsal(a):

Quoted 9 lines

From: Libin Yang <[email protected]>

The old code always uses sof_fw_filename in struct snd_soc_acpi_mach as the firmware name. However, firmware name should depend on the platform instead of the machine. For example, different machines may use the same soundwire link topology, but they are using the different firmware. In this case, it's hard to determine in struct snd_soc_acpi_mach which firmware it should use.

Quoted 4 lines
Signature · 2 lines
Jaroslav Kysela <[email protected]>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.
maintainer
#5 lore raw

Re: (subset) [PATCH 1/3] ASoC: SOF: allow soundwire use desc->default_fw_filename

In reply to Kai Vehmanen
Quoted 6 lines · Kai Vehmanen

The old code always uses sof_fw_filename in struct snd_soc_acpi_mach as the firmware name. However, firmware name should depend on the platform instead of the machine. For example, different machines may use the same soundwire link topology, but they are using the different firmware. In this case, it's hard to determine in struct snd_soc_acpi_mach which firmware it should use.

Applied to

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

Thanks!

[1/3] ASoC: SOF: allow soundwire use desc->default_fw_filename

      commit: 7da99ef9757a3dd6e66a9b4854c5e58cd65a0b9a
[2/3] ASoC: Intel: tgl: remove sof_fw_filename set for tgl_3_in_1_default
      commit: 3d14932527ff09517f052e54e7c25d676120b33a

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

maintainer
#6 lore raw

Re: (subset) [PATCH 1/3] ASoC: SOF: allow soundwire use desc->default_fw_filename

In reply to Kai Vehmanen
Quoted 6 lines · Kai Vehmanen

The old code always uses sof_fw_filename in struct snd_soc_acpi_mach as the firmware name. However, firmware name should depend on the platform instead of the machine. For example, different machines may use the same soundwire link topology, but they are using the different firmware. In this case, it's hard to determine in struct snd_soc_acpi_mach which firmware it should use.

Applied to

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

Thanks!

[3/3] ASoC: Intel: adl: remove sof_fw_filename setting in ADL snd_soc_acpi_mach

      commit: e32df142359fb6f4d27977b7652549f0844aa62f

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