aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/sound/soc.h
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2023-06-20 02:14:06 +0000
committerMark Brown <broonie@kernel.org>2023-06-20 12:49:21 +0100
commit05722a0ce6fbd1c603ec0f0ecb5ed839dd561ac7 (patch)
treee6a420fb5fd20fe525c93559dd23fe060e840d56 /include/sound/soc.h
parentASoC: max98388: fix error code in probe() (diff)
downloadwireguard-linux-05722a0ce6fbd1c603ec0f0ecb5ed839dd561ac7.tar.xz
wireguard-linux-05722a0ce6fbd1c603ec0f0ecb5ed839dd561ac7.zip
ASoC: soc-core.c: add snd_soc_{of_}get_dlc()
Current soc-core.c has snd_soc_{of_}get_dai_name() to get DAI name for dlc (snd_soc_dai_link_component). It gets .dai_name, but we need .of_node too. Therefor user need to arrange. It will be more useful if it gets both .dai_name and .of_node. This patch adds snd_soc_{of_}get_dlc() for it, and existing functions uses it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://lore.kernel.org/r/87r0q6dgnm.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'include/sound/soc.h')
-rw-r--r--include/sound/soc.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/sound/soc.h b/include/sound/soc.h
index a7ae8b26737e..943f0a1b2d27 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -1309,6 +1309,12 @@ unsigned int snd_soc_daifmt_parse_clock_provider_raw(struct device_node *np,
snd_soc_daifmt_parse_clock_provider_as_bitmap(np, prefix))
int snd_soc_get_stream_cpu(struct snd_soc_dai_link *dai_link, int stream);
+int snd_soc_get_dlc(const struct of_phandle_args *args,
+ struct snd_soc_dai_link_component *dlc);
+int snd_soc_of_get_dlc(struct device_node *of_node,
+ struct of_phandle_args *args,
+ struct snd_soc_dai_link_component *dlc,
+ int index);
int snd_soc_get_dai_id(struct device_node *ep);
int snd_soc_get_dai_name(const struct of_phandle_args *args,
const char **dai_name);