Skip to content
8 changes: 4 additions & 4 deletions include/sound/soc-acpi.h
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,8 @@ struct snd_soc_acpi_endpoint {
* @name_prefix: string used for codec controls
*/
struct snd_soc_acpi_adr_device {
const u64 adr;
const u8 num_endpoints;
u64 adr;
u8 num_endpoints;
const struct snd_soc_acpi_endpoint *endpoints;
const char *name_prefix;
};
Expand All @@ -131,8 +131,8 @@ struct snd_soc_acpi_adr_device {
*/

struct snd_soc_acpi_link_adr {
const u32 mask;
const u32 num_adr;
u32 mask;
u32 num_adr;
const struct snd_soc_acpi_adr_device *adr_d;
};

Expand Down
2 changes: 2 additions & 0 deletions include/sound/soc_sdw_utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ struct asoc_sdw_codec_info {
const int part_id;
const int version_id;
const char *codec_name;
const char *name_prefix;
Copy link

Copilot AI May 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A new field 'name_prefix' has been added to asoc_sdw_codec_info without accompanying documentation. Please add a descriptive comment to clarify its intended purpose and usage.

Copilot uses AI. Check for mistakes.
int amp_num;
const u8 acpi_id[ACPI_ID_LEN];
const bool ignore_internal_dmic;
Expand Down Expand Up @@ -168,6 +169,7 @@ int asoc_sdw_count_sdw_endpoints(struct snd_soc_card *card, int *num_devs, int *

struct asoc_sdw_dailink *asoc_sdw_find_dailink(struct asoc_sdw_dailink *dailinks,
const struct snd_soc_acpi_endpoint *new);
int asoc_sdw_get_dai_type(u32 type);

int asoc_sdw_parse_sdw_endpoints(struct snd_soc_card *card,
struct asoc_sdw_dailink *soc_dais,
Expand Down
8 changes: 6 additions & 2 deletions sound/soc/intel/common/sof-function-topology-lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,11 +126,15 @@ int sof_sdw_get_tplg_files(struct snd_soc_card *card, const struct snd_soc_acpi_
if (!ret) {
release_firmware(fw);
} else {
dev_dbg(card->dev, "Failed to open topology file: %s\n", (*tplg_files)[i]);
dev_warn(card->dev,
"Failed to open topology file: %s, you might need to\n",
(*tplg_files)[i]);
dev_warn(card->dev,
"download it from https://github.com/thesofproject/sof-bin/\n");
return 0;
}
}

return tplg_num;
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

commit message last sentence needs rewording


EXPORT_SYMBOL_GPL(sof_sdw_get_tplg_files);
30 changes: 29 additions & 1 deletion sound/soc/sdw_utils/soc_sdw_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ static const struct snd_kcontrol_new rt700_controls[] = {
struct asoc_sdw_codec_info codec_info_list[] = {
{
.part_id = 0x700,
.name_prefix = "rt700",
.dais = {
{
.direction = {true, true},
Expand All @@ -77,6 +78,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x711,
.name_prefix = "rt711",
.version_id = 3,
.dais = {
{
Expand All @@ -97,6 +99,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x711,
.name_prefix = "rt711",
.version_id = 2,
.dais = {
{
Expand All @@ -117,6 +120,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x712,
.name_prefix = "rt712",
.version_id = 3,
.dais = {
{
Expand Down Expand Up @@ -158,6 +162,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x1712,
.name_prefix = "rt712-dmic",
.version_id = 3,
.dais = {
{
Expand All @@ -172,6 +177,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x713,
.name_prefix = "rt713",
.version_id = 3,
.dais = {
{
Expand Down Expand Up @@ -199,6 +205,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x1713,
.name_prefix = "rt713-dmic",
.version_id = 3,
.dais = {
{
Expand All @@ -213,6 +220,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x1308,
.name_prefix = "rt1308",
.acpi_id = "10EC1308",
.dais = {
{
Expand All @@ -235,6 +243,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x1316,
.name_prefix = "rt1316",
.dais = {
{
.direction = {true, true},
Expand All @@ -255,6 +264,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x1318,
.name_prefix = "rt1318",
.dais = {
{
.direction = {true, true},
Expand All @@ -275,6 +285,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x1320,
.name_prefix = "rt1320",
.dais = {
{
.direction = {true, false},
Expand All @@ -295,6 +306,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x714,
.name_prefix = "rt714",
.version_id = 3,
.ignore_internal_dmic = true,
.dais = {
Expand All @@ -310,6 +322,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x715,
.name_prefix = "rt715",
.version_id = 3,
.ignore_internal_dmic = true,
.dais = {
Expand All @@ -325,6 +338,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x714,
.name_prefix = "rt714",
.version_id = 2,
.ignore_internal_dmic = true,
.dais = {
Expand All @@ -340,6 +354,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x715,
.name_prefix = "rt715",
.version_id = 2,
.ignore_internal_dmic = true,
.dais = {
Expand All @@ -355,6 +370,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x721,
.name_prefix = "rt721",
.version_id = 3,
.dais = {
{
Expand Down Expand Up @@ -397,6 +413,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x722,
.name_prefix = "rt722",
.version_id = 3,
.dais = {
{
Expand Down Expand Up @@ -441,6 +458,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x8373,
.name_prefix = "Left",
.dais = {
{
.direction = {true, true},
Expand All @@ -460,6 +478,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x8363,
.name_prefix = "Left",
.dais = {
{
.direction = {true, false},
Expand All @@ -479,6 +498,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x5682,
.name_prefix = "rt5682",
.dais = {
{
.direction = {true, true},
Expand All @@ -496,6 +516,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x3556,
.name_prefix = "AMP",
.dais = {
{
.direction = {true, false},
Expand Down Expand Up @@ -548,6 +569,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x4242,
.name_prefix = "cs42l42",
.dais = {
{
.direction = {true, true},
Expand All @@ -565,6 +587,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x4243,
.name_prefix = "cs42l43",
.codec_name = "cs42l43-codec",
.count_sidecar = asoc_sdw_bridge_cs35l56_count_sidecar,
.add_sidecar = asoc_sdw_bridge_cs35l56_add_sidecar,
Expand Down Expand Up @@ -616,6 +639,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0xaaaa, /* generic codec mockup */
.name_prefix = "sdw_mockup_mmulti-function",
.version_id = 0,
.dais = {
{
Expand All @@ -641,6 +665,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0xaa55, /* headset codec mockup */
.name_prefix = "sdw_mockup_headset0",
.version_id = 0,
.dais = {
{
Expand All @@ -654,6 +679,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x55aa, /* amplifier mockup */
.name_prefix = "sdw_mockup_amp1",
.version_id = 0,
.dais = {
{
Expand All @@ -667,6 +693,7 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
{
.part_id = 0x5555,
.name_prefix = "sdw_mockup_mic0",
.version_id = 0,
.dais = {
{
Expand Down Expand Up @@ -1194,7 +1221,7 @@ struct asoc_sdw_dailink *asoc_sdw_find_dailink(struct asoc_sdw_dailink *dailinks
}
EXPORT_SYMBOL_NS(asoc_sdw_find_dailink, "SND_SOC_SDW_UTILS");

static int asoc_sdw_get_dai_type(u32 type)
int asoc_sdw_get_dai_type(u32 type)
{
switch (type) {
case SDCA_FUNCTION_TYPE_SMART_AMP:
Expand All @@ -1212,6 +1239,7 @@ static int asoc_sdw_get_dai_type(u32 type)
return -EINVAL;
}
}
EXPORT_SYMBOL_NS(asoc_sdw_get_dai_type, "SND_SOC_SDW_UTILS");

/*
* Check if the SDCA endpoint is present by the SDW peripheral
Expand Down
11 changes: 10 additions & 1 deletion sound/soc/sof/fw-file-profile.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ static int sof_test_topology_file(struct device *dev,
if (!profile->tplg_path || !profile->tplg_name)
return 0;

/* Dummy topology does not exist and should not be used */
if (strstr(profile->tplg_name, "dummy"))
return 0;

tplg_filename = kasprintf(GFP_KERNEL, "%s/%s", profile->tplg_path,
profile->tplg_name);
if (!tplg_filename)
Expand Down Expand Up @@ -266,6 +270,7 @@ static void sof_print_profile_info(struct snd_sof_dev *sdev,
enum sof_ipc_type ipc_type,
struct sof_loadable_file_profile *profile)
{
struct snd_sof_pdata *plat_data = sdev->pdata;
struct device *dev = sdev->dev;

if (ipc_type != profile->ipc_type)
Expand All @@ -282,7 +287,11 @@ static void sof_print_profile_info(struct snd_sof_dev *sdev,

if (profile->fw_lib_path)
dev_info(dev, " Firmware lib path: %s\n", profile->fw_lib_path);
dev_info(dev, " Topology file: %s/%s\n", profile->tplg_path, profile->tplg_name);

if(plat_data->machine->get_function_tplg_files && !plat_data->disable_function_topology)
dev_info(dev, " Topology file: function topologies\n");
else
dev_info(dev, " Topology file: %s/%s\n", profile->tplg_path, profile->tplg_name);
}

int sof_create_ipc_file_profile(struct snd_sof_dev *sdev,
Expand Down
1 change: 1 addition & 0 deletions sound/soc/sof/intel/apl.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,4 +118,5 @@ const struct sof_intel_dsp_desc apl_chip_info = {
.power_down_dsp = hda_power_down_dsp,
.disable_interrupts = hda_dsp_disable_interrupts,
.hw_ip_version = SOF_INTEL_CAVS_1_5_PLUS,
.platform = "apl",
};
2 changes: 2 additions & 0 deletions sound/soc/sof/intel/cnl.c
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,7 @@ const struct sof_intel_dsp_desc cnl_chip_info = {
.power_down_dsp = hda_power_down_dsp,
.disable_interrupts = hda_dsp_disable_interrupts,
.hw_ip_version = SOF_INTEL_CAVS_1_8,
.platform = "cnl",
};

/*
Expand Down Expand Up @@ -515,5 +516,6 @@ const struct sof_intel_dsp_desc jsl_chip_info = {
.power_down_dsp = hda_power_down_dsp,
.disable_interrupts = hda_dsp_disable_interrupts,
.hw_ip_version = SOF_INTEL_CAVS_2_0,
.platform = "jsl",
};
EXPORT_SYMBOL_NS(jsl_chip_info, "SND_SOC_SOF_INTEL_CNL");
Loading
Loading