diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2021-04-19 11:02:19 +0900 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-04-20 17:25:44 +0100 |
commit | 1a456b1c6be13514a8fc5c1a99e6763f491d17e9 (patch) | |
tree | 0508f4d1ac3a4d1fe11006713445a6f5613f7c1c /sound/soc/generic/simple-card-utils.c | |
parent | ec1af6c64db94e4f24e53011a77b2bf2220ae000 (diff) | |
download | linux-stable-1a456b1c6be13514a8fc5c1a99e6763f491d17e9.tar.gz linux-stable-1a456b1c6be13514a8fc5c1a99e6763f491d17e9.tar.bz2 linux-stable-1a456b1c6be13514a8fc5c1a99e6763f491d17e9.zip |
ASoC: audio-graph: move audio_graph_card_probe() to simple-card-utils.c
audio-graph-card2 can reuse audio_graph_card_probe().
This patch moves it to simple-card-utils.c.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87zgxv3uc4.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/generic/simple-card-utils.c')
-rw-r--r-- | sound/soc/generic/simple-card-utils.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sound/soc/generic/simple-card-utils.c b/sound/soc/generic/simple-card-utils.c index e1b7b30a4c8c..ed2cad6d9ac1 100644 --- a/sound/soc/generic/simple-card-utils.c +++ b/sound/soc/generic/simple-card-utils.c @@ -740,6 +740,23 @@ int asoc_simple_init_priv(struct asoc_simple_priv *priv, } EXPORT_SYMBOL_GPL(asoc_simple_init_priv); +int asoc_graph_card_probe(struct snd_soc_card *card) +{ + struct asoc_simple_priv *priv = snd_soc_card_get_drvdata(card); + int ret; + + ret = asoc_simple_init_hp(card, &priv->hp_jack, NULL); + if (ret < 0) + return ret; + + ret = asoc_simple_init_mic(card, &priv->mic_jack, NULL); + if (ret < 0) + return ret; + + return 0; +} +EXPORT_SYMBOL_GPL(asoc_graph_card_probe); + /* Module information */ MODULE_AUTHOR("Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>"); MODULE_DESCRIPTION("ALSA SoC Simple Card Utils"); |