public inbox for linux-sound@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] ALSA: aoa/onyx: Fix OF node leak on probe failure
@ 2026-04-02  2:35 wangdich9700
  2026-04-02 10:43 ` Takashi Iwai
  0 siblings, 1 reply; 2+ messages in thread
From: wangdich9700 @ 2026-04-02  2:35 UTC (permalink / raw)
  To: johannes, perex, tiwai, wangdich9700; +Cc: linux-sound, wangdicheng

From: wangdicheng <wangdicheng@kylinos.cn>

Add missing of_node_put() in the error path.

Signed-off-by: wangdicheng <wangdicheng@kylinos.cn>
---
 sound/aoa/codecs/onyx.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/aoa/codecs/onyx.c b/sound/aoa/codecs/onyx.c
index 04961c456d2c..fea12d3a06a9 100644
--- a/sound/aoa/codecs/onyx.c
+++ b/sound/aoa/codecs/onyx.c
@@ -985,6 +985,7 @@ static int onyx_i2c_probe(struct i2c_client *client)
 	printk(KERN_DEBUG PFX "created and attached onyx instance\n");
 	return 0;
  fail:
+	of_node_put(onyx->codec.node);
 	kfree(onyx);
 	return -ENODEV;
 }
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-04-02 10:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-02  2:35 [PATCH 1/2] ALSA: aoa/onyx: Fix OF node leak on probe failure wangdich9700
2026-04-02 10:43 ` Takashi Iwai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox