Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp144413yba; Fri, 12 Apr 2019 00:14:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqyqXLex83iMyc3n9j6Q08Da2j+lQiT7SKXklkOooThPMIolmJ6Ux6Kx+78fbSZ2xSnA5XRs X-Received: by 2002:aa7:8096:: with SMTP id v22mr26040906pff.94.1555053242440; Fri, 12 Apr 2019 00:14:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555053242; cv=none; d=google.com; s=arc-20160816; b=ibpSYMoZfrYQW1xa7/L2WCFRsW3znFDEATAIzBnoeuxwkXppmbl+/FJejYVMkf28nM L1VGEEt59ZRGzR6Q1yGwtDg4/5t1/ys/pTWS0kPU1sU69iFhCqz9aGUj/FqQ4KKyQQ0l PLUvcWIOwDncDuWKGwHiNZpGY3cS/BzHH/0jm1k2iNKi/u8CSJeR3CV66Xsnsc8VB6LX Abgwbel6Hrn1giV/4Lc1YEPTEzfRnI4r/dKqjjGefZslNfWbqrTF9Blz7LRcALbcaaJn cz2G0F67dCpIZr/xRc00hv8WlRvwuHeaQfq0YQ6bcq0ENg+xrtP4lE1q4b/QEBl+InIl jh2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=cUDRUvfw7fqVRmcYqiL+aO4CkbjdbUW/EnMoZrGCRKs=; b=lp4YF7k8PSFknVTtPm3u9d2QQjnZIzpANEyCtDk3SfMqeCaEbsERYTfInfaOw6EQ27 IH+/9Xxq7nC1BsKvscgpXmgMWtkjKuq79BFT8iVxLuQxk4LYZqGdcg6FFD2C52+pMwwJ smbypujkra2lSUWjA83NduDgGR1BNtvP7b3kPgKnM1RyfdjnOx+Xs/eie6f5nVrvv1Uy 6Syx8VtQtt8OCPqbW2Mx9C0MIKbDz14lnQIuBzkBLCxvSgyCn+HEf984TRqXkJ+9fn2f E4ZgLASt122rj/edToQfXQe9yL890s2JCPyEWC7Nlz0i35eKu2jk60mkJDuSE1I9hLtl nl7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="G9/FVv21"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id i3si15682240pgq.350.2019.04.12.00.13.46; Fri, 12 Apr 2019 00:14:02 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="G9/FVv21"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1727027AbfDLHM7 (ORCPT + 99 others); Fri, 12 Apr 2019 03:12:59 -0400 Received: from mail.kernel.org ([198.145.29.99]:48818 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726061AbfDLHM7 (ORCPT ); Fri, 12 Apr 2019 03:12:59 -0400 Received: from mail-lj1-f175.google.com (mail-lj1-f175.google.com [209.85.208.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2CFF52082E; Fri, 12 Apr 2019 07:12:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1555053178; bh=cUDRUvfw7fqVRmcYqiL+aO4CkbjdbUW/EnMoZrGCRKs=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=G9/FVv217tAuNqtbpbaTOBZaQpwd/0V7RuiAQiQ4WEZkd7Bc51pHJv2J6nsilGeeh HkjHEfovD9WgX8kP1SshShu4xDNuttLcAILrGo03AqFzGpRxwrS5WApkGpOuxwdvI3 RG3KTC9tKHCBRVGGRHh+YpLdBwBokUfYJoz8exBE= Received: by mail-lj1-f175.google.com with SMTP id f23so7911079ljc.0; Fri, 12 Apr 2019 00:12:58 -0700 (PDT) X-Gm-Message-State: APjAAAXSPkf4SQNoUp3E7REnY2kj+0LuE1IkVgSFMfVofzKwnKPCcnrE Moto6zsvsUzfN4WwrMbcvON2NQZayS280DtsQnM= X-Received: by 2002:a2e:74f:: with SMTP id i15mr23842825ljd.156.1555053176438; Fri, 12 Apr 2019 00:12:56 -0700 (PDT) MIME-Version: 1.0 References: <1555048943-39589-1-git-send-email-wen.yang99@zte.com.cn> <1555048943-39589-5-git-send-email-wen.yang99@zte.com.cn> In-Reply-To: <1555048943-39589-5-git-send-email-wen.yang99@zte.com.cn> From: Krzysztof Kozlowski Date: Fri, 12 Apr 2019 09:12:45 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 4/5] pinctrl: samsung: fix leaked of_node references To: Wen Yang Cc: linux-kernel@vger.kernel.org, wang.yi59@zte.com.cn, Linus Walleij , Tomasz Figa , Krzysztof Kozlowski , Sylwester Nawrocki , Kukjin Kim , "linux-samsung-soc@vger.kernel.org" , linux-gpio@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 12 Apr 2019 at 08:01, Wen Yang wrote: > > The call to of_find_compatible_node returns a node pointer with refcount > incremented thus it must be explicitly decremented after the last > usage. > > Detected by coccinelle with the following warnings: > ./drivers/pinctrl/samsung/pinctrl-exynos-arm.c:76:2-8: ERROR: missing of_node_put; acquired a node pointer with refcount incremented on line 66, but without a corresponding object release within this function. > ./drivers/pinctrl/samsung/pinctrl-exynos-arm.c:82:1-7: ERROR: missing of_node_put; acquired a node pointer with refcount incremented on line 66, but without a corresponding object release within this function. > > Signed-off-by: Wen Yang Reviewed-by: Krzysztof Kozlowski Best regards, Krzysztof