Unverified Commit 1934906b authored by Brent Lu's avatar Brent Lu Committed by Mark Brown
Browse files

ASoC: Intel: sof_nau8825: mach cleanup for adl boards



Add a common entry in enumeration table for all nau8825 boards
with/without speaker amplifier. All other adl_nau8825_def entries
become redundant so get removed.

Reviewed-by: default avatarBard Liao <yung-chuan.liao@linux.intel.com>
Signed-off-by: default avatarBrent Lu <brent.lu@intel.com>
Signed-off-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://msgid.link/r/20240327162408.63953-9-pierre-louis.bossart@linux.intel.com


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 1504a768
Loading
Loading
Loading
Loading
+11 −43
Original line number Diff line number Diff line
@@ -7,6 +7,7 @@

#include <sound/soc-acpi.h>
#include <sound/soc-acpi-intel-match.h>
#include <sound/soc-acpi-intel-ssp-common.h>

static const struct snd_soc_acpi_codecs essx_83x6 = {
	.num_codecs = 3,
@@ -467,11 +468,6 @@ static const struct snd_soc_acpi_codecs adl_rt5682_rt5682s_hp = {
	.codecs = {"10EC5682", "RTL5682"},
};

static const struct snd_soc_acpi_codecs adl_rt1015p_amp = {
	.num_codecs = 1,
	.codecs = {"RTL1015"}
};

static const struct snd_soc_acpi_codecs adl_rt1019p_amp = {
	.num_codecs = 1,
	.codecs = {"RTL1019"}
@@ -487,11 +483,6 @@ static const struct snd_soc_acpi_codecs adl_lt6911_hdmi = {
	.codecs = {"INTC10B0"}
};

static const struct snd_soc_acpi_codecs adl_nau8318_amp = {
	.num_codecs = 1,
	.codecs = {"NVTN2012"}
};

static struct snd_soc_acpi_codecs adl_rt5650_amp = {
	.num_codecs = 1,
	.codecs = {"10EC5650"}
@@ -526,20 +517,6 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_adl_machines[] = {
		.quirk_data = &adl_rt1019p_amp,
		.sof_tplg_filename = "sof-adl-rt1019-nau8825.tplg",
	},
	{
		.id = "10508825",
		.drv_name = "adl_nau8825_def",
		.machine_quirk = snd_soc_acpi_codec_list,
		.quirk_data = &adl_max98373_amp,
		.sof_tplg_filename = "sof-adl-max98373-nau8825.tplg",
	},
	{
		.id = "10508825",
		.drv_name = "adl_nau8825_def",
		.machine_quirk = snd_soc_acpi_codec_list,
		.quirk_data = &adl_max98360a_amp,
		.sof_tplg_filename = "sof-adl-max98360a-nau8825.tplg",
	},
	{
		.comp_ids = &adl_rt5682_rt5682s_hp,
		.drv_name = "adl_rt5682_def",
@@ -547,25 +524,6 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_adl_machines[] = {
		.quirk_data = &adl_rt1019p_amp,
		.sof_tplg_filename = "sof-adl-rt1019-rt5682.tplg",
	},
	{
		.id = "10508825",
		.drv_name = "adl_nau8825_def",
		.machine_quirk = snd_soc_acpi_codec_list,
		.quirk_data = &adl_rt1015p_amp,
		.sof_tplg_filename = "sof-adl-rt1015-nau8825.tplg",
	},
	{
		.id = "10508825",
		.drv_name = "adl_nau8825_def",
		.machine_quirk = snd_soc_acpi_codec_list,
		.quirk_data = &adl_nau8318_amp,
		.sof_tplg_filename = "sof-adl-nau8318-nau8825.tplg",
	},
	{
		.id = "10508825",
		.drv_name = "adl_nau8825_def",
		.sof_tplg_filename = "sof-adl-nau8825.tplg",
	},
	{
		.comp_ids = &adl_rt5682_rt5682s_hp,
		.drv_name = "adl_rt5682_def",
@@ -621,6 +579,16 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_adl_machines[] = {
		.quirk_data = &adl_max98360a_amp,
		.sof_tplg_filename = "sof-adl-max98360a-da7219.tplg",
	},
	/* place boards for each headphone codec: sof driver will complete the
	 * tplg name and machine driver will detect the amp type
	 */
	{
		.id = NAU8825_ACPI_HID,
		.drv_name = "adl_nau8825_def",
		.sof_tplg_filename = "sof-adl", /* the tplg suffix is added at run time */
		.tplg_quirk_mask = SND_SOC_ACPI_TPLG_INTEL_AMP_NAME |
					SND_SOC_ACPI_TPLG_INTEL_CODEC_NAME,
	},
	/* place amp-only boards in the end of table */
	{
		.id = "CSC3541",