summaryrefslogtreecommitdiff
path: root/sound/ppc
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-02-18 17:05:24 +0300
committerTakashi Iwai <tiwai@suse.de>2019-02-20 00:20:46 +0300
commit5e2c9465825595e3c295085c1ffb14eb239e3278 (patch)
tree5f022d74692a17edc2882fe41769d30630b06d84 /sound/ppc
parent00178c9175402c364a1456742c0d71bdc4189e0c (diff)
downloadlinux-5e2c9465825595e3c295085c1ffb14eb239e3278.tar.xz
ALSA: ppc: Fix of-node refcount unbalance
We forgot to unreference the node when aborting from the loop of for_each_child_of_node() in snd_pmac_tumbler_init(). This leads to unbalanced node refcount. Fix it by adding the missing of_node_put() call. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/ppc')
-rw-r--r--sound/ppc/tumbler.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sound/ppc/tumbler.c b/sound/ppc/tumbler.c
index 6d7ffffcce95..78e5798ae967 100644
--- a/sound/ppc/tumbler.c
+++ b/sound/ppc/tumbler.c
@@ -1371,6 +1371,7 @@ int snd_pmac_tumbler_init(struct snd_pmac *chip)
mix->anded_reset = 1;
if (of_get_property(np, "layout-id", NULL))
mix->reset_on_sleep = 0;
+ of_node_put(np);
break;
}
}