Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp445452pxb; Thu, 25 Feb 2021 06:44:13 -0800 (PST) X-Google-Smtp-Source: ABdhPJy0I3tenAWHPDCI6DoW5fKqJQgY+VyMAzbuwHrg9JiwGp6EyrgVZDLKu/OEu40sJWYffsW4 X-Received: by 2002:a17:906:260a:: with SMTP id h10mr2995744ejc.392.1614264253610; Thu, 25 Feb 2021 06:44:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614264253; cv=none; d=google.com; s=arc-20160816; b=IZjO2LIM6PsZzOhid7nfBo88fUW9RJgqtMW8r0FTRakTHTMggX5wcg+tDfUFENzUvD mv7Rtp0MDh14vWVStprl3ryWq8QZpLPasXZA2j1nfuLLjXND1sv5fBgOnDHSn6RUaMTy qjnCpRPt1MhyNYxXYZ4G8W6rK56stZQ2kZhPnh2cvPQDCodE92eBx4sM8ljcFPS03bq8 4KeasqzWtHAX599r48+Vn5T/yEOUoaKMZdWKhKqynNm9qdiiD2Oc1YjcTZyAmK0CCMvD zMTIeMwyO4jDuNDJ3xLFiD21oWeyLloXSfAw8mLmetR+1OwPFxRo36rlcqgktYxw0qN3 4zNQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=K3fl6Z1FyblaQd+AGsW/EDiBLSCvu2gbQvhDswym/yg=; b=PLoeIxBeVHdBpYr2sxgM/7jadK2yL1/aJ1aTOzwG60uCCqgHLY8YWopOacM0QMXoA0 GjALav4Bi7ahjvEJ/nhR9LdU4diYAe55OtkpjDJfu2gRRyqYuaM3MzQw1Vown2wZQYOw pmqW9YiS/VXzwqOof/g+PfPOoS2ZV4ydUfbVIXDGoQqLSSXfv6A8nxT9dLYLsUpKzo3T BeGPxf+wOt34jz1dm6uThTKjGXQUVRhwjk2LSGtrxbGrKuHEVsqr5MbCBVhbiB6q58a9 +SkMaJedSNKzpg8P8+HqbuXZY27uVGO48z5ero+Aa0ctL9TnETJhRYWUn/4wkFF1OYG2 RICg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=NBlzBAwY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hq3si3499584ejc.692.2021.02.25.06.43.50; Thu, 25 Feb 2021 06:44:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=NBlzBAwY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229919AbhBYOnC (ORCPT + 99 others); Thu, 25 Feb 2021 09:43:02 -0500 Received: from mail.kernel.org ([198.145.29.99]:59078 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229498AbhBYOmx (ORCPT ); Thu, 25 Feb 2021 09:42:53 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 53B7964ECE; Thu, 25 Feb 2021 14:42:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1614264132; bh=4sHiq68F0g7bVZOgLUG764o38A+n0QBHmSbVULWttEU=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=NBlzBAwYS8G2iYlgShS3ec+hMTeAGBB9TqPXmfccfAhjp5G+Zon99QhzfGulHKN14 PreBRo6QfIcjxdt7aIUPFvKua6bd22UxddCqXwxom8k2apNdY6HQ1wcTpcEvjbhO75 +WBiwt+O1aboP6kOPzuq/eFwaelkP8ZZ1wrtZyDgL88SW7TfqUNEdPefBNO4DL9ZG6 p+UOtiHU2iYm8duMF3TfU3nxadNwg1eX+HqYePjks3dybD9lTux5Y5f4QlGCuhdN6o JZWtDjxzFYHMp4JzetBfAjpmzxyD3iojFm5nAGKR8kqDDuFF0RwFwvKAop5ggRsXuI QtvvOQaqK1R3g== Received: by mail-ej1-f47.google.com with SMTP id lr13so9245803ejb.8; Thu, 25 Feb 2021 06:42:12 -0800 (PST) X-Gm-Message-State: AOAM533lIc2g+soPYQVUzzKpOFbKjvfkSRk5ARM/OjivPtCCM/1Pvta8 /gaXVr/angOL3SRyW/bRhBsgqIlIDE118mQhCmI= X-Received: by 2002:a17:906:a896:: with SMTP id ha22mr2938761ejb.503.1614264130626; Thu, 25 Feb 2021 06:42:10 -0800 (PST) MIME-Version: 1.0 References: <1614243836-54718-1-git-send-email-yang.lee@linux.alibaba.com> In-Reply-To: <1614243836-54718-1-git-send-email-yang.lee@linux.alibaba.com> From: Krzysztof Kozlowski Date: Thu, 25 Feb 2021 15:41:58 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] media: exynos4-is: add missing call to of_node_put() To: Yang Li Cc: mchehab@kernel.org, Sylwester Nawrocki , linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, "linux-samsung-soc@vger.kernel.org" , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 25 Feb 2021 at 10:04, Yang Li wrote: > > In one of the error paths of the for_each_child_of_node() loop in > fimc_md_parse_one_endpoint, add missing call to of_node_put(). > > Fix the following coccicheck warning: > ./drivers/media/platform/exynos4-is/media-dev.c:489:1-23: WARNING: > Function "for_each_child_of_node" should have of_node_put() before > return around line 492. > > Reported-by: Abaci Robot Please make the reports public. Otherwise the actual credits should go to Coccinelle not to some hidden/unknown tool... > Signed-off-by: Yang Li > --- > drivers/media/platform/exynos4-is/media-dev.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/media/platform/exynos4-is/media-dev.c b/drivers/media/platform/exynos4-is/media-dev.c > index 8e1e892..467bc69 100644 > --- a/drivers/media/platform/exynos4-is/media-dev.c > +++ b/drivers/media/platform/exynos4-is/media-dev.c > @@ -489,6 +489,7 @@ static int fimc_md_parse_port_node(struct fimc_md *fmd, > for_each_child_of_node(port, ep) { > ret = fimc_md_parse_one_endpoint(fmd, ep); > if (ret < 0) > + of_node_put(ep); This is wrong... Best regards, Krzysztof