diff options
Diffstat (limited to 'sound/soc/soc-core.c')
-rw-r--r-- | sound/soc/soc-core.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 6d3b203..674e588 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -1117,6 +1117,20 @@ static int soc_pcm_ioctl(struct snd_pcm_substream *substream, return snd_pcm_lib_ioctl(substream, cmd, arg); } +struct snd_soc_codec *snd_soc_card_get_codec(struct snd_soc_card *card, + const char *codec_name) +{ + struct snd_soc_codec *codec = NULL; + + list_for_each_entry(codec, &card->codec_dev_list, card_list) { + if (!strcmp(codec->name, codec_name)) + return codec; + } + + return codec; +} +EXPORT_SYMBOL(snd_soc_card_get_codec); + struct snd_pcm_substream *snd_soc_get_dai_substream(struct snd_soc_card *card, const char *dai_link, int stream) { |