Skip to content

Commit 2073572

Browse files
committed
ASoC: SOF: Intel: remove hyphen from AMP<index> name_prexix
For those amp with "AMP" name_prefix in the codec_info_list[], use the AMP<index> format to meet the UCM expectation. Fixes: 5cd5f8f ("ASoC: SOF: Intel: add hyphen between name and index to amp name_prefix") Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
1 parent 7161b25 commit 2073572

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

sound/soc/sof/intel/hda.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1260,7 +1260,15 @@ static struct snd_soc_acpi_adr_device *find_acpi_adr_device(struct device *dev,
12601260
"AMP", *amp_index);
12611261
break;
12621262
}
1263+
} else if (!strcmp(name_prefix, "AMP")) {
1264+
adr_dev[index].name_prefix = devm_kasprintf(dev, GFP_KERNEL, "%s%d",
1265+
name_prefix,
1266+
*amp_index);
12631267
} else {
1268+
/*
1269+
* The name_prefix will be the amp name if it is not "Left" or "AMP", set it to
1270+
* <name_prefix>-<amp_index> format. Like rt1320-1
1271+
*/
12641272
adr_dev[index].name_prefix = devm_kasprintf(dev, GFP_KERNEL, "%s-%d",
12651273
name_prefix,
12661274
*amp_index);

0 commit comments

Comments
 (0)