diff options
author | Mengdong Lin <mengdong.lin@linux.intel.com> | 2016-11-03 01:04:12 +0800 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2016-11-04 11:16:51 -0600 |
commit | 17fb175520e5497d71351aa66a125324fcb625a7 (patch) | |
tree | 1224910f851f3d9ba89818ef6922666c416f578f /include/sound | |
parent | 676c6b5208f7ce6ccc7933ab210f24358ca99a7a (diff) | |
download | linux-17fb175520e5497d71351aa66a125324fcb625a7.tar.gz linux-17fb175520e5497d71351aa66a125324fcb625a7.tar.bz2 linux-17fb175520e5497d71351aa66a125324fcb625a7.zip |
ASoC: Define API to find a dai link
Define the API to find an existing DAI link of the soc card by matching
the ID, name and stream name.
Some cards may use unique ID for each DAI link, so matching ID is enough,
and name or stream name are not necessary. But user need to specify name
or stream name as well if not sure whether link ID is unique since most
cards use 0 as the default link ID.
Topology can use this API to find an existing BE link and configure it.
Signed-off-by: Mengdong Lin <mengdong.lin@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'include/sound')
-rw-r--r-- | include/sound/soc.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/sound/soc.h b/include/sound/soc.h index 4f1c784e44f6..c3a38ee2b006 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -1671,6 +1671,9 @@ int snd_soc_add_dai_link(struct snd_soc_card *card, struct snd_soc_dai_link *dai_link); void snd_soc_remove_dai_link(struct snd_soc_card *card, struct snd_soc_dai_link *dai_link); +struct snd_soc_dai_link *snd_soc_find_dai_link(struct snd_soc_card *card, + int id, const char *name, + const char *stream_name); int snd_soc_register_dai(struct snd_soc_component *component, struct snd_soc_dai_driver *dai_drv); |