From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 13D99C2D0DB for ; Tue, 28 Jan 2020 14:47:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D071020716 for ; Tue, 28 Jan 2020 14:47:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1580222828; bh=iUtRt/4A0EKtUxFN7POXi60okHJXln+goaL3CNV6aQo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=jQx+GfW/90PsezsJBv3Gu9gecdNtEP7kFT5XkWxNI4PM2taUo/ockkTcTo5P/YqEk wOn+qBbpEn6qRWYQbPuhVRHkn8iWjVcoG1To4RBmHjheHkfz3jaw1cC2XFmJQwpFRH RLUXXTeEWP13Y+03FxC3pLzy0XoXfSt3IvhoacL8= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727093AbgA1OrH (ORCPT ); Tue, 28 Jan 2020 09:47:07 -0500 Received: from mail.kernel.org ([198.145.29.99]:56152 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727792AbgA1OIM (ORCPT ); Tue, 28 Jan 2020 09:08:12 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 76EAB22522; Tue, 28 Jan 2020 14:08:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1580220491; bh=iUtRt/4A0EKtUxFN7POXi60okHJXln+goaL3CNV6aQo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=pZavAVhOX8aoBNNB3P6BlAgcK9NcLCP/xn+uU0h5K0dsOIh8q19Ry+7yMzaEOWsgx hp7c7G1rNAfsgY/e/eTSuzP8IfAWwjHeALOcfx8j3gGYCWn/JZ6LIKEOGLbdtK6VhT qU86Afgo/hcrxN5wdVj5VeYaRhNe5p+jKguY6Aec= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Yangtao Li , Stephen Boyd , Sasha Levin Subject: [PATCH 4.4 028/183] clk: vf610: fix refcount leak in vf610_clocks_init() Date: Tue, 28 Jan 2020 15:04:07 +0100 Message-Id: <20200128135832.847402064@linuxfoundation.org> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200128135829.486060649@linuxfoundation.org> References: <20200128135829.486060649@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Yangtao Li [ Upstream commit 567177024e0313e4f0dcba7ba10c0732e50e655d ] The of_find_compatible_node() returns a node pointer with refcount incremented, but there is the lack of use of the of_node_put() when done. Add the missing of_node_put() to release the refcount. Signed-off-by: Yangtao Li Fixes: 1f2c5fd5f048 ("ARM: imx: add VF610 clock support") Signed-off-by: Stephen Boyd Signed-off-by: Sasha Levin --- drivers/clk/imx/clk-vf610.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/clk/imx/clk-vf610.c b/drivers/clk/imx/clk-vf610.c index 0a94d9661d912..2c92a2706fdd0 100644 --- a/drivers/clk/imx/clk-vf610.c +++ b/drivers/clk/imx/clk-vf610.c @@ -155,6 +155,7 @@ static void __init vf610_clocks_init(struct device_node *ccm_node) np = of_find_compatible_node(NULL, NULL, "fsl,vf610-anatop"); anatop_base = of_iomap(np, 0); BUG_ON(!anatop_base); + of_node_put(np); np = ccm_node; ccm_base = of_iomap(np, 0); -- 2.20.1