Skip to content

Commit 3e75d06

Browse files
lucaceresoligregkh
authored andcommitted
drm/arcpgu: fix device node leak
commit ad3ac32 upstream. This function gets a device_node reference via of_graph_get_remote_port_parent() and stores it in encoder_node, but never puts that reference. Add it. There used to be a of_node_put(encoder_node) but it has been removed by mistake during a rework in commit 3ea66a7 ("drm/arc: Inline arcpgu_drm_hdmi_init"). Fixes: 3ea66a7 ("drm/arc: Inline arcpgu_drm_hdmi_init") Cc: stable@vger.kernel.org Reviewed-by: Louis Chauvet <louis.chauvet@bootlin.com> Link: https://patch.msgid.link/20260402-drm-arcgpu-fix-device-node-leak-v2-1-d773cf754ae5@bootlin.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent fa0c428 commit 3e75d06

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

drivers/gpu/drm/tiny/arcpgu.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,8 @@ DEFINE_DRM_GEM_DMA_FOPS(arcpgu_drm_ops);
248248
static int arcpgu_load(struct arcpgu_drm_private *arcpgu)
249249
{
250250
struct platform_device *pdev = to_platform_device(arcpgu->drm.dev);
251-
struct device_node *encoder_node = NULL, *endpoint_node = NULL;
251+
struct device_node *encoder_node __free(device_node) = NULL;
252+
struct device_node *endpoint_node = NULL;
252253
struct drm_connector *connector = NULL;
253254
struct drm_device *drm = &arcpgu->drm;
254255
struct resource *res;

0 commit comments

Comments
 (0)