diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2017-06-16 04:39:11 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2017-06-16 19:58:39 +0300 |
commit | fa2760dd366c735637504d1d7efab7688391c6b4 (patch) | |
tree | f592812182200a312c3d01a2ba8e8ba26c338936 /sound/soc/generic | |
parent | b31f11d036e689ba9e60d581ffe8e032a6305da9 (diff) | |
download | linux-fa2760dd366c735637504d1d7efab7688391c6b4.tar.xz |
ASoC: simple-card: use asoc_simple_card_of_parse_widgets()
Current simple card driver is supporting widgets on DT,
other simple/audio card drivers will support it.
Encapsulation is one of simple card util's purpose.
Let's use asoc_simple_card_of_parse_widgets
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/generic')
-rw-r--r-- | sound/soc/generic/simple-card.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/sound/soc/generic/simple-card.c b/sound/soc/generic/simple-card.c index 7b2533c7f82e..8b7b47251fe1 100644 --- a/sound/soc/generic/simple-card.c +++ b/sound/soc/generic/simple-card.c @@ -354,13 +354,9 @@ static int asoc_simple_card_parse_of(struct simple_card_data *priv) dai_link = of_get_child_by_name(node, PREFIX "dai-link"); - /* The off-codec widgets */ - if (of_property_read_bool(node, PREFIX "widgets")) { - ret = snd_soc_of_parse_audio_simple_widgets(card, - PREFIX "widgets"); - if (ret) - goto card_parse_end; - } + ret = asoc_simple_card_of_parse_widgets(card, PREFIX); + if (ret < 0) + goto card_parse_end; ret = asoc_simple_card_of_parse_routing(card, PREFIX, 1); if (ret < 0) |