diff options
author | Takashi Iwai <tiwai@suse.de> | 2017-08-02 17:11:45 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2017-08-02 17:11:45 +0200 |
commit | 5ef26e966d3fd105ad9a7e8e8f6d12c7fbd4c03d (patch) | |
tree | dd5c2ce3daab2e398ab8c0fb852587b647131568 /sound/soc/generic/audio-graph-card.c | |
parent | ALSA: hda - Fix speaker output from VAIO VPCL14M1R (diff) | |
parent | Merge remote-tracking branches 'asoc/fix/rt5663', 'asoc/fix/rt5665', 'asoc/fi... (diff) | |
download | linux-5ef26e966d3fd105ad9a7e8e8f6d12c7fbd4c03d.tar.xz linux-5ef26e966d3fd105ad9a7e8e8f6d12c7fbd4c03d.zip |
Merge tag 'asoc-fix-v4.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Fixes for v4.13
Quite a few fixes here that have been sent since the merge window, the
biggest one is the fix from Tony for some confusion with the device
property API which was causing issues with the of-graph card. This is
fixed with some changes in the graph API itself as it seemed very likely
to be error prone.
Diffstat (limited to 'sound/soc/generic/audio-graph-card.c')
-rw-r--r-- | sound/soc/generic/audio-graph-card.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sound/soc/generic/audio-graph-card.c b/sound/soc/generic/audio-graph-card.c index 105ec3a6e30d..de2550c7a96b 100644 --- a/sound/soc/generic/audio-graph-card.c +++ b/sound/soc/generic/audio-graph-card.c @@ -224,9 +224,11 @@ static int asoc_graph_card_parse_of(struct graph_card_data *priv) of_for_each_phandle(&it, rc, node, "dais", NULL, 0) { ret = asoc_graph_card_dai_link_of(it.node, priv, idx++); - of_node_put(it.node); - if (ret < 0) + if (ret < 0) { + of_node_put(it.node); + return ret; + } } return asoc_simple_card_parse_card_name(card, NULL); @@ -239,10 +241,8 @@ static int asoc_graph_get_dais_count(struct device *dev) int count = 0; int rc; - of_for_each_phandle(&it, rc, node, "dais", NULL, 0) { + of_for_each_phandle(&it, rc, node, "dais", NULL, 0) count++; - of_node_put(it.node); - } return count; } |