Received: by 2002:a05:6a10:7420:0:0:0:0 with SMTP id hk32csp3837050pxb; Mon, 21 Feb 2022 06:43:10 -0800 (PST) X-Google-Smtp-Source: ABdhPJyj5fS5qP4hGLrHY64yUHzkTQo3UlATOmLyaUnQ+nldiOzZ/AC+NWjFDwRKpoIpJMYwpLqy X-Received: by 2002:a63:2a53:0:b0:372:cb6d:3d61 with SMTP id q80-20020a632a53000000b00372cb6d3d61mr16391517pgq.575.1645454590380; Mon, 21 Feb 2022 06:43:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645454590; cv=none; d=google.com; s=arc-20160816; b=qyC/kO+yRD9O7mTpNYzrVGPKMjqEzNFWHlDkzI5rJA8O/vyTpYeEcnSvH9OwwkRRlY dvjJ0bS5akfizaGvok15mwQKU2fZCNH9L3CTaEabvO9hVbHRMV6+lmGOILCMhfQj+R5N u+j1tEyLknF/9rXL2UZ+Qo8eVW5BohJTTzG9vboLTmtT9vWEp20rO6RauQh+imBcOaeb dglIfG4LBAqyUZCvjgIlpbxrncKXR0Kqhpp0beyMWErb5CEPRsTI4aEqsSjd6925YYl/ PA5FK/+AXSGu/SpsjGfqsJv5j6veFYMiWqkMT0o3Sd7PSeDFqQrSqZUmbliQibzR7s9t JQeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Svnn9uxtn2AOXTC4WJ5DzmaN69sjywp7zGjrjZMU/uU=; b=QMFvUVNmDvs+rpd7TOPGqTWxYynHyDyp85l4Kkvw/95uJ8kxd3L/9vnumeuQOpAh1J s8y/1rIRGzChKUhnDjeYDZjmpIym2nFbvw6QDwfpfVxzdYx7IKd1N5uVwdLBFyDGMCvy FojKrnGvRzPXen2+mJEg+7zPzvfHUMwPSiptcqxnvbNg6TqjeufRUB2B8phMDfHZGVnl 6BBox6jLo40uk1jA8PbDxP5dOBGu0DteqXq5zNou806C7IbRdCP0HT1dgasZj3+S4T7y kPgsL7TWdENFsjUZKyyzZHw9oxmpqifVSgx+xvWGL1nJtt5KLzJR9TYSqRTMtPBaM6dX w4uQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=tLa+T1On; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u8si36472238plh.177.2022.02.21.06.42.55; Mon, 21 Feb 2022 06:43:10 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=tLa+T1On; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352374AbiBUKEO (ORCPT + 99 others); Mon, 21 Feb 2022 05:04:14 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:57298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1353402AbiBUJ5Z (ORCPT ); Mon, 21 Feb 2022 04:57:25 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BEBB247568; Mon, 21 Feb 2022 01:25:35 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 584CE608C4; Mon, 21 Feb 2022 09:25:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 32C76C340E9; Mon, 21 Feb 2022 09:25:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1645435534; bh=KRBk8usKmGeZ1GUK1kBqF1ohJl+84gnwg7OyWcxSc50=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tLa+T1On29iFiYUH//zRBcaG7triTIlw31AE699DDrV2uQHDtUgh1PxCsy/yUGmNb dMHmXo8tcxa3p7fDtP8I++O+fZQQJEcn6kqiYDMXkci/mzbv5qpd8iAGC0s8nMQIhY qOUEo+aFsfwZL+VvBkfYGeVC3cnFlLYpHJ99PWoY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Wan Jiabing , Tony Lindgren , Sasha Levin Subject: [PATCH 5.16 198/227] ARM: OMAP2+: hwmod: Add of_node_put() before break Date: Mon, 21 Feb 2022 09:50:17 +0100 Message-Id: <20220221084941.398493015@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220221084934.836145070@linuxfoundation.org> References: <20220221084934.836145070@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Wan Jiabing [ Upstream commit 80c469a0a03763f814715f3d12b6f3964c7423e8 ] Fix following coccicheck warning: ./arch/arm/mach-omap2/omap_hwmod.c:753:1-23: WARNING: Function for_each_matching_node should have of_node_put() before break Early exits from for_each_matching_node should decrement the node reference counter. Signed-off-by: Wan Jiabing Signed-off-by: Tony Lindgren Signed-off-by: Sasha Levin --- arch/arm/mach-omap2/omap_hwmod.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c index ccb0e3732c0dc..31d1a21f60416 100644 --- a/arch/arm/mach-omap2/omap_hwmod.c +++ b/arch/arm/mach-omap2/omap_hwmod.c @@ -752,8 +752,10 @@ static int __init _init_clkctrl_providers(void) for_each_matching_node(np, ti_clkctrl_match_table) { ret = _setup_clkctrl_provider(np); - if (ret) + if (ret) { + of_node_put(np); break; + } } return ret; -- 2.34.1