Re: [PATCH] drm/logicvc: Fix device node reference leak in logicvc_drm_config_parse()

From: Luca Ceresoli

Date: Thu Jan 29 2026 - 17:01:56 EST


On Thu Jan 29, 2026 at 5:21 PM CET, Felix Gu wrote:
> The logicvc_drm_config_parse() function calls of_get_child_by_name() to
> find the "layers" node but fails to release the reference, leading to a
> device node reference leak.
>
> Fix this by using the __free(device_node) cleanup attribute to automatic
> release the reference when the variable goes out of scope.
>
> Fixes: efeeaefe9be5 ("drm: Add support for the LogiCVC display controller")
> Signed-off-by: Felix Gu <ustc.gu@xxxxxxxxx>

Reviewed-by: Luca Ceresoli <luca.ceresoli@xxxxxxxxxxx>

--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com