lkml.org 
[lkml]   [2022]   [Apr]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] of: Add missing of_node_put() before return
+Thomas

On Thu, Apr 21, 2022 at 7:23 AM Wan Jiabing <wanjiabing@vivo.com> wrote:
>
> Fix the following coccicheck error:
> drivers/of/platform.c:554:2-23: WARNING: Function "for_each_node_by_type"
> should have of_node_put() before return around line 560.

Especially since the code this fixes just landed, you should Cc the
author and reference the commit.

> Early exits from for_each_node_by_type() should decrement the node
> reference counter.
>
> Signed-off-by: Wan Jiabing <wanjiabing@vivo.com>
> ---
> drivers/of/platform.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)

This has to go via the DRM tree.

Fixes: 52b1b46c39ae ("of: Create platform devices for OF framebuffers")
Acked-by: Rob Herring <robh@kernel.org>

\
 
 \ /
  Last update: 2022-04-21 14:36    [W:0.041 / U:1.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site