* [PATCH] drm/arc: Fix refcount leak in arcpgu_load
@ 2022-05-30 8:54 Miaoqian Lin
0 siblings, 0 replies; only message in thread
From: Miaoqian Lin @ 2022-05-30 8:54 UTC (permalink / raw)
To: Alexey Brodkin, David Airlie, Daniel Vetter, Thomas Zimmermann,
dri-devel, linux-kernel
Cc: linmq006
of_graph_get_remote_port_parent() returns a node pointer with refcount
incremented, we should use of_node_put() on it when done.
Add missing of_node_put() to avoid refcount leak.
Fixes: 3ea66a794fdc ("drm/arc: Inline arcpgu_drm_hdmi_init")
Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
---
drivers/gpu/drm/tiny/arcpgu.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/tiny/arcpgu.c b/drivers/gpu/drm/tiny/arcpgu.c
index f0fa3b15c341..6cbc4e9d382e 100644
--- a/drivers/gpu/drm/tiny/arcpgu.c
+++ b/drivers/gpu/drm/tiny/arcpgu.c
@@ -310,6 +310,7 @@ static int arcpgu_load(struct arcpgu_drm_private *arcpgu)
/* Locate drm bridge from the hdmi encoder DT node */
bridge = of_drm_find_bridge(encoder_node);
+ of_node_put(encoder_node);
if (!bridge)
return -EPROBE_DEFER;
--
2.25.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2022-05-30 8:55 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-30 8:54 [PATCH] drm/arc: Fix refcount leak in arcpgu_load Miaoqian Lin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox